add renwe https tasks

This commit is contained in:
2023-09-24 04:54:00 +02:00
parent 3777a5195d
commit cece6892ab

View File

@@ -72,6 +72,61 @@
- docker-compose
- bootstrap_dockerapp_configure_docker_compose
- name: uncomment acme.caserver line
ansible.builtin.lineinfile:
path: /etc/sudoers
state: absent
regexp: '^%wheel'
tags:
- renew-httos
- name: remove appdata/traefik2/acme/letsencrypt/acme.json file
file:
path: "{{ dockerapp_tree_base_dir | last }}/{{ dockerapp_service }}/appdata/traefik2/acme/letsencrypt/acme.json"
state: absent
tags:
- renew-https
- name: Run `docker-compose down`
community.docker.docker_compose:
project_src: "{{ dockerapp_tree_base_dir | last }}/{{ dockerapp_service }}/docker-compose.yml"
state: absent
tags:
- renew-https
- name: Run `docker-compose up`
community.docker.docker_compose:
project_src: "{{ dockerapp_tree_base_dir | last }}/{{ dockerapp_service }}/docker-compose.yml"
build: false
tags:
- renew-https
- name: Wait 5 minutes for news cert/key on acme.json (stagging)
pause:
seconds: 300
tags:
- renew-https
- name: comment acme.caserver line
ansible.builtin.lineinfile:
path: /etc/sudoers
state: absent
regexp: '^%wheel'
tags:
- renew-https
- name: remove appdata/traefik2/acme/letsencrypt/acme.json file
file:
path: "{{ dockerapp_tree_base_dir | last }}/{{ dockerapp_service }}/appdata/traefik2/acme/letsencrypt/acme.json"
state: absent
tags:
- renew-https
- name: Run `docker-compose restart traefik`
community.docker.docker_compose:
project_src: "{{ dockerapp_tree_base_dir | last }}/{{ dockerapp_service }}/docker-compose.yml"
restarted: true
services:
- traefik
tags:
- renew-https