From: Frank Brehm Date: Fri, 3 Nov 2017 14:16:14 +0000 (+0100) Subject: Refactored for a schema solution X-Git-Tag: 0.1.2~124^2 X-Git-Url: https://git.uhu-banane.net/?a=commitdiff_plain;h=7107d1fc5b3e505aee690b11ab1d45ec28a75071;p=pixelpark%2Fadmin-tools.git Refactored for a schema solution --- diff --git a/dns/schema.pgsql.sql b/dns/schema.pgsql.sql index 4fed700..703454b 100644 --- a/dns/schema.pgsql.sql +++ b/dns/schema.pgsql.sql @@ -2,9 +2,6 @@ CREATE DATABASE pdns WITH ENCODING 'UTF8' LC_COLLATE 'en_US.UTF-8' LC_CTYPE 'en_US.UTF-8'; CREATE DATABASE pdnsadm WITH ENCODING 'UTF8' LC_COLLATE 'en_US.UTF-8' LC_CTYPE 'en_US.UTF-8'; -CREATE DATABASE pdns_local WITH ENCODING 'UTF8' LC_COLLATE 'en_US.UTF-8' LC_CTYPE 'en_US.UTF-8'; -CREATE DATABASE pdns_public WITH ENCODING 'UTF8' LC_COLLATE 'en_US.UTF-8' LC_CTYPE 'en_US.UTF-8'; - BEGIN WORK; CREATE ROLE dns @@ -24,16 +21,12 @@ GRANT ALL ON DATABASE "pdnsadm" TO pdnsadm; ALTER DATABASE pdnsadm OWNER TO pdnsadm; CREATE USER pdns_local WITH PASSWORD 'Neingeichee(ghahn7ah'; -COMMENT ON ROLE pdns IS 'User for local PowerDNS'; +COMMENT ON ROLE pdns_local IS 'User for local PowerDNS'; GRANT dns TO pdns_local; -GRANT ALL ON DATABASE "pdns_local" TO pdns_local; -ALTER DATABASE pdns_local OWNER TO pdns_local; CREATE USER pdns_public WITH PASSWORD 'ahr7die3gee]s4vahCoh'; -COMMENT ON ROLE pdns IS 'User for public PowerDNS'; +COMMENT ON ROLE pdns_public IS 'User for public PowerDNS'; GRANT dns TO pdns_public; -GRANT ALL ON DATABASE "pdns_public" TO pdns_public; -ALTER DATABASE pdns_public OWNER TO pdns_public; COMMIT;