github.com/hanks177/podman/v4@v4.1.3-0.20220613032544-16d90015bc83/docs/source/markdown/podman-network-ls.1.md (about)

     1  % podman-network-ls(1)
     2  
     3  ## NAME
     4  podman\-network\-ls - Display a summary of networks
     5  
     6  ## SYNOPSIS
     7  **podman network ls**  [*options*]
     8  
     9  ## DESCRIPTION
    10  Displays a list of existing podman networks.
    11  
    12  ## OPTIONS
    13  #### **--filter**, **-f**=*filter=value*
    14  
    15  Provide filter values.
    16  
    17  The *filters* argument format is of `key=value`. If there is more than one *filter*, then pass multiple OPTIONS: **--filter** *foo=bar* **--filter** *bif=baz*.
    18  
    19  Supported filters:
    20  
    21  | **Filter** | **Description**                                                                                  |
    22  | ---------- | ------------------------------------------------------------------------------------------------ |
    23  | driver     | Filter by driver type.                                                                           |
    24  | id         | Filter by full or partial network ID.                                                            |
    25  | label      | Filter by network with (or without, in the case of label!=[...] is used) the specified labels.   |
    26  | name       | Filter by network name (accepts `regex`).                                                        |
    27  | until      | Filter by networks created before given timestamp.                                               |
    28  
    29  
    30  The `driver` filter accepts values: `bridge`, `macvlan`, `ipvlan`.
    31  
    32  The `label` *filter* accepts two formats. One is the `label`=*key* or `label`=*key*=*value*, which shows images with the specified labels. The other format is the `label!`=*key* or `label!`=*key*=*value*, which shows images without the specified labels.
    33  
    34  The `until` *filter* can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. 10m, 1h30m) computed relative to the machine’s time.
    35  
    36  #### **--format**=*format*
    37  
    38  Change the default output format.  This can be of a supported type like 'json'
    39  or a Go template.
    40  Valid placeholders for the Go template are listed below:
    41  
    42  | **Placeholder**   | **Description**                           |
    43  | ----------------- | ----------------------------------------- |
    44  | .ID               | Network ID                                |
    45  | .Name             | Network name                              |
    46  | .Driver           | Network driver                            |
    47  | .Labels           | Network labels                            |
    48  | .Options          | Network options                           |
    49  | .IPAMOptions      | Network ipam options                      |
    50  | .Created          | Timestamp when the network was created    |
    51  | .Internal         | Network is internal (boolean)             |
    52  | .IPv6Enabled      | Network has ipv6 subnet (boolean)         |
    53  | .DNSEnabled       | Network has dns enabled (boolean)         |
    54  | .NetworkInterface | Name of the network interface on the host |
    55  | .Subnets          | List of subnets on this network           |
    56  
    57  #### **--no-trunc**
    58  
    59  Do not truncate the network ID.
    60  
    61  #### **--noheading**
    62  
    63  Omit the table headings from the listing of networks.
    64  
    65  #### **--quiet**, **-q**
    66  
    67  The `quiet` option will restrict the output to only the network names.
    68  
    69  ## EXAMPLE
    70  
    71  Display networks
    72  
    73  ```
    74  $ podman network ls
    75  NETWORK ID    NAME         DRIVER
    76  88a7120ee19d  podman       bridge
    77  6dd508dbf8cd  cni-podman6  bridge
    78  8e35c2cd3bf6  cni-podman5  macvlan
    79  ```
    80  
    81  Display only network names
    82  ```
    83  $ podman network ls -q
    84  podman
    85  podman2
    86  outside
    87  podman9
    88  ```
    89  
    90  Display name of network which support bridge plugin
    91  ```
    92  $ podman network ls --filter driver=bridge --format {{.Name}}
    93  podman
    94  podman2
    95  podman9
    96  ```
    97  List networks with their subnets
    98  ```
    99  $ podman network ls --format "{{.Name}}: {{range .Subnets}}{{.Subnet}} {{end}}"
   100  podman: 10.88.0.0/16
   101  cni-podman3: 10.89.30.0/24 fde4:f86f:4aab:e68f::/64
   102  macvlan:
   103  ```
   104  
   105  ## SEE ALSO
   106  **[podman(1)](podman.1.md)**, **[podman-network(1)](podman-network.1.md)**, **[podman-network-inspect(1)](podman-network-inspect.1.md)**, **[podman-network-create(1)](podman-network-create.1.md)**
   107  
   108  ## HISTORY
   109  August 2021, Updated with the new network format by Paul Holzinger <pholzing@redhat.com>
   110  
   111  August 2019, Originally compiled by Brent Baude <bbaude@redhat.com>