applying tags on includes

This commit is contained in:
AnsibleGuy 2023-01-28 16:22:06 +01:00
parent 893500f3d7
commit 8364389f7a
No known key found for this signature in database
GPG Key ID: 52984C069F5AD3CD
2 changed files with 16 additions and 1 deletions

View File

@ -1,7 +1,7 @@
---
- name: "Apache | Debian | Site '{{ name }}' | Certs | Creating certificates"
ansible.builtin.import_role:
ansible.builtin.include_role:
name: ansibleguy.infra_certs
vars:
certs:
@ -34,6 +34,9 @@
email: "{{ site.ssl.ca.email | default(APACHE_CONFIG.ssl.ca.email, true) }}"
pwd: "{{ site.ssl.ca.pwd | default(APACHE_CONFIG.ssl.ca.pwd, true) }}"
when: "site.ssl.mode in ['ca', 'selfsigned']"
args:
apply:
tags: [certs, sites]
- name: "Apache | Debian | Site '{{ name }}' | Certs | Trying to copy cert pub"
ansible.builtin.copy:

View File

@ -107,6 +107,9 @@
with_dict: "{{ APACHE_CONFIG.sites }}"
no_log: true
tags: [certs, sites]
args:
apply:
tags: [certs, sites]
- name: Apache | Debian | Disabling default apache sites
ansible.builtin.file:
@ -120,6 +123,9 @@
- name: Apache | Debian | Removing status page
ansible.builtin.include_tasks: rm_status.yml
when: APACHE_CONFIG.status_page.state != 'present'
args:
apply:
tags: [config, sites, base]
tags: [config, sites, base]
- name: Apache | Debian | Removing site
@ -134,6 +140,9 @@
with_dict: "{{ APACHE_CONFIG.sites }}"
no_log: true
tags: [config, sites, certs]
args:
apply:
tags: [config, sites, certs]
- name: Apache | Debian | Reloading apache
ansible.builtin.systemd:
@ -159,6 +168,9 @@
with_dict: "{{ APACHE_CONFIG.sites }}"
no_log: true
tags: [config, sites, certs]
args:
apply:
tags: [config, sites, certs]
- name: Apache | Debian | Starting/Enabling apache
ansible.builtin.systemd: