In the text for RH134 (v9), chapter 11, section 5, there is this command:
This command will not work as expected as it will not set the container name to db01 because anything that appears after the image name (registry.lab.example.com/rhel8/mariadb-105) is treated as a command to be executed inside the container after it starts.
In other words, this command tries to [1] run the --name db01 command (which does not exist) inside the container and therefore [2] does not set the container name to db01.
Furthermore, this means that this is also incorrect:
This is wrong because the NAME field cannot be db01 due to the prior incorrect command. Insead, the NAME field will be some random value.
The COMMAND field will also be different. It will list --name db01 instead of run-mysql
It also leads to this being incorrect. Again db01 doesn't exist:
To fix this, the command should be:
podman run -d --name db01 registry.lab.example.com/rhel8/mariadb-105
Red Hat
Learning Community
A collaborative learning environment, enabling open source skill development.