39 lines
783 B
YAML
39 lines
783 B
YAML
- hosts: archlinux
|
|
remote_user: root
|
|
become: true
|
|
gather_facts: false
|
|
tasks:
|
|
- name: Init pacman
|
|
ansible.builtin.raw: |
|
|
pacman-key --init
|
|
pacman-key --populate archlinux
|
|
changed_when: false
|
|
failed_when: false
|
|
- name: "install python on arch"
|
|
raw: pacman -Sy python --noconfirm
|
|
|
|
- hosts: rocky9
|
|
remote_user: root
|
|
become: true
|
|
gather_facts: false
|
|
tasks:
|
|
- name: "install python for rocky"
|
|
raw: dnf install python3 --assumeyes
|
|
|
|
|
|
- hosts: debian
|
|
remote_user: root
|
|
become: true
|
|
gather_facts: false
|
|
tasks:
|
|
- name: "install python for debian"
|
|
raw: apt install python3 --assume-yes
|
|
|
|
- hosts: all
|
|
become: true
|
|
tasks:
|
|
- name: create user
|
|
user:
|
|
name: user
|
|
state: present
|