[FIX] Starte Gitea neu, wenn die Config geändert wurde
This commit is contained in:
parent
6817fe0ff9
commit
e8e05f8391
@ -20,6 +20,11 @@
|
|||||||
- Backup Gitea
|
- Backup Gitea
|
||||||
register: backup
|
register: backup
|
||||||
|
|
||||||
|
- name: Ensure Gitea is restarted
|
||||||
|
community.docker.docker_compose:
|
||||||
|
project_src: /opt/gitea
|
||||||
|
restarted: true
|
||||||
|
|
||||||
- name: Ensure Gitea is running
|
- name: Ensure Gitea is running
|
||||||
community.docker.docker_compose:
|
community.docker.docker_compose:
|
||||||
project_src: /opt/gitea
|
project_src: /opt/gitea
|
||||||
|
@ -70,6 +70,9 @@
|
|||||||
dest: "/opt/gitea/environment.env"
|
dest: "/opt/gitea/environment.env"
|
||||||
owner: root
|
owner: root
|
||||||
mode: "600"
|
mode: "600"
|
||||||
|
notify:
|
||||||
|
- Ensure Gitea is restarted
|
||||||
|
- Check Gitea HTTP Response
|
||||||
|
|
||||||
- name: Upload docker-compose.yaml
|
- name: Upload docker-compose.yaml
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
@ -79,21 +82,13 @@
|
|||||||
mode: "600"
|
mode: "600"
|
||||||
notify:
|
notify:
|
||||||
- Output Docker Compose State
|
- Output Docker Compose State
|
||||||
|
- Ensure Gitea is restarted
|
||||||
|
- Check Gitea HTTP Response
|
||||||
|
|
||||||
- name: Try to start and reach Gitea
|
- name: Update Config
|
||||||
block:
|
block:
|
||||||
|
- name:
|
||||||
- name: Start Gitea
|
meta: flush_handlers
|
||||||
community.docker.docker_compose:
|
|
||||||
project_src: /opt/gitea
|
|
||||||
|
|
||||||
- name: Check if {{ gitea.hostname }}.{{ gitea.domain }} is available and returning status 200
|
|
||||||
ansible.builtin.uri:
|
|
||||||
url: "https://{{ gitea.hostname }}.{{ gitea.domain }}"
|
|
||||||
register: _result
|
|
||||||
until: _result.status == 200
|
|
||||||
retries: 30
|
|
||||||
delay: 2
|
|
||||||
|
|
||||||
rescue:
|
rescue:
|
||||||
- name: Stop Gitea for Backup
|
- name: Stop Gitea for Backup
|
||||||
|
Loading…
Reference in New Issue
Block a user