Commit c7a9c229 by Joseph Mulloy

Parameterize and change gocd cron time OPS-3004

parent 72cbdcea
...@@ -82,6 +82,8 @@ GO_SERVER_BACKUP_PIP_PKGS: ["boto", "awscli"] ...@@ -82,6 +82,8 @@ GO_SERVER_BACKUP_PIP_PKGS: ["boto", "awscli"]
GO_SERVER_BACKUP_API_URL: "http://localhost:8153/go/api/backups" GO_SERVER_BACKUP_API_URL: "http://localhost:8153/go/api/backups"
GO_SERVER_BACKUP_TMP_LOCATION: "/tmp/{{ GO_SERVER_BACKUP_FILENAME }}" GO_SERVER_BACKUP_TMP_LOCATION: "/tmp/{{ GO_SERVER_BACKUP_FILENAME }}"
GO_SERVER_BACKUP_CRON_SCRIPT_LOCATION: "/root/gocd_backup.sh" GO_SERVER_BACKUP_CRON_SCRIPT_LOCATION: "/root/gocd_backup.sh"
GO_SERVER_BACKUP_CRON_HOUR: "23"
GO_SERVER_BACKUP_CRON_MINUTE: "58"
# When "true", attempts to restore go-server backup from S3. # When "true", attempts to restore go-server backup from S3.
GO_SERVER_RESTORE_BACKUP: false GO_SERVER_RESTORE_BACKUP: false
......
...@@ -52,6 +52,6 @@ ...@@ -52,6 +52,6 @@
- name: create cron entry - name: create cron entry
cron: cron:
name: "gocd backup" name: "gocd backup"
minute: 0 minute: "{{ GO_SERVER_BACKUP_CRON_MINUTE }}"
hour: 3 hour: "{{ GO_SERVER_BACKUP_CRON_HOUR }}"
job: "{{ GO_SERVER_BACKUP_CRON_SCRIPT_LOCATION }} 2>&1 | /usr/bin/logger -t gocd_backup" job: "{{ GO_SERVER_BACKUP_CRON_SCRIPT_LOCATION }} 2>&1 | /usr/bin/logger -t gocd_backup"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment