mirror of
https://github.com/hanzo-io/cloud.git
synced 2026-10-30 18:57:42 +00:00
For "primary-primary" replication - Also remove the job on failover - Use a playbook for this purpose for everything else
26 lines
496 B
YAML
26 lines
496 B
YAML
---
|
|
- name: Up secondary proxy to serve requests
|
|
hosts: all
|
|
become: yes
|
|
become_user: root
|
|
gather_facts: no
|
|
|
|
tasks:
|
|
- name: Ensure nginx is enabled and running
|
|
service:
|
|
name: nginx
|
|
enabled: yes
|
|
state: started
|
|
|
|
- name: Reload nginx
|
|
service:
|
|
name: nginx
|
|
state: reloaded
|
|
|
|
- name: Remove cron to reload nginx every 5 mins
|
|
become: yes
|
|
become_user: frappe
|
|
cron:
|
|
name: reload_nginx
|
|
state: absent
|