Created
April 8, 2020 08:04
-
-
Save mshRoR/555f26c2c9048030d1ae7b1770fae63f to your computer and use it in GitHub Desktop.
How to fix docker: Got permission denied issue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
If you want to run docker as non-root user then you need to add it to the docker group. | |
1. Create the docker group if it does not exist | |
$ sudo groupadd docker | |
2. Add your user to the docker group. | |
$ sudo usermod -aG docker $USER | |
3. Run the following command or Logout and login again and run (that doesn't work you may need to reboot your machine first) | |
$ newgrp docker | |
4. Check if docker can be run without root | |
$ docker run hello-world | |
source: https://stackoverflow.com/questions/48957195/how-to-fix-docker-got-permission-denied-issue |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you want to run docker as non-root user then you need to add it to the docker group.
$ sudo groupadd docker
$ sudo usermod -aG docker $USER
$ newgrp docker
$ docker run hello-world
source: https://stackoverflow.com/questions/48957195/how-to-fix-docker-got-permission-denied-issue