Browse Source

ansible: add fallback for gunicorn_reloader.path service

merge-requests/157/head
Andrew Shu 6 months ago
parent
commit
504b0c6b87
  1. 11
      ansible/roles/gunicorn/tasks/main.yml

11
ansible/roles/gunicorn/tasks/main.yml

@ -47,8 +47,17 @@
group: root
mode: 0644
- name: Start and enable gunicorn_reloader path-monitoring service, with fallback
block:
- name: Start and enable gunicorn_reloader path-monitoring service
service:
systemd_service:
name: gunicorn_reloader.path
state: started
enabled: true
rescue:
# Likely Docker; systemctl3.py doesn't support .path, so enable .service here
- name: Start and enable gunicorn.service (if .path service fails)
systemd_service:
name: gunicorn.service
state: started
enabled: true
Loading…
Cancel
Save