![]() We start by downloading the current, stable release of Docker Compose. Installing Docker Compose is really easy, just copy and paste a few more commands into the SSH terminal. This makes it really easy to create and configure many containers at once, and also to backup your environment. docker run hello-world Installing Docker Composeĭocker Compose is a really handy utility that allows you to create and configure Docker containers using a YAML file. If everything has worked properly, you should be able to re-download and run the Hello World Docker container without using sudo. Now log out and back in again for the permission changes to take effect. Now add your user account to that Docker group. Let's do that now.įirst, create the Docker group if it doesn't already exist. To get Docker to work as a non-root user we need to add our user to the Docker group. This may reduce the security of my Docker environment, but because it's running in my own network, inaccessible from the outside world I'm willing to accept that risk. I find it easiest if I can manage Docker as a non-Root user - it means I don't need to add sudo to the start of every command. If everything is working properly you'll see the container output a message to the screen and shut itself down. ![]() You can verify that everything is working by running the Hello World docker container. Sudo apt-get install docker-ce docker-ce-cli containerd.ioĬongratulations! You now have Docker installed! $(lsb_release -cs) stable" | sudo tee /etc/apt//docker.list > /dev/nullįinally, install the Docker engine using these two commands sudo apt-get update Set up the file repository for the Stable version of Docker (You can run a beta or experimental one if you want, but I prefer to use the stable versions) echo \ sudo apt-get updateĪdd Dockers official GPG key to the KeyRing curl -fsSL | sudo gpg -dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg Now we update the apt package index and allow it to use HTTPS with these two commands. You'll probably have none if this is a fresh install of Ubuntu Server sudo apt-get remove docker docker-engine docker.io containerd runc Now we'll install the Docker Engine for Ubuntu by running the following commands.įirst we remove any older versions of Docker Engine, if they exist.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |