Jcrespo has uploaded a new change for review.

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

Change subject: Addind needed files to setup research access to a flow replica
......................................................................

Addind needed files to setup research access to a flow replica

Research grants an unpuppetized. I have not clear where those
grants have to be applied, so I have added for now the grants
as they are in analytics-store. We need to do a cleanup later.

Adding replication filter so only flowdb is replicated to dbstores.

Bug: T75047
Change-Id: Id9c601dbbf323d85e1ac256e2416c0203a006545
---
M templates/mariadb/dbstore.my.cnf.erb
A templates/mariadb/research-grants.sql.erb
2 files changed, 11 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/43/249743/1

diff --git a/templates/mariadb/dbstore.my.cnf.erb 
b/templates/mariadb/dbstore.my.cnf.erb
index 8334225..c2ed806 100644
--- a/templates/mariadb/dbstore.my.cnf.erb
+++ b/templates/mariadb/dbstore.my.cnf.erb
@@ -78,6 +78,7 @@
 m3.replicate-wild-do-table = phab%.%
 m3.replicate-wild-do-table = phlegal%.%
 m4.replicate-wild-do-table = log.%
+x1.replicate-wild-do-table = flowdb.%
 
 [mysqldump]
 
diff --git a/templates/mariadb/research-grants.sql.erb 
b/templates/mariadb/research-grants.sql.erb
new file mode 100644
index 0000000..caca75b
--- /dev/null
+++ b/templates/mariadb/research-grants.sql.erb
@@ -0,0 +1,10 @@
+-- This files is not yet used by any class, but it is better here than nowhere
+-- Grants for 'research'@'%'
+GRANT USAGE ON *.* TO 'research'@'%' IDENTIFIED BY <%= research_pass %> WITH 
MAX_USER_CONNECTIONS 200;
+GRANT ALTER, CREATE, CREATE TEMPORARY TABLES, DELETE, DROP, INDEX, INSERT, 
SELECT, UPDATE ON `datasets`.* TO 'research'@'%';
+GRANT ALTER, CREATE, CREATE TEMPORARY TABLES, DELETE, DROP, INDEX, INSERT, 
SELECT, UPDATE ON `staging`.* TO 'research'@'%';
+GRANT SELECT ON `%wik%`.* TO 'research'@'%';
+GRANT SELECT ON `centralauth`.* TO 'research'@'%';
+GRANT SELECT ON `log`.* TO 'research'@'%';
+GRANT SELECT ON `warehouse`.* TO 'research'@'%';
+GRANT SELECT ON `flowdb`.* TO 'research'@'%';

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id9c601dbbf323d85e1ac256e2416c0203a006545
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Jcrespo <[email protected]>

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

Reply via email to