Closed javalenjara closed 7 months ago
Add the user to the docker group:
sudo usermod -aG docker $USER
Then, you have to "update" the docker group with:
newgrp docker
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
This issue has been closed due to inactivity. If you feel this is in error, please reopen the issue or file a new issue with the relevant details.
While running
ansible-playbook main.yml
next message appears:fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'ansible_user' is undefined. 'ansible_user' is undefined\n\nThe error appears to be in '/home/javalen/code/internet-pi/tasks/docker.yml': line 58, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: \"Ensure user is added to the docker group: {{ ansible_user }}\"\n ^ here\nWe could be wrong, but this one looks like it might be an issue with\nmissing quotes. Always quote template expression brackets when they\nstart a value. For instance:\n\n with_items:\n - {{ foo }}\n\nShould be written as:\n\n with_items:\n - \"{{ foo }}\"\n"}
init.yml
file contents:raspberrypi ansible_user=javalen
I'm running using ssh from another pc.