diff options
Diffstat (limited to 'modules/private/databases/default.nix')
-rw-r--r-- | modules/private/databases/default.nix | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/modules/private/databases/default.nix b/modules/private/databases/default.nix index 7371410..8c5eb9a 100644 --- a/modules/private/databases/default.nix +++ b/modules/private/databases/default.nix | |||
@@ -1,4 +1,4 @@ | |||
1 | { lib, config, myconfig, nodes, ... }: | 1 | { lib, config, nodes, ... }: |
2 | let | 2 | let |
3 | cfg = config.myServices.databases; | 3 | cfg = config.myServices.databases; |
4 | in | 4 | in |
@@ -18,49 +18,49 @@ in | |||
18 | mariadb = { | 18 | mariadb = { |
19 | enable = true; | 19 | enable = true; |
20 | ldapConfig = { | 20 | ldapConfig = { |
21 | inherit (myconfig.env.ldap) host base; | 21 | inherit (config.myEnv.ldap) host base; |
22 | inherit (myconfig.env.databases.mysql.pam) dn filter password; | 22 | inherit (config.myEnv.databases.mysql.pam) dn filter password; |
23 | }; | 23 | }; |
24 | replicationLdapConfig = { | 24 | replicationLdapConfig = { |
25 | inherit (myconfig.env.ldap) host base; | 25 | inherit (config.myEnv.ldap) host base; |
26 | inherit (myconfig.env.ldap.eldiron) dn password; | 26 | inherit (config.myEnv.servers.eldiron.ldap) dn password; |
27 | }; | 27 | }; |
28 | credentials.root = myconfig.env.databases.mysql.systemUsers.root; | 28 | credentials.root = config.myEnv.databases.mysql.systemUsers.root; |
29 | }; | 29 | }; |
30 | 30 | ||
31 | openldap = { | 31 | openldap = { |
32 | accessFile = "${myconfig.privateFiles}/ldap.conf"; | 32 | accessFile = "${config.myEnv.privateFiles}/ldap.conf"; |
33 | baseDn = myconfig.env.ldap.base; | 33 | baseDn = config.myEnv.ldap.base; |
34 | rootDn = myconfig.env.ldap.root_dn; | 34 | rootDn = config.myEnv.ldap.root_dn; |
35 | rootPw = myconfig.env.ldap.root_pw; | 35 | rootPw = config.myEnv.ldap.root_pw; |
36 | enable = true; | 36 | enable = true; |
37 | }; | 37 | }; |
38 | 38 | ||
39 | postgresql = { | 39 | postgresql = { |
40 | ldapConfig = { | 40 | ldapConfig = { |
41 | inherit (myconfig.env.ldap) host base; | 41 | inherit (config.myEnv.ldap) host base; |
42 | inherit (myconfig.env.databases.postgresql.pam) dn filter password; | 42 | inherit (config.myEnv.databases.postgresql.pam) dn filter password; |
43 | }; | 43 | }; |
44 | replicationLdapConfig = { | 44 | replicationLdapConfig = { |
45 | inherit (myconfig.env.ldap) host base; | 45 | inherit (config.myEnv.ldap) host base; |
46 | inherit (myconfig.env.ldap.eldiron) dn password; | 46 | inherit (config.myEnv.servers.eldiron.ldap) dn password; |
47 | }; | 47 | }; |
48 | authorizedHosts = { | 48 | authorizedHosts = { |
49 | immaeEu = [{ | 49 | immaeEu = [{ |
50 | ip4 = [ | 50 | ip4 = [ |
51 | myconfig.env.servers.immaeEu.ips.main.ip4 | 51 | config.myEnv.servers.immaeEu.ips.main.ip4 |
52 | myconfig.env.servers.immaeEu.ips.alt.ip4 | 52 | config.myEnv.servers.immaeEu.ips.alt.ip4 |
53 | ]; | 53 | ]; |
54 | }]; | 54 | }]; |
55 | }; | 55 | }; |
56 | replicationHosts = { | 56 | replicationHosts = { |
57 | backup-1 = { | 57 | backup-1 = { |
58 | ip4 = [myconfig.env.servers.backup-1.ips.main.ip4]; | 58 | ip4 = [config.myEnv.servers.backup-1.ips.main.ip4]; |
59 | ip6 = myconfig.env.servers.backup-1.ips.main.ip6; | 59 | ip6 = config.myEnv.servers.backup-1.ips.main.ip6; |
60 | }; | 60 | }; |
61 | backup-2 = { | 61 | backup-2 = { |
62 | ip4 = [myconfig.env.servers.backup-2.ips.main.ip4]; | 62 | ip4 = [config.myEnv.servers.backup-2.ips.main.ip4]; |
63 | ip6 = myconfig.env.servers.backup-2.ips.main.ip6; | 63 | ip6 = config.myEnv.servers.backup-2.ips.main.ip6; |
64 | }; | 64 | }; |
65 | }; | 65 | }; |
66 | enable = true; | 66 | enable = true; |