configurations-ansible/roles/ansible-node/tasks/main.yml

14 lines
403 B
YAML

---
# tasks file for ansible-node
- name: Setup node with ansible for given user
when: 'ansible_node_user is defined'
block:
- name: Install python3-pip if not present
ansible.builtin.package:
name: python3-pip
- name: Install ansible with pip
become: true
become_user: '{{ ansible_node_user }}'
ansible.builtin.shell: python3 -m pip install --user ansible