MaxScale/script/create_roles.sql
Markus Makela 1001654987 Add utility scripts to make installation easier
The `create_grants` scripts allow users to be easily "copied" to
MaxScale. It queries the backend for grants for all users and converts
them into similar grants for the MaxScale host.

The `create_roles.sql` is a small set of queries which creates two utility
roles, `proxy_authenticator` and `proxy_monitor`. These roles can be
assigned to the actual service and monitor users with a single grant
command.
2016-09-20 10:30:53 +03:00

8 lines
320 B
SQL

CREATE ROLE proxy_authenticator;
GRANT SELECT ON mysql.user TO proxy_authenticator;
GRANT SELECT ON mysql.db TO proxy_authenticator;
GRANT SELECT ON mysql.tables_priv TO proxy_authenticator;
GRANT SHOW DATABASES ON *.* TO proxy_authenticator;
CREATE ROLE proxy_monitor;
GRANT REPLICATION CLIENT ON *.* TO proxy_monitor;