From a73e9d7b62f5ac5e5c0d30e45e730e2d174292ba Mon Sep 17 00:00:00 2001 From: Ralph Bean Date: Thu, 10 Aug 2017 14:23:51 +0000 Subject: [PATCH] Apply locks to the owner-sync cronjob. --- roles/bodhi2/backend/tasks/main.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/roles/bodhi2/backend/tasks/main.yml b/roles/bodhi2/backend/tasks/main.yml index f1e06bdeab..770785d615 100644 --- a/roles/bodhi2/backend/tasks/main.yml +++ b/roles/bodhi2/backend/tasks/main.yml @@ -146,7 +146,7 @@ - name: sync packages from pagure-on-dist-git to koji (el6) cron: name="owner-sync-el6" minute="7,17,27,37,47,57" user="root" - job="/usr/local/bin/owner-sync-pagure dist-6E-epel" + job="/usr/local/bin/lock-wrapper owner-sync-el6 /usr/local/bin/owner-sync-pagure dist-6E-epel" cron_file=update-koji-owner-EL-6 when: inventory_hostname.startswith('bodhi-backend01') and env == "production" tags: @@ -155,7 +155,7 @@ - name: sync packages from pagure-on-dist-git to koji (epel7) cron: name="owner-sync-epel7" minute="7,17,27,37,47,57" user="root" - job="/usr/local/bin/owner-sync-pagure epel7" + job="/usr/local/bin/lock-wrapper owner-sync-epel7 /usr/local/bin/owner-sync-pagure epel7" cron_file=update-koji-owner-epel7 when: inventory_hostname.startswith('bodhi-backend01') and env == "production" tags: @@ -164,7 +164,7 @@ - name: sync packages from pagure-on-dist-git to koji fedora cron: name="owner-sync-fedora" minute="7,17,27,37,47,57" user="root" - job="/usr/local/bin/owner-sync-pagure f25;/usr/local/bin/owner-sync-pagure f26;/usr/local/bin/owner-sync-pagure f27" + job="/usr/local/bin/lock-wrapper owner-sync-fedora /usr/local/bin/owner-sync-pagure f25;/usr/local/bin/owner-sync-pagure f26;/usr/local/bin/owner-sync-pagure f27" cron_file=update-koji-owner-fedora when: inventory_hostname.startswith('bodhi-backend01') and env == "production" tags: @@ -172,8 +172,8 @@ - cron - name: sync packages from pagure-on-dist-git to koji fedora (container) - cron: name="owner-sync-fedora" minute="7,17,27,37,47,57" user="root" - job="/usr/local/bin/owner-sync-pagure f25-container;/usr/local/bin/owner-sync-pagure f26-container;/usr/local/bin/owner-sync-pagure f27-container" + cron: name="owner-sync-fedora-container" minute="7,17,27,37,47,57" user="root" + job="/usr/local/bin/lock-wrapper owner-sync-fedora-container /usr/local/bin/owner-sync-pagure f25-container;/usr/local/bin/owner-sync-pagure f26-container;/usr/local/bin/owner-sync-pagure f27-container" cron_file=update-koji-owner-fedora-container when: inventory_hostname.startswith('bodhi-backend01') and env == "production" tags: @@ -183,7 +183,7 @@ # See https://pagure.io/releng/issue/6663 and https://pagure.io/fm-orchestrator/issue/333 - name: sync packages from pagure-on-dist-git to koji fedora (modules) cron: name="owner-sync-modules" minute="9,19,29,39,49,59" user="root" - job="/usr/local/bin/owner-sync-pagure module-package-list" + job="/usr/local/bin/lock-wrapper owner-sync-modules /usr/local/bin/owner-sync-pagure module-package-list" cron_file=update-koji-owner-modules when: inventory_hostname.startswith('bodhi-backend01') and env == "production" tags: