infra/ansible/roles/services/tasks/main.yaml
shockrah 3521b840ae
Some checks failed
Ansible Linting / ansible-lint (push) Failing after 6s
Secops Linting and Safety Checks / checkov-scan-s3 (push) Failing after 15s
Seperating the roles of basic infra requirements and docker service requirements into seperate roles
With this we have a working proof of concept for a proper simple docker host
2025-04-16 18:25:24 -07:00

18 lines
537 B
YAML

- name: Ensure docker dir is present
ansible.builtin.file:
path: "{{ docker_compose_dir }}"
state: directory
mode: "0755"
- name: Ensure compose.yaml is present
ansible.builtin.template:
src: compose.yaml
dest: "{{ docker_compose_dir }}/compose.yaml"
mode: "0644"
- name: Apply docker compose with services
community.docker.docker_compose_v2:
project_src: "{{ docker_compose_dir }}"
register: compose_output
- name: Show output of docker compose apply
ansible.builtin.debug:
var: compose_output