add gitlab

This commit is contained in:
Florian RICHER 2023-09-25 22:01:57 +02:00
parent 4e62432a58
commit 82e2cdb355
7 changed files with 147 additions and 0 deletions

View file

@ -0,0 +1,22 @@
---
- name: Check gitlab directory exist
ansible.builtin.file:
path: gitlab
state: directory
- name: Copy template conf
ansible.builtin.template:
src: "{{ item.src }}"
dest: "gitlab/{{ item.dest }}"
loop:
- { src: 'docker-compose.yml', dest: 'docker-compose.yml' }
register: gitlab_copy_templates_results
- name: Update and restart container
community.docker.docker_compose:
project_src: gitlab
state: present
pull: true
restarted: "{{ gitlab_copy_templates_results.changed }}"
become: true