ArielGlenn has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/281913

Change subject: small fixes for dumps cron job script
......................................................................

small fixes for dumps cron job script

eliminate whines about comparison of empty string in cron dump script
make sure we chdir to the repo dir before running dump commands

Change-Id: I7b926197fde9240b5d61e56723924092ad3ee902
---
M modules/snapshot/templates/dumps/fulldumps.sh.erb
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/13/281913/1

diff --git a/modules/snapshot/templates/dumps/fulldumps.sh.erb 
b/modules/snapshot/templates/dumps/fulldumps.sh.erb
index 7e20d66..e9795e1 100644
--- a/modules/snapshot/templates/dumps/fulldumps.sh.erb
+++ b/modules/snapshot/templates/dumps/fulldumps.sh.erb
@@ -38,7 +38,7 @@
 getcommandargs(){
     slots="$1"
     stagesfile="$2"
-    commandargs="${repodir}/dumpscheduler.py --slots ${slots} --commands 
${dumpsdir}/stages/${stagesfile} --cache ${dumpsdir}/cache/running_cache.txt 
--directory $dumpsdir"
+    commandargs="${repodir}/dumpscheduler.py --slots ${slots} --commands 
${dumpsdir}/stages/${stagesfile} --cache ${dumpsdir}/cache/running_cache.txt 
--directory $repodir"
 }
 
 maybe_do_createdirs(){
@@ -108,7 +108,7 @@
 fullpids=`pgrep -f fulldumps.sh`
 for pid in $fullpids; do
     pgroup=`ps --no-headers -o pgrp -p $pid`
-    if [ "$pgroup" -ne "$mypgroup" ]; then
+    if [ "$pgroup" != "$mypgroup" ]; then
         show "exiting because already running"
         exit 0
     fi

-- 
To view, visit https://gerrit.wikimedia.org/r/281913
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7b926197fde9240b5d61e56723924092ad3ee902
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: ArielGlenn <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to