Jcrespo has submitted this change and it was merged.

Change subject: Setup the new labsdb hosts with a new role
......................................................................


Setup the new labsdb hosts with a new role

Bug: T140452
Change-Id: I2c0b24dc34048439b44548b317182b4ee7ceb9ff
---
M manifests/site.pp
A modules/role/manifests/labs/db/replica.pp
2 files changed, 33 insertions(+), 2 deletions(-)

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



diff --git a/manifests/site.pp b/manifests/site.pp
index 8187445..36d214c 100644
--- a/manifests/site.pp
+++ b/manifests/site.pp
@@ -1482,11 +1482,15 @@
 }
 
 ## labsdb dbs
-node /labsdb10(1[01]|0[1389])\.eqiad\.wmnet/ {
-    # this role is depecated and should be converted to labs::db::slave
+node /labsdb100[138]\.eqiad\.wmnet/ {
+    # this role is depecated and its nodes scheduled for decom
     role mariadb::labs
 }
 
+node /labsdb10(09|10|11)\.eqiad\.wmnet/ {
+    role labs::db::replica
+}
+
 node 'labsdb1004.eqiad.wmnet' {
     # Bug: T101233
     #$postgres_slave = 'labsdb1005.eqiad.wmnet'
diff --git a/modules/role/manifests/labs/db/replica.pp 
b/modules/role/manifests/labs/db/replica.pp
new file mode 100644
index 0000000..390f924
--- /dev/null
+++ b/modules/role/manifests/labs/db/replica.pp
@@ -0,0 +1,27 @@
+class role::labs::db::replica {
+
+    system::role { 'role::labs::db::replica':
+        description => 'Labs replica database',
+    }
+
+    include standard
+    class { 'mariadb::packages_wmf':
+        mariadb10 => true
+    }
+    include role::mariadb::grants
+    include role::mariadb::monitor
+    include role::mariadb::ferm
+
+    class { 'mariadb::config':
+        prompt        => 'REPLICA database',
+        config        => 'mariadb/labs-replica.my.cnf.erb',
+        password      => $passwords::misc::scripts::mysql_root_pass,
+        datadir       => '/srv/labsdb/data',
+        tmpdir        => '/srv/labsdb/tmp',
+        read_only     => 'ON',
+        p_s           => 'on',
+        ssl           => 'on',
+        binlog_format => 'ROW',
+    }
+
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2c0b24dc34048439b44548b317182b4ee7ceb9ff
Gerrit-PatchSet: 5
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Jcrespo <[email protected]>
Gerrit-Reviewer: Jcrespo <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

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

Reply via email to