I am unable to run Docker on AMI linux EC2 instance on AWS. My AMI linux instance is Linux ip-172-31-29-77 4.14.62-65.117.amzn1.x86_64 #1 SMP Fri Aug 10 20:03:52 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux.
I am able to install docker and start the service using:
sudo yum install -y docker
sudo service docker start
sudo usermod -aG docker ec2-user
but cmd docker ps does not work?
can anyone help me on this?
Thanks, Nidhi Arora
You have done all the steps correctly. I believe your goal here is to run docker commands without sudo.
However after adding user to the docker (Or any) group, you have to refresh the user's group id.
You can either login again or do su - $USER.
You can run id before and after to confirm.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With