ArielGlenn has uploaded a new change for review.

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

Change subject: dumps: move all dumps-related dir decls to the dirs class
......................................................................

dumps: move all dumps-related dir decls to the dirs class

Change-Id: Idb387c03396c6aaa2c2c50d89bbcfb8866aa1787
---
M modules/snapshot/manifests/dirs.pp
M modules/snapshot/manifests/dumps/dblists.pp
M modules/snapshot/manifests/dumps/stagesconfig.pp
M modules/snapshot/manifests/dumps/templates.pp
4 files changed, 41 insertions(+), 30 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/86/276786/1

diff --git a/modules/snapshot/manifests/dirs.pp 
b/modules/snapshot/manifests/dirs.pp
index c200f1a..cced057 100644
--- a/modules/snapshot/manifests/dirs.pp
+++ b/modules/snapshot/manifests/dirs.pp
@@ -6,11 +6,51 @@
     file { $dumpsdir:
         ensure => 'directory',
         path   => $dumpsdir,
-        mode   => '0644',
+        mode   => '0755',
         owner  => 'root',
         group  => 'root',
     }
 
+    file { "${dumpsdir}/confs":
+      ensure => 'directory',
+      path   => "${dumpsdir}/confs",
+      mode   => '0755',
+      owner  => 'root',
+      group  => 'root',
+    }
+
+    file { "${dumpsdir}/dblists":
+      ensure => 'directory',
+      path   => "${dumpsdir}/dblists",
+      mode   => '0755',
+      owner  => 'root',
+      group  => 'root',
+    }
+
+    file { "${dumpsdir}/stages":
+      ensure => 'directory',
+      path   => "${dumpsdir}/stages",
+      mode   => '0755',
+      owner  => 'root',
+      group  => 'root',
+    }
+
+    file { "${dumpsdir}/cache":
+      ensure => 'directory',
+      path   => "${dumpsdir}/cache",
+      mode   => '0755',
+      owner  => 'datasets',
+      group  => 'root',
+    }
+
+    file { "${snapshot::dirs::dumpsdir}/templs":
+      ensure => 'directory',
+      path   => "${snapshot::dirs::dumpsdir}/templs",
+      mode   => '0755',
+      owner  => 'root',
+      group  => 'root',
+    }
+
     $addschangesdir = '/srv/addschanges'
 
     file { $addschangesdir:
diff --git a/modules/snapshot/manifests/dumps/dblists.pp 
b/modules/snapshot/manifests/dumps/dblists.pp
index 0a6a274..7a68f88 100644
--- a/modules/snapshot/manifests/dumps/dblists.pp
+++ b/modules/snapshot/manifests/dumps/dblists.pp
@@ -20,13 +20,6 @@
 
         include snapshot::dirs
 
-        file { "${snapshot::dirs::dumpsdir}/dblists":
-            ensure => 'directory',
-            path   => "${snapshot::dirs::dumpsdir}/dblists",
-            mode   => '0755',
-            owner  => 'root',
-            group  => 'root',
-        }
         if ($hugewikis_enable) {
             # this host will run enwiki dumps
             file { "${snapshot::dirs::dumpsdir}/dblists/hugewikis.dblist":
diff --git a/modules/snapshot/manifests/dumps/stagesconfig.pp 
b/modules/snapshot/manifests/dumps/stagesconfig.pp
index 2f9482b..eccbc0a 100644
--- a/modules/snapshot/manifests/dumps/stagesconfig.pp
+++ b/modules/snapshot/manifests/dumps/stagesconfig.pp
@@ -34,21 +34,6 @@
     }
 
     if ($enable) {
-        file { "${snapshot::dirs::dumpsdir}/stages":
-            ensure => 'directory',
-            path   => "${snapshot::dirs::dumpsdir}/stages",
-            mode   => '0755',
-            owner  => 'root',
-            group  => 'root',
-        }
-        file { "${snapshot::dirs::dumpsdir}/cache":
-            ensure => 'directory',
-            path   => "${snapshot::dirs::dumpsdir}/cache",
-            mode   => '0755',
-            owner  => 'datasets',
-            group  => 'root',
-        }
-
         snapshot::dumps::stagesconf { 'stages_normal':
             stagestype => 'normal',
             stages     => $stages,
diff --git a/modules/snapshot/manifests/dumps/templates.pp 
b/modules/snapshot/manifests/dumps/templates.pp
index c45a1a0..0252d3e 100644
--- a/modules/snapshot/manifests/dumps/templates.pp
+++ b/modules/snapshot/manifests/dumps/templates.pp
@@ -3,13 +3,6 @@
 
         include snapshot::dirs
 
-        file { "${snapshot::dirs::dumpsdir}/templs":
-            ensure => 'directory',
-            path   => "${snapshot::dirs::dumpsdir}/templs",
-            mode   => '0755',
-            owner  => 'root',
-            group  => 'root',
-        }
         file { "${snapshot::dirs::dumpsdir}/templs/download-index.html":
             ensure => 'present',
             path   => "${snapshot::dirs::dumpsdir}/templs/download-index.html",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idb387c03396c6aaa2c2c50d89bbcfb8866aa1787
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