From 9ade8f6eb774dc7d19d82a070199b5024786b819 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Isma=C3=ABl=20Bouya?= Date: Fri, 17 May 2019 01:43:18 +0200 Subject: Use acme directory config rather than hardcoding the value --- modules/private/databases/mariadb.nix | 4 ++-- modules/private/databases/openldap/default.nix | 6 +++--- modules/private/databases/postgresql.nix | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) (limited to 'modules/private/databases') diff --git a/modules/private/databases/mariadb.nix b/modules/private/databases/mariadb.nix index 21f4359..cc99c3c 100644 --- a/modules/private/databases/mariadb.nix +++ b/modules/private/databases/mariadb.nix @@ -54,8 +54,8 @@ in { dataDir = cfg.dataDir; extraOptions = '' ssl_ca = ${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt - ssl_key = /var/lib/acme/mysql/key.pem - ssl_cert = /var/lib/acme/mysql/fullchain.pem + ssl_key = ${config.security.acme.directory}/mysql/key.pem + ssl_cert = ${config.security.acme.directory}/mysql/fullchain.pem ''; }; diff --git a/modules/private/databases/openldap/default.nix b/modules/private/databases/openldap/default.nix index 850f3ff..46f85d2 100644 --- a/modules/private/databases/openldap/default.nix +++ b/modules/private/databases/openldap/default.nix @@ -33,9 +33,9 @@ let directory ${cfg.dataDir} overlay memberof - TLSCertificateFile /var/lib/acme/ldap/cert.pem - TLSCertificateKeyFile /var/lib/acme/ldap/key.pem - TLSCACertificateFile /var/lib/acme/ldap/fullchain.pem + TLSCertificateFile ${config.security.acme.directory}/ldap/cert.pem + TLSCertificateKeyFile ${config.security.acme.directory}/ldap/key.pem + TLSCACertificateFile ${config.security.acme.directory}/ldap/fullchain.pem TLSCACertificatePath ${pkgs.cacert.unbundled}/etc/ssl/certs/ #This makes openldap crash #TLSCipherSuite DEFAULT diff --git a/modules/private/databases/postgresql.nix b/modules/private/databases/postgresql.nix index 26242a8..8c36d84 100644 --- a/modules/private/databases/postgresql.nix +++ b/modules/private/databases/postgresql.nix @@ -73,8 +73,8 @@ in { lc_time = 'en_US.UTF-8' default_text_search_config = 'pg_catalog.english' ssl = on - ssl_cert_file = '/var/lib/acme/postgresql/fullchain.pem' - ssl_key_file = '/var/lib/acme/postgresql/key.pem' + ssl_cert_file = '${config.security.acme.directory}/postgresql/fullchain.pem' + ssl_key_file = '${config.security.acme.directory}/postgresql/key.pem' ''; authentication = '' local all postgres ident -- cgit v1.2.3