github.com/containers/libpod@v1.9.4-0.20220419124438-4284fd425507/docs/source/markdown/podman-images.1.md (about)

     1  % podman-images(1)
     2  
     3  ## NAME
     4  podman\-images - List images in local storage
     5  
     6  ## SYNOPSIS
     7  **podman images** [*options*]
     8  
     9  **podman image list** [*options*]
    10  
    11  **podman image ls** [*options*]
    12  
    13  ## DESCRIPTION
    14  Displays locally stored images, their names, and their IDs.
    15  
    16  ## OPTIONS
    17  
    18  **-a**, **--all**
    19  
    20  Show all images (by default filter out the intermediate image layers). The default is false.
    21  
    22  **--digests**
    23  
    24  Show image digests
    25  
    26  **-f**, **--filter**=*filter*
    27  
    28  Filter output based on conditions provided
    29  
    30    Filters:
    31  
    32    **since=IMAGE**
    33      Filter on images created after the given IMAGE (name or tag).
    34  
    35    **before=IMAGE**
    36      Filter on images created before the given IMAGE (name or tag).
    37  
    38    **dangling=true|false**
    39      Show dangling images. Dangling images are a file system layer that was used in a previous build of an image and is no longer referenced by any active images. They are denoted with the <none> tag, consume disk space and serve no active purpose.
    40  
    41    **label**
    42      Filter by images labels key and/or value.
    43  
    44    **readonly=true|false**
    45       Show only read only images or Read/Write images. The default is to show both.  Read/Only images can be configured by modifying the  "additionalimagestores" in the /etc/containers/storage.conf file.
    46  
    47    **reference=**
    48       Filter by image name, specified as regular expressions.
    49  
    50  **--format**=*format*
    51  
    52  Change the default output format.  This can be of a supported type like 'json'
    53  or a Go template.
    54  Valid placeholders for the Go template are listed below:
    55  
    56  | **Placeholder** | **Description**                                                               |
    57  | --------------- | ----------------------------------------------------------------------------- |
    58  | .ID             | Image ID                                                                      |
    59  | .Repository     | Image repository                                                              |
    60  | .Tag            | Image tag                                                                     |
    61  | .Digest         | Image digest                                                                  |
    62  | .CreatedSince   | Elapsed time since the image was created			     					  |
    63  | .CreatedAt      | Time when the image was created                                               |
    64  | .Size           | Size of layer on disk                                                         |
    65  | .History        | History of the image layer                                                    |
    66  
    67  **--history**
    68  
    69  Display the history of image names.  If an image gets re-tagged or untagged, then the image name history gets prepended (latest image first).  This is especially useful when undoing a tag operation or an image does not contain any name because it has been untagged.
    70  
    71  **--noheading**, **-n**
    72  
    73  Omit the table headings from the listing of images.
    74  
    75  **--no-trunc**
    76  
    77  Do not truncate output.
    78  
    79  **--quiet**, **-q**
    80  
    81  Lists only the image IDs.
    82  
    83  **--sort**=*sort*
    84  
    85  Sort by created, id, repository, size or tag (default: created)
    86  
    87  ## EXAMPLE
    88  
    89  ```
    90  # podman images
    91  REPOSITORY                                   TAG      IMAGE ID       CREATED       SIZE
    92  docker.io/kubernetes/pause                   latest   e3d42bcaf643   3 years ago   251 kB
    93  <none>                                       <none>   ebb91b73692b   4 weeks ago   27.2 MB
    94  docker.io/library/ubuntu                     latest   4526339ae51c   6 weeks ago   126 MB
    95  ```
    96  
    97  ```
    98  # podman images --quiet
    99  e3d42bcaf643
   100  ebb91b73692b
   101  4526339ae51c
   102  ```
   103  
   104  ```
   105  # podman images --noheading
   106  docker.io/kubernetes/pause                   latest   e3d42bcaf643   3 years ago   251 kB
   107  <none>                                       <none>   ebb91b73692b   4 weeks ago   27.2 MB
   108  docker.io/library/ubuntu                     latest   4526339ae51c   6 weeks ago   126 MB
   109  ```
   110  
   111  ```
   112  # podman images --no-trunc
   113  REPOSITORY                                   TAG      IMAGE ID                                                                  CREATED       SIZE
   114  docker.io/kubernetes/pause                   latest   sha256:e3d42bcaf643097dd1bb0385658ae8cbe100a80f773555c44690d22c25d16b27   3 years ago   251 kB
   115  <none>                                       <none>   sha256:ebb91b73692bd27890685846412ae338d13552165eacf7fcd5f139bfa9c2d6d9   4 weeks ago   27.2 MB
   116  docker.io/library/ubuntu                     latest   sha256:4526339ae51c3cdc97956a7a961c193c39dfc6bd9733b0d762a36c6881b5583a   6 weeks ago   126 MB
   117  ```
   118  
   119  ```
   120  # podman images --format "table {{.ID}} {{.Repository}} {{.Tag}}"
   121  IMAGE ID       REPOSITORY                                   TAG
   122  e3d42bcaf643   docker.io/kubernetes/pause                   latest
   123  ebb91b73692b   <none>                                       <none>
   124  4526339ae51c   docker.io/library/ubuntu                     latest
   125  ```
   126  
   127  ```
   128  # podman images --filter dangling=true
   129  REPOSITORY   TAG      IMAGE ID       CREATED       SIZE
   130  <none>       <none>   ebb91b73692b   4 weeks ago   27.2 MB
   131  ```
   132  
   133  ```
   134  # podman images --format json
   135  [
   136      {
   137  	"id": "e3d42bcaf643097dd1bb0385658ae8cbe100a80f773555c44690d22c25d16b27",
   138  	"names": [
   139  	    "docker.io/kubernetes/pause:latest"
   140  	],
   141  	"digest": "sha256:0aecf73ff86844324847883f2e916d3f6984c5fae3c2f23e91d66f549fe7d423",
   142  	"created": "2014-07-19T07:02:32.267701596Z",
   143  	"size": 250665
   144      },
   145      {
   146  	"id": "ebb91b73692bd27890685846412ae338d13552165eacf7fcd5f139bfa9c2d6d9",
   147  	"names": [
   148  	    "\u003cnone\u003e"
   149  	],
   150  	"digest": "sha256:ba7e4091d27e8114a205003ca6a768905c3395d961624a2c78873d9526461032",
   151  	"created": "2017-10-26T03:07:22.796184288Z",
   152  	"size": 27170520
   153      },
   154      {
   155  	"id": "4526339ae51c3cdc97956a7a961c193c39dfc6bd9733b0d762a36c6881b5583a",
   156  	"names": [
   157  	    "docker.io/library/ubuntu:latest"
   158  	],
   159  	"digest": "sha256:193f7734ddd68e0fb24ba9af8c2b673aecb0227b026871f8e932dab45add7753",
   160  	"created": "2017-10-10T20:59:05.10196344Z",
   161  	"size": 126085200
   162      }
   163  ]
   164  ```
   165  
   166  ```
   167  # podman images --sort repository
   168  REPOSITORY                                   TAG      IMAGE ID       CREATED       SIZE
   169  <none>                                      <none>   2460217d76fc   About a minute ago   4.41 MB
   170  docker.io/library/alpine                    latest   3fd9065eaf02   5 months ago         4.41 MB
   171  localhost/myapp                             latest   b2e0ad03474a   About a minute ago   4.41 MB
   172  registry.access.redhat.com/rhel7            latest   7a840db7f020   2 weeks ago          211 MB
   173  registry.fedoraproject.org/fedora           27       801894bc0e43   6 weeks ago          246 MB
   174  ```
   175  
   176  ```
   177  # podman images
   178  REPOSITORY                 TAG      IMAGE ID       CREATED         SIZE
   179  localhost/test             latest   18f0c080cd72   4 seconds ago   4.42 MB
   180  docker.io/library/alpine   latest   3fd9065eaf02   5 months ago    4.41 MB
   181  # podman images -a
   182  REPOSITORY                 TAG      IMAGE ID       CREATED         SIZE
   183  localhost/test             latest   18f0c080cd72   6 seconds ago   4.42 MB
   184  <none>                     <none>   270e70dc54c0   7 seconds ago   4.42 MB
   185  <none>                     <none>   4ed6fbe43414   8 seconds ago   4.41 MB
   186  <none>                     <none>   6b0df8e71508   8 seconds ago   4.41 MB
   187  docker.io/library/alpine   latest   3fd9065eaf02   5 months ago    4.41 MB
   188  ```
   189  
   190  ## SEE ALSO
   191  podman(1), containers-storage.conf(5)
   192  
   193  ## HISTORY
   194  March 2017, Originally compiled by Dan Walsh <dwalsh@redhat.com>