Migrating existing images and playing with a command's alias
Podman has one great feature that lets any previous Docker user easily adapt and switch to it – complete command-line interface (CLI) compatibility with Docker.
Let's demonstrate this CLI compatibility with Docker by creating a shell command alias for the docker
command:
# alias docker=podman # docker Error: missing command 'podman COMMAND' Try 'podman --help' for more information.
As you can see, we have created a command alias that binds the podman
command to the docker
one. If we try to execute the docker
command after setting the alias, the output is returned from the podman
command instead.
Let's try this out on the newly created alias by running a container:
# docker run --rm -it docker.io/wernight/funbox nyancat
We should see something very funny – a running cat, similar to the one shown in the following screenshot: