Reintroduce the handlers for the secret management.
This commit is contained in:
parent
328f34f518
commit
2e1f1cbc30
|
@ -4,7 +4,7 @@
|
|||
# https://github.com/openanalytics/shinyproxy-config-examples
|
||||
shinyproxy_install: true
|
||||
shinyproxy_as_docker_service: false
|
||||
shinyproxy_docker_privileged_user: false
|
||||
shinyproxy_docker_privileged_user: true
|
||||
shinyproxy_major_ver: 3
|
||||
shinyproxy_minor_ver: 0
|
||||
shinyproxy_patch_ver: 2
|
||||
|
|
|
@ -3,3 +3,13 @@
|
|||
ansible.builtin.service:
|
||||
name: shinyproxy
|
||||
state: restarted
|
||||
- name: Stop the shinyproxy service
|
||||
community.docker.docker_swarm_service:
|
||||
name: "{{ shinyproxy_as_docker_stack_name }}_{{ shinyproxy_as_docker_service_name }}"
|
||||
state: absent
|
||||
|
||||
- name: Create the secret for the application.yml file
|
||||
community.docker.docker_secret:
|
||||
name: "{{ shinyproxy_as_docker_stack_name }}_{{ shinyproxy_as_docker_service_name }}"
|
||||
data_src: '{{ shinyproxy_as_docker_src_dir }}/application.yml'
|
||||
state: present
|
||||
|
|
|
@ -37,20 +37,9 @@
|
|||
owner: root
|
||||
group: root
|
||||
mode: "0400"
|
||||
register: shinyproxy_conf_file
|
||||
|
||||
- name: shinyproxy_docker_stack_service | Stop the shinyproxy service {{ shinyproxy_as_docker_stack_name }}_{{ shinyproxy_as_docker_service_name }} # noqa: name[template] noqa: yaml[line-length]
|
||||
community.docker.docker_swarm_service:
|
||||
name: "{{ shinyproxy_as_docker_stack_name }}_{{ shinyproxy_as_docker_service_name }}"
|
||||
state: absent
|
||||
when: shinyproxy_conf_file is changed # noqa: no-handler
|
||||
|
||||
- name: shinyproxy_docker_stack_service | Create the secret for the application.yml file
|
||||
community.docker.docker_secret:
|
||||
name: "{{ shinyproxy_as_docker_stack_name }}_{{ shinyproxy_as_docker_service_name }}"
|
||||
data_src: '{{ shinyproxy_as_docker_src_dir }}/application.yml'
|
||||
state: present
|
||||
when: shinyproxy_conf_file is changed # noqa: no-handler
|
||||
notify:
|
||||
- Stop the shinyproxy service
|
||||
- Create the secret for the application.yml file
|
||||
|
||||
- name: shinyproxy_docker_stack_service | Start the shinyproxy stack
|
||||
community.docker.docker_stack:
|
||||
|
|
Loading…
Reference in New Issue