Refactor user permissions task to use Ansible user module

This commit is contained in:
Ahmed Elzagh 2023-06-15 22:08:16 +03:00
parent 05ac0b680f
commit a5378bc268

View File

@ -9,7 +9,9 @@
- docker.io
update_cache: yes
- name: add user permissions
shell: "usermod -aG docker {{ ansible_env.SUDO_USER }}"
user:
name: "{{ ansible_env.SUDO_USER }}"
groups: docker
- name: Reset ssh connection for changes to take effect
meta: "reset_connection"
- name: install python package manager