<\/span><\/h2>\r\n\r\n\r\n\r\nBefore we start installing everything, we should upgrade our system, so after logging in as root, you can run:<\/p>\r\n\r\n\r\n\r\n
apt-get update -y\r\napt-get upgrade -y<\/code><\/pre>\r\n\r\n\r\n\r\n<\/span>Installing dependencies<\/span><\/h2>\r\n\r\n\r\n\r\nAlso, it’s required by Docker some dependencies, so you can easily install them with this command:<\/p>\r\n\r\n\r\n\r\n
apt-get install apt-transport-https ca-certificates curl gnupg lsb-release -y<\/code><\/pre>\r\n\r\n\r\n\r\n<\/span>Adding the Docker Repository<\/span><\/h2>\r\n\r\n\r\n\r\n\r\n- Since our dependecies are installed, we’ll proceed with adding the Docker Repository so we can fetch our download, first of all run the following command to add the GPG Key:<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n
curl -fsSL https:\/\/download.docker.com\/linux\/debian\/gpg | sudo gpg --dearmor -o \/usr\/share\/keyrings\/docker-archive-keyring.gpg<\/code><\/pre>\r\n\r\n\r\n\r\n\r\n- Then, we’ll add the docker repository using this command:<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n
echo \\\r\n \"deb [arch=amd64 signed-by=\/usr\/share\/keyrings\/docker-archive-keyring.gpg] https:\/\/download.docker.com\/linux\/debian \\\r\n $(lsb_release -cs) stable\" | sudo tee \/etc\/apt\/sources.list.d\/docker.list > \/dev\/null<\/code><\/pre>\r\n\r\n\r\n\r\n\r\n- You should now run a new update & upgrade on your system to update everything:<\/li>\r\n<\/ol>\r\n\r\n\r\n\r\n
apt-get update -y\r\napt-get upgrade -y<\/code><\/pre>\r\n\r\n\r\n\r\nNow, we are ready to install Docker.<\/p>\r\n\r\n\r\n\r\n