Shorted cleanup- to cln-

This commit is contained in:
2025-07-09 03:45:02 +02:00
parent 9668e74139
commit f548faa80f
60 changed files with 88 additions and 88 deletions

View File

@@ -0,0 +1,20 @@
---
- name: Find matching nginx configs for {{ domain }}
ansible.builtin.find:
paths: "{{ nginx.directories.http.servers }}"
patterns: "*.{{ domain }}.conf"
register: find_result
- name: Remove wildcard nginx configs for {{ domain }}
ansible.builtin.file:
path: "{{ item.path }}"
state: absent
loop: "{{ find_result.files | default([]) }}"
when: item is defined
notify: restart nginx
- name: Remove exact nginx config for {{ domain }}
ansible.builtin.file:
path: "{{ nginx.directories.http.servers }}{{ domain }}.conf"
state: absent
notify: restart nginx