feat: add playbook and role
This commit is contained in:
parent
4f11c7c090
commit
e52349797a
2 changed files with 28 additions and 0 deletions
22
playbook.yaml
Normal file
22
playbook.yaml
Normal file
|
|
@ -0,0 +1,22 @@
|
||||||
|
---
|
||||||
|
|
||||||
|
# execute this role
|
||||||
|
- name: "install and configure a container registry"
|
||||||
|
hosts: "all"
|
||||||
|
serial: 1
|
||||||
|
become: true
|
||||||
|
tasks:
|
||||||
|
|
||||||
|
# due to semaphore bug we need to do this ourselves
|
||||||
|
- name: "force-update requirements"
|
||||||
|
ansible.builtin.command:
|
||||||
|
cmd: "ansible-galaxy install -f -r roles/requirements.yml"
|
||||||
|
become: false
|
||||||
|
delegate_to: "localhost"
|
||||||
|
changed_when: false
|
||||||
|
failed_when: false
|
||||||
|
|
||||||
|
# execute the role
|
||||||
|
- name: "execute role: zot"
|
||||||
|
ansible.builtin.include_role:
|
||||||
|
name: "zot"
|
||||||
6
roles/requirements.yml
Normal file
6
roles/requirements.yml
Normal file
|
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
|
||||||
|
roles:
|
||||||
|
- name: "zot"
|
||||||
|
src: "https://gitlab.simoncor.net/ansible/role-zot.git"
|
||||||
|
scm: "git"
|
||||||
Loading…
Add table
Add a link
Reference in a new issue