add docker app name in task names

This commit is contained in:
Gabriel Augendre 2024-10-20 22:23:13 +02:00
parent f2df9c06f7
commit 2ed3f6cfa8
2 changed files with 7 additions and 7 deletions

View file

@ -1,10 +1,10 @@
---
- name: Stop service
- name: Stop service {{ docker_app_name }}
listen: Restart service
community.docker.docker_compose_v2:
project_src: "{{ docker_dir }}"
state: stopped
- name: Start service
- name: Start service {{ docker_app_name }}
listen: Restart service
community.docker.docker_compose_v2:
project_src: "{{ docker_dir }}"

View file

@ -1,10 +1,10 @@
---
- name: Create dir
- name: Create dir for {{ docker_app_name }}
ansible.builtin.file:
path: "{{ docker_dir }}"
state: directory
mode: "0775"
- name: Write files
- name: Write files for {{ docker_app_name }}
ansible.builtin.copy:
src: "{{ item }}"
dest: "{{ docker_dir }}/"
@ -14,7 +14,7 @@
- files/{{ docker_app_name }}/.*
notify:
- Restart service
- name: Write templates
- name: Write templates for {{ docker_app_name }}
ansible.builtin.template:
src: "{{ item }}"
dest: "{{ docker_dir }}/{{ item | basename | regex_replace('\\.j2$', '') }}"
@ -24,9 +24,9 @@
- templates/{{ docker_app_name }}/.*.j2
notify:
- Restart service
- name: Flush handlers
- name: Flush handlers for {{ docker_app_name }}
ansible.builtin.meta: flush_handlers
- name: Ensure service is started
- name: Ensure service is started {{ docker_app_name }}
community.docker.docker_compose_v2:
project_src: "{{ docker_dir }}"
state: present