ansible/roles/docker_host/tasks/user_group_setup.yml

15 lines
285 B
YAML

---
- name: Ensure group "docker" exists
ansible.builtin.group:
name: docker
state: present
become: true
- name: Append the group docker to "{{ user }}"
ansible.builtin.user:
name: "{{ user }}"
shell: /bin/bash
groups: docker
append: true
become: true