Low Orbit Flux Logo 2 F

Docker How To Name Or Rename A Container

Naming and renaming Docker containers is easy. That is good to know because it would be pretty inconvenient if there wasn’t a way to specify and change the name of a container.

You can specify a name for a new container when you launch it like this. The following will name your container “silly-squid”.


sudo docker run -d --name silly-squid ubuntu

If you want to rename your container you can accomplish this easily with the rename command. The following will rename “silly-squid” to “funny-frog”.


sudo docker rename silly-squid funny-frog