From: rominique Date: Thu, 29 Aug 2024 09:57:17 +0000 (+0200) Subject: ajout certif domain.tld X-Git-Url: http://git.cyclocoop.org/data/%7B%7B%20url_for%28%27static%27%2C%20filename=%27js/%27.generer_url_public%28?a=commitdiff_plain;h=f05b2ae3135b143e59f9d28be04c9eb057b3e178;p=lhc%2Fansible.git ajout certif domain.tld --- diff --git a/creation_nouveau_site.yml b/creation_nouveau_site.yml index 48caac2..dc0d713 100644 --- a/creation_nouveau_site.yml +++ b/creation_nouveau_site.yml @@ -85,6 +85,15 @@ register: certbot_log ignore_errors: true changed_when: false + when: config_ss_domain != 'www' + + - name: Générer un certififat avec certbot # noqa : command-instead-of-module + become: true + ansible.builtin.command: 'certbot certonly -n --nginx -d {{ DOMAIN }}.{{ TLD }} -d {{ config_ss_domain | default(SITE) }}.{{ DOMAIN }}.{{ TLD }}' + register: certbot_log + ignore_errors: true + changed_when: false + when: config_ss_domain == 'www' - name: Afficher les logs certbot ansible.builtin.debug: