Dzahn has uploaded a new change for review.

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

Change subject: role/lists: rename prod role, move to module/role
......................................................................

role/lists: rename prod role, move to module/role

- move role classes to module/role
- rename ::server class to match description and to fit
  into this scheme avoiding the limitation of the role keyword
- move into autoloader layout
- minimal docs / lint-fix

Change-Id: I4834b14053c5f799b3df4514188fbbec0d9a806e
---
A modules/role/manifests/lists/migration.pp
R modules/role/manifests/lists/server.pp
2 files changed, 62 insertions(+), 60 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/39/271739/1

diff --git a/modules/role/manifests/lists/migration.pp 
b/modules/role/manifests/lists/migration.pp
new file mode 100644
index 0000000..fdb4937
--- /dev/null
+++ b/modules/role/manifests/lists/migration.pp
@@ -0,0 +1,60 @@
+# sets up rsync for a migration of a
+# mailman installation to a new server
+class role::lists::migration {
+
+    $sourceip='208.80.154.61'
+
+    ferm::service { 'mailman-http':
+        proto => 'tcp',
+        port  => '80',
+    }
+
+    ferm::service { 'mailman-migration-rysnc':
+        proto  => 'tcp',
+        port   => '873',
+        srange => "${sourceip}/32",
+    }
+
+    include rsync::server
+
+    rsync::server::module { 'lists':
+        path        => '/var/lib/mailman/lists',
+        read_only   => 'no',
+        hosts_allow => $sourceip,
+    }
+
+    rsync::server::module { 'archives':
+        path        => '/var/lib/mailman/archives',
+        read_only   => 'no',
+        hosts_allow => $sourceip,
+    }
+
+    rsync::server::module { 'data':
+        path        => '/var/lib/mailman/data',
+        read_only   => 'no',
+        hosts_allow => $sourceip,
+    }
+
+    rsync::server::module { 'qfiles':
+        path        => '/var/lib/mailman/qfiles',
+        read_only   => 'no',
+        hosts_allow => $sourceip,
+    }
+
+    rsync::server::module { 'exim':
+        path        => '/var/spool/exim4',
+        read_only   => 'no',
+        hosts_allow => $sourceip,
+    }
+
+    package { 'mailman':
+        ensure => 'present',
+    }
+
+    service { 'mailman':
+        ensure => 'stopped',
+    }
+
+    include mailman::scripts
+
+}
diff --git a/manifests/role/lists.pp b/modules/role/manifests/lists/server.pp
similarity index 78%
rename from manifests/role/lists.pp
rename to modules/role/manifests/lists/server.pp
index 9169ba7..433ec00 100644
--- a/manifests/role/lists.pp
+++ b/modules/role/manifests/lists/server.pp
@@ -1,8 +1,8 @@
-class role::lists {
+class role::lists::server {
     include network::constants
     include base::firewall
 
-    system::role { 'role::mail::lists':
+    system::role { 'role::lists::server':
         description => 'Mailing list server',
     }
 
@@ -167,61 +167,3 @@
     }
 }
 
-class role::lists::migration {
-
-    $sourceip='208.80.154.61'
-
-    ferm::service { 'mailman-http':
-        proto => 'tcp',
-        port  => '80',
-    }
-
-    ferm::service { 'mailman-migration-rysnc':
-        proto  => 'tcp',
-        port   => '873',
-        srange => "${sourceip}/32",
-    }
-
-    include rsync::server
-
-    rsync::server::module { 'lists':
-        path        => '/var/lib/mailman/lists',
-        read_only   => 'no',
-        hosts_allow => $sourceip,
-    }
-
-    rsync::server::module { 'archives':
-        path        => '/var/lib/mailman/archives',
-        read_only   => 'no',
-        hosts_allow => $sourceip,
-    }
-
-    rsync::server::module { 'data':
-        path        => '/var/lib/mailman/data',
-        read_only   => 'no',
-        hosts_allow => $sourceip,
-    }
-
-    rsync::server::module { 'qfiles':
-        path        => '/var/lib/mailman/qfiles',
-        read_only   => 'no',
-        hosts_allow => $sourceip,
-    }
-
-    rsync::server::module { 'exim':
-        path        => '/var/spool/exim4',
-        read_only   => 'no',
-        hosts_allow => $sourceip,
-    }
-
-    package { 'mailman':
-        ensure => 'present',
-    }
-
-    service { 'mailman':
-        ensure => 'stopped',
-    }
-
-    include mailman::scripts
-
-}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4834b14053c5f799b3df4514188fbbec0d9a806e
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn <dz...@wikimedia.org>

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

Reply via email to