Refactor wallabag stack name and repo variables
Brought in line with other stack naming schemes.
This commit is contained in:
parent
9cf43d0d5d
commit
a52cab2f61
6 changed files with 17 additions and 20 deletions
|
|
@ -15,28 +15,28 @@
|
|||
listen: "update wallabag upstream"
|
||||
|
||||
# figure out if upstream id exists
|
||||
- name: check {{ stack.name }} upstream
|
||||
- name: check {{ stack_name }} upstream
|
||||
community.docker.docker_container_exec:
|
||||
container: "{{ caddy_container_id }}"
|
||||
command: >
|
||||
curl localhost:2019/id/{{ stack.name }}_upstream/
|
||||
curl localhost:2019/id/{{ stack_name }}_upstream/
|
||||
changed_when: False
|
||||
register: result
|
||||
become: true
|
||||
listen: "update wallabag upstream"
|
||||
|
||||
# upstream already exists, patch it
|
||||
- name: remove old {{ stack.name }} upstream
|
||||
- name: remove old {{ stack_name }} upstream
|
||||
community.docker.docker_container_exec:
|
||||
container: "{{ caddy_container_id }}"
|
||||
command: >
|
||||
curl -X DELETE localhost:2019/id/{{ stack.name }}_upstream/
|
||||
curl -X DELETE localhost:2019/id/{{ stack_name }}_upstream/
|
||||
become: true
|
||||
when: (result.stdout | from_json)['error'] is not defined
|
||||
listen: "update wallabag upstream"
|
||||
|
||||
# upstream has to be created
|
||||
- name: add {{ stack.name }} upstream
|
||||
- name: add {{ stack_name }} upstream
|
||||
community.docker.docker_container_exec:
|
||||
container: "{{ caddy_container_id }}"
|
||||
command: >
|
||||
|
|
@ -50,4 +50,3 @@
|
|||
state: absent
|
||||
become: true
|
||||
listen: "update wallabag upstream"
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue