Hashar has uploaded a new change for review.

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


Change subject: deployment: abstract out MW_RSYNC_HOST
......................................................................

deployment: abstract out MW_RSYNC_HOST

Hack up the deployment var class to let beta uses a different MediaWiki
synchronization host.  The 'if $::realm' is not clever, but I am not
really willing to refactor the messy deployment manifests.

Change-Id: I3eb5b5c4e7f255c83758d96f5999980c5cf7f31b
---
M manifests/misc/deployment.pp
M templates/misc/mw-deployment-vars.erb
2 files changed, 8 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/91/72491/1

diff --git a/manifests/misc/deployment.pp b/manifests/misc/deployment.pp
index d57a25d..2ae1f96 100644
--- a/manifests/misc/deployment.pp
+++ b/manifests/misc/deployment.pp
@@ -373,6 +373,13 @@
                $dblist_common = $mw_common
                $dblist_common_source = $mw_common_source
        }
+
+       if $::realm == 'production' {
+               $mw_rsync_host = 'tin.eqiad.wmnet'
+       } else {
+               $mw_rsync_host = 'deployment-bastion.pmtpa.wmflabs'
+       }
+
        file {
                "/usr/local/lib/mw-deployment-vars.sh":
                        owner => root,
diff --git a/templates/misc/mw-deployment-vars.erb 
b/templates/misc/mw-deployment-vars.erb
index 4b43af0..deae390 100644
--- a/templates/misc/mw-deployment-vars.erb
+++ b/templates/misc/mw-deployment-vars.erb
@@ -3,6 +3,6 @@
 MW_DBLISTS=<%= dblist_common %>
 MW_DBLISTS_SOURCE=<%= dblist_common_source %>
 MW_CRON_LOGS=/home/wikipedia/logs/norotate
-MW_RSYNC_HOST=tin.eqiad.wmnet
+MW_RSYNC_HOST=<%= mw_rsync_host %>
 MW_DSH_ARGS=('-cM' '-g' 'mediawiki-installation' '-o' '-oSetupTimeout=30' 
'-F30')
 MW_RSYNC_ARGS=('-a' '--delete' '--exclude=**/.svn/lock' 
'--exclude=**/.git/objects' '--exclude=**/.git/**/objects' '--no-perms')

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

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

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

Reply via email to