aboutsummaryrefslogtreecommitdiff
path: root/infrastructure/roles/incus_provision/tasks/main.yaml
blob: 7b54f9ead6fe579e54001536b558adb90e19c943 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
- name: create incus container
  ansible.builtin.shell: incus info {{ ansible_incus_host }} || incus launch images:debian/13 {{ ansible_incus_host }} --vm
  delegate_to: 127.0.0.1
- name: fetch your user id to identify incus project
  ansible.builtin.command: id -u
  delegate_to: 127.0.0.1
  register: uid
- name: set incus project
  ansible.builtin.set_fact:
    ansible_incus_project: user-{{ uid.stdout }}
- name: install python
  ansible.builtin.raw: apt install -y python3
  retries: 10
  delay: 3