Rush has submitted this change and it was merged.
Change subject: Install the scap package from deb instead of trebuchet
......................................................................
Install the scap package from deb instead of trebuchet
This was previously reverted (Iaa518889fa2c8b3d81db9e466cb63d0fcbc30cc4)
Now it's been tested on deployment-tin and it needs to get re-re-verted
This switches scap to use the apt provider and fixes paths to point to
`/usr/bin/$binary` instead of `/srv/deployment/scap/scap/bin/$binary`
Bug: T114363
Change-Id: I7dd552056c6ad58164e44b77e0c20e15daac2a0b
---
M modules/mediawiki/manifests/scap.pp
M modules/mediawiki/templates/mediawiki.sh.erb
M modules/restbase/manifests/deploy.pp
M modules/scap/files/l10nupdate-1
M modules/scap/manifests/init.pp
M modules/scap/manifests/l10nupdate.pp
M modules/scap/templates/mw-deployment-vars.erb
7 files changed, 7 insertions(+), 20 deletions(-)
Approvals:
Thcipriani: Looks good to me, but someone else must approve
Rush: Looks good to me, approved
jenkins-bot: Verified
diff --git a/modules/mediawiki/manifests/scap.pp
b/modules/mediawiki/manifests/scap.pp
index 6a61609..8702c0d 100644
--- a/modules/mediawiki/manifests/scap.pp
+++ b/modules/mediawiki/manifests/scap.pp
@@ -12,7 +12,7 @@
$mediawiki_deployment_dir = '/srv/mediawiki'
$mediawiki_staging_dir = '/srv/mediawiki-staging'
- $scap_bin_dir = '/srv/deployment/scap/scap/bin'
+ $scap_bin_dir = '/usr/bin'
$mediawiki_web_user = $::mediawiki::users::web
# /srv/mediawiki is the root path of the MediaWiki deployment tree.
diff --git a/modules/mediawiki/templates/mediawiki.sh.erb
b/modules/mediawiki/templates/mediawiki.sh.erb
index 0aa6eac..1b16432 100644
--- a/modules/mediawiki/templates/mediawiki.sh.erb
+++ b/modules/mediawiki/templates/mediawiki.sh.erb
@@ -9,6 +9,7 @@
# into scap.
if groups | grep -Pqw '(wikidev|l10nupdate)'; then
- PATH="${PATH}:/srv/deployment/scap/scap/bin"
+ # scap is now in /usr/bin thanks to debian package 'scap'
+ # PATH="${PATH}:/srv/deployment/scap/scap/bin"
umask 0002
fi
diff --git a/modules/restbase/manifests/deploy.pp
b/modules/restbase/manifests/deploy.pp
index f5d7d89..45cd3f3 100644
--- a/modules/restbase/manifests/deploy.pp
+++ b/modules/restbase/manifests/deploy.pp
@@ -29,14 +29,6 @@
source => $public_key_file,
}
- # Using trebuchet provider while scap service deployment is under
- # developmentāchicken and egg things
- #
- # This should be removed once scap3 is in a final state
- package { 'scap/scap':
- provider => 'trebuchet',
- }
-
# Rather than futz with adding new functionality to allow a deployment
# user set per repository in trebuchet, I'm running an exec here
$dir = '/srv/deployment/restbase/deploy'
diff --git a/modules/scap/files/l10nupdate-1 b/modules/scap/files/l10nupdate-1
index 52e48b5..7b0f6c8 100755
--- a/modules/scap/files/l10nupdate-1
+++ b/modules/scap/files/l10nupdate-1
@@ -7,7 +7,7 @@
. /etc/profile.d/mediawiki.sh
BINDIR=/usr/local/bin
-SCAPDIR=/srv/deployment/scap/scap/bin
+SCAPDIR=/usr/bin
# The configuration in CommonSettings.php should match GITDIR and GITREPOS
GITDIR=/var/lib/l10nupdate/mediawiki
GITURL=https://gerrit.wikimedia.org/r/p/mediawiki
diff --git a/modules/scap/manifests/init.pp b/modules/scap/manifests/init.pp
index 3a01956..07ebe45 100644
--- a/modules/scap/manifests/init.pp
+++ b/modules/scap/manifests/init.pp
@@ -3,14 +3,9 @@
# Common role for scap masters and targets
class scap {
- # Using trebuchet provider while scap service deployment is under
- # development -- chicken and egg things
- #
- # This should be removed once scap3 is in a final state (i.e. packaged
- # or deployed via another method)
+
package { 'scap':
- ensure => latest,
- provider => 'trebuchet',
+ ensure => '3.0.1-1',
}
file { '/etc/scap.cfg':
diff --git a/modules/scap/manifests/l10nupdate.pp
b/modules/scap/manifests/l10nupdate.pp
index 3d4ca08..91abdbf 100644
--- a/modules/scap/manifests/l10nupdate.pp
+++ b/modules/scap/manifests/l10nupdate.pp
@@ -64,7 +64,7 @@
# This command is equivalent to a restricted sync-dir call that
# only syncs l10n cache files followed by a scap-rebuild-cdbs
# call.
- 'ALL = (mwdeploy) NOPASSWD:
/srv/deployment/scap/scap/bin/sync-l10n',
+ 'ALL = (mwdeploy) NOPASSWD: /usr/bin/sync-l10n',
# Allow l10nupdate user to run anything as the unprivledged web
# user. Needed for mwscript actions and related operations.
"ALL = (${::mediawiki::users::web}) NOPASSWD: ALL",
diff --git a/modules/scap/templates/mw-deployment-vars.erb
b/modules/scap/templates/mw-deployment-vars.erb
index b0c9230..abd8da3 100644
--- a/modules/scap/templates/mw-deployment-vars.erb
+++ b/modules/scap/templates/mw-deployment-vars.erb
@@ -1,5 +1,4 @@
# This file should be BASH / Python polyglot.
-PATH="$PATH:/srv/deployment/scap/scap/bin"
MEDIAWIKI_DEPLOYMENT_DIR="<%= @common_path %>"
MEDIAWIKI_STAGING_DIR="<%= @common_source_path %>"
--
To view, visit https://gerrit.wikimedia.org/r/271442
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I7dd552056c6ad58164e44b77e0c20e15daac2a0b
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: 20after4 <[email protected]>
Gerrit-Reviewer: Alex Monk <[email protected]>
Gerrit-Reviewer: ArielGlenn <[email protected]>
Gerrit-Reviewer: Rush <[email protected]>
Gerrit-Reviewer: Thcipriani <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits