Welcome to this video about using Podman to search container registries for images to
be used to create containers on Oracle Linux.
Let's look at how to search for images to pull down from the image registries.
Images are pulled from container registries and stored in local storage.
They are then used to create and run containers.
We can see the default list of containers registries that will be used, which was configured
when the container-tools package was installed.
They are added into the registries.conf file.
We can view the file with the command cat /etc/containers/registries.conf.
The section unqualified-search-registries identifies the default registries configured
to be used when searching for images.
Different container registries can be used, they just need to be configured.
Ok, let's search for any images matching oracle in all configured registries.
We use the command podman search oracle.
The results displayed are limited to the top 25 entries for each container registry searched,
and can be affected by how the different registries are implemented.
Under the name column, we see the entries are coming from the container-registry.oracle.com
and docker.io registries.
The last part of the name path is the container image name.
Now let's list the top 5 images which contain oracle from both configured container registries
by adding the command option --limit 5.
The command is flexible with the arrangement of the command options, for example, the command
podman search --limit 5 oracle also works.
Now we search again, but list only the first 10 entries and additional columns showing
star rating, official status, and automated information.
For this we add the option --compatible.
Now we want to search for image version tags for any images called oraclelinux.
The tag typically represents a version of the image.
We use the option --list-tags and need to specify the full qualified path and image
name, so we use container-registry.oracle.com/os/oraclelinux.
Remember, if search result provides more than the default top 25 per registry, you may not
see all possible entries.
As we see in our output the results only go up 7.9.
Oracle Linux images are tagged with their release level.
For example, to get the latest update release image for Oracle Linux 8, use the 8 tag.
Oracle offers minimal compressed versions of each Oracle Linux release, as seen with
the 7-slim and 8-slim tags.
These images contain just enough operating system to run within a container and to perform
installations of more packages.
If you need a more complete operating system than the slim image, use a release tag.
Many tools default to using a tag called latest.
But Oracle doesn't provide this tag for Oracle Linux images, or recommend it is used.
You can read more about tags and Oracle's tagging conventions at this link.
To see all tags, we increase the results displayed by adding the --limit 50 option to show up
to 50 entries.
Now we see all the tags for this image.
Let's list only oraclelinux images with tags containing the number 8.
We add | grep 8 to filter the up to 50 results to any with 8.
And we do the same to filter for the number 9.
Now let's search for any oracle images with official status.
We use the command podman search oracle -f=is-official to filter for any that are official images.
The Docker registry only returns one image found, as there is only one image with this
name marked official.
How do we know these are official images, we can ask to see the output with the official
status listed by adding the --compatible option.
The OFFICIAL column shows the OK status, which indicates the image is the official image.
Now we limit this list to the top 3 entries for each configured registry being searched
by adding the option --limit 3.
Remember that any search results can be affected by how the container registries are being
implemented.
We have been searching in the configured remote container registries, but when we create or
run a container, the requested image will be pulled into local storage, or simply used
if it is already in local storage.
We list any images that have currently been downloaded to local storage with the podman
images command.
The hello:latest image was pulled before to have an image downloaded to view.
But other than that we have not pulled any other images down from a container registry
and our searching was carried out on the remote container registries.
So that's some practice at some of the commands used to search for images from container registries
using Podman.
These commands support a lot more options which are worth investigating, if you have
the time there is even a free real hands on lab environment where you can practice these
and many more Podman commands.
You can find it at this link.
That's the end of this video.
Oracle provides an extensive number of resources which you can use to learn about this subject
and others.
Use the links here to find more content about this video as well as Oracle Linux and using
Linux.
Thanks for watching.