github.com/containers/podman/v2@v2.2.2-0.20210501105131-c1e07d070c4c/docs/source/markdown/podman-search.1.md (about)

     1  % podman-search(1)
     2  
     3  ## NAME
     4  podman\-search - Search a registry for an image
     5  
     6  ## SYNOPSIS
     7  **podman search** [*options*] *term*
     8  
     9  ## DESCRIPTION
    10  **podman search** searches a registry or a list of registries for a matching image.
    11  The user can specify which registry to search by prefixing the registry in the search term
    12  (example **registry.fedoraproject.org/fedora**), default is the registries in the
    13  **registries.search** table in the config file - **/etc/containers/registries.conf**.
    14  The default number of results is 25. The number of results can be limited using the **--limit** flag.
    15  If more than one registry is being searched, the limit will be applied to each registry. The output can be filtered
    16  using the **--filter** flag. To get all available images in a registry without a specific
    17  search term, the user can just enter the registry name with a trailing "/" (example **registry.fedoraproject.org/**).
    18  Note, searching without a search term will only work for registries that implement the v2 API.
    19  
    20  **podman [GLOBAL OPTIONS]**
    21  
    22  **podman search [GLOBAL OPTIONS]**
    23  
    24  **podman search [OPTIONS] TERM**
    25  
    26  ## OPTIONS
    27  
    28  #### **--authfile**=*path*
    29  
    30  Path of the authentication file. Default is ${XDG\_RUNTIME\_DIR}/containers/auth.json
    31  
    32  Note: You can also override the default path of the authentication file by setting the REGISTRY\_AUTH\_FILE
    33  environment variable. `export REGISTRY_AUTH_FILE=path`
    34  
    35  #### **--filter**, **-f**=*filter*
    36  
    37  Filter output based on conditions provided (default [])
    38  
    39  Supported filters are:
    40  
    41  * stars (int - number of stars the image has)
    42  * is-automated (boolean - true | false) - is the image automated or not
    43  * is-official (boolean - true | false) - is the image official or not
    44  
    45  #### **--format**=*format*
    46  
    47  Change the output format to a Go template
    48  
    49  Valid placeholders for the Go template are listed below:
    50  
    51  | **Placeholder** | **Description**              |
    52  | --------------- | ---------------------------- |
    53  | .Index          | Registry                     |
    54  | .Name           | Image name                   |
    55  | .Descriptions   | Image description            |
    56  | .Stars          | Star count of image          |
    57  | .Official       | "[OK]" if image is official  |
    58  | .Automated      | "[OK]" if image is automated |
    59  | .Tag            | Repository tag               |
    60  
    61  Note: use .Tag only if the --list-tags is set.
    62  
    63  #### **--limit**=*limit*
    64  
    65  Limit the number of results (default 25).
    66  Note: The results from each registry will be limited to this value.
    67  Example if limit is 10 and two registries are being searched, the total
    68  number of results will be 20, 10 from each (if there are at least 10 matches in each).
    69  The order of the search results is the order in which the API endpoint returns the results.
    70  
    71  #### **--list-tags**
    72  
    73  List the available tags in the repository for the specified image.
    74  **Note:** --list-tags requires the search term to be a fully specified image name.
    75  The result contains the Image name and its tag, one line for every tag associated with the image.
    76  
    77  #### **--no-trunc**
    78  
    79  Do not truncate the output
    80  
    81  #### **--tls-verify**=*true|false*
    82  
    83  Require HTTPS and verify certificates when contacting registries (default: true). If explicitly set to true,
    84  then TLS verification will be used. If set to false, then TLS verification will not be used if needed. If not specified,
    85  default registries will be searched through (in /etc/containers/registries.conf), and TLS will be skipped if a default
    86  registry is listed in the insecure registries.
    87  
    88  #### **--help**, **-h**
    89  
    90  Print usage statement
    91  
    92  ## EXAMPLES
    93  
    94  ```
    95  $ podman search --limit 3 rhel
    96  INDEX        NAME                                 DESCRIPTION                                       STARS   OFFICIAL   AUTOMATED
    97  docker.io    docker.io/richxsl/rhel7              RHEL 7 image with minimal installation            9
    98  docker.io    docker.io/bluedata/rhel7             RHEL-7.x base container images                    1
    99  docker.io    docker.io/gidikern/rhel-oracle-jre   RHEL7 with jre8u60                                5                  [OK]
   100  redhat.com   redhat.com/rhel                      This platform image provides a minimal runti...   0
   101  redhat.com   redhat.com/rhel6                     This platform image provides a minimal runti...   0
   102  redhat.com   redhat.com/rhel6.5                   This platform image provides a minimal runti...   0
   103  ```
   104  
   105  ```
   106  $ podman search alpine
   107  INDEX       NAME                                             DESCRIPTION                                       STARS   OFFICIAL   AUTOMATED
   108  docker.io   docker.io/library/alpine                         A minimal Docker image based on Alpine Linux...   3009    [OK]
   109  docker.io   docker.io/mhart/alpine-node                      Minimal Node.js built on Alpine Linux             332
   110  docker.io   docker.io/anapsix/alpine-java                    Oracle Java 8 (and 7) with GLIBC 2.23 over A...   272                [OK]
   111  docker.io   docker.io/tenstartups/alpine                     Alpine linux base docker image with useful p...   5                  [OK]
   112  ```
   113  
   114  ```
   115  $ podman search registry.fedoraproject.org/fedora
   116  INDEX               NAME                               DESCRIPTION   STARS   OFFICIAL   AUTOMATED
   117  fedoraproject.org   fedoraproject.org/fedora                         0
   118  fedoraproject.org   fedoraproject.org/fedora-minimal                 0
   119  ```
   120  
   121  ```
   122  $ podman search --filter=is-official alpine
   123  INDEX       NAME                       DESCRIPTION                                       STARS   OFFICIAL   AUTOMATED
   124  docker.io   docker.io/library/alpine   A minimal Docker image based on Alpine Linux...   3009    [OK]
   125  ```
   126  
   127  ```
   128  $ podman search --format "table {{.Index}} {{.Name}}" registry.fedoraproject.org/fedora
   129  INDEX               NAME
   130  fedoraproject.org   fedoraproject.org/fedora
   131  fedoraproject.org   fedoraproject.org/fedora-minimal
   132  ```
   133  
   134  ```
   135  $ podman search registry.fedoraproject.org/
   136  INDEX               NAME                                                           DESCRIPTION   STARS   OFFICIAL   AUTOMATED
   137  fedoraproject.org   registry.fedoraproject.org/f25/cockpit                                       0
   138  fedoraproject.org   registry.fedoraproject.org/f25/container-engine                              0
   139  fedoraproject.org   registry.fedoraproject.org/f25/docker                                        0
   140  fedoraproject.org   registry.fedoraproject.org/f25/etcd                                          0
   141  fedoraproject.org   registry.fedoraproject.org/f25/flannel                                       0
   142  fedoraproject.org   registry.fedoraproject.org/f25/httpd                                         0
   143  fedoraproject.org   registry.fedoraproject.org/f25/kubernetes-apiserver                          0
   144  fedoraproject.org   registry.fedoraproject.org/f25/kubernetes-controller-manager                 0
   145  fedoraproject.org   registry.fedoraproject.org/f25/kubernetes-kubelet                            0
   146  fedoraproject.org   registry.fedoraproject.org/f25/kubernetes-master                             0
   147  fedoraproject.org   registry.fedoraproject.org/f25/kubernetes-node                               0
   148  fedoraproject.org   registry.fedoraproject.org/f25/kubernetes-proxy                              0
   149  fedoraproject.org   registry.fedoraproject.org/f25/kubernetes-scheduler                          0
   150  fedoraproject.org   registry.fedoraproject.org/f25/mariadb                                       0
   151  ```
   152  
   153  ```
   154  $ podman search --list-tags  registry.redhat.io/rhel
   155  NAME                      TAG
   156  registry.redhat.io/rhel   7.3-74
   157  registry.redhat.io/rhel   7.6-301
   158  registry.redhat.io/rhel   7.1-9
   159  ...
   160  ```
   161  Note: This works only with registries that implement the v2 API. If tried with a v1 registry an error will be returned.
   162  
   163  ## FILES
   164  
   165  **registries.conf** (`/etc/containers/registries.conf`)
   166  
   167  	registries.conf is the configuration file which specifies which container registries should be consulted when completing image names which do not include a registry or domain portion.
   168  
   169  ## SEE ALSO
   170  podman(1), containers-registries.conf(5)
   171  
   172  ## HISTORY
   173  January 2018, Originally compiled by Urvashi Mohnani <umohnani@redhat.com>