ArielGlenn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/332390 )

Change subject: turn on ezachte rsync to other/media on dataset1001
......................................................................


turn on ezachte rsync to other/media on dataset1001

Change-Id: Ic86ae12cd39aed076e54b96b0fd582cbbe54a6be
---
M modules/dataset/files/rsync/rsyncd.conf.media
M modules/dataset/manifests/init.pp
A modules/dataset/manifests/rsync/media.pp
M modules/role/manifests/dataset/primary.pp
4 files changed, 29 insertions(+), 1 deletion(-)

Approvals:
  ArielGlenn: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/dataset/files/rsync/rsyncd.conf.media 
b/modules/dataset/files/rsync/rsyncd.conf.media
index 9e5df8d..68c321b 100644
--- a/modules/dataset/files/rsync/rsyncd.conf.media
+++ b/modules/dataset/files/rsync/rsyncd.conf.media
@@ -1,5 +1,6 @@
 #####################################################################
 ### Note: This file is managed by Puppet.
+### puppet:///modules/dataset/rsync/rsyncd.conf.media
 #####################################################################
 
 # write access from stat1002 and stat1003 to media directory.
diff --git a/modules/dataset/manifests/init.pp 
b/modules/dataset/manifests/init.pp
index c60f017..83090d4 100644
--- a/modules/dataset/manifests/init.pp
+++ b/modules/dataset/manifests/init.pp
@@ -7,6 +7,8 @@
     #            'labs'   for rsync of some dumps to labs public fileshare
     #    $uploads: 'pagecounts_ez' to allow the corresponding rsync
     #              to those directories from the appropriate hosts
+    #              'media' to allow the corresponding rsync
+    #              to other/media from the appropriate hosts
     #              'phab' for rsync of phabricator dump from hosts that have it
     #    $grabs: 'kiwix' to copy kiwix (offline wiki) tarballs from upstream
     #            to local filesystem
@@ -50,5 +52,9 @@
     $grabs_kiwix_enable = has_key($grabs,'kiwix')
     class { '::dataset::cron::kiwix': enable => $grabs_kiwix_enable }
 
+    $uploads_media = has_key($uploads,'media')
+    class { '::dataset::rsync::media':
+        enable => $uploads_media }
+
     include ::dataset::html
 }
diff --git a/modules/dataset/manifests/rsync/media.pp 
b/modules/dataset/manifests/rsync/media.pp
new file mode 100644
index 0000000..0db4da9
--- /dev/null
+++ b/modules/dataset/manifests/rsync/media.pp
@@ -0,0 +1,20 @@
+class dataset::rsync::media($enable=true) {
+    if ($enable) {
+        $ensure = 'present'
+    }
+    else {
+        $ensure = 'absent'
+    }
+
+    include ::dataset::common
+    include ::dataset::rsync::common
+
+    file { '/etc/rsyncd.d/30-rsync-media.conf':
+        ensure => $ensure,
+        mode   => '0444',
+        owner  => 'root',
+        group  => 'root',
+        source => 'puppet:///modules/dataset/rsync/rsyncd.conf.media',
+        notify => Exec['update-rsyncd.conf'],
+    }
+}
diff --git a/modules/role/manifests/dataset/primary.pp 
b/modules/role/manifests/dataset/primary.pp
index d40dbea..f700fe3 100644
--- a/modules/role/manifests/dataset/primary.pp
+++ b/modules/role/manifests/dataset/primary.pp
@@ -20,7 +20,8 @@
     }
     $uploads = {
         'pagecounts_ez' => true,
-        'phab'       => true,
+        'phab'          => true,
+        'media'         => true,
     }
     class { 'dataset':
         rsync   => $rsync,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic86ae12cd39aed076e54b96b0fd582cbbe54a6be
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: ArielGlenn <ar...@wikimedia.org>
Gerrit-Reviewer: ArielGlenn <ar...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to