To install Docker on Ubuntu 22.04.2 LTS you can use these simple instructions, these are based on a standard Ubuntu 22.04.2 LTS installation and using a user called “ubuntu”.
cd /tmp
curl -o /tmp/get-docker.sh https://get.docker.com
Once downloaded make sure it is executable with:
chmod u+x get-docker.sh
Now run the installation with the following, the script has sudo commands added so you may need to re-enter your password.
./get-docker.sh
After a short while it should be installed, to test now run:
sudo docker run hello-world
If all is well you’ll get a message saying it has run the docker container correctly and provided a result.
As we don’t want to run sudo for each time we want to use docker, we need to add our “ubuntu” user into the Docker group.
sudo usermod -aG docker ubuntu
Once that is done, log out and back in again to re-enumerate the permissions, and let’s test again, if you can run without prefixing the command with “sudo”, we’re all set!
docker run hello-world
![](https://geekmungus.co.uk/wp-content/uploads/2023/07/image-10.png)
1 thought on “Docker Install on Ubuntu 22.04.2 LTS”