summaryrefslogtreecommitdiffstats
path: root/tv/2configs
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2019-04-20 18:54:58 +0200
committertv <tv@krebsco.de>2019-04-20 18:54:58 +0200
commitf940a179053e54de0d46aada5b42502f7563f45f (patch)
tree3f595f6522f81f2589b9c7d0dbfca8106e24e80f /tv/2configs
parentd825d2db8796a0d19f22eba240a2e49213cf01e2 (diff)
tv pki: immigrate certificate environment
Diffstat (limited to 'tv/2configs')
-rw-r--r--tv/2configs/default.nix10
-rw-r--r--tv/2configs/pki/default.nix14
2 files changed, 15 insertions, 9 deletions
diff --git a/tv/2configs/default.nix b/tv/2configs/default.nix
index ac0a6af4d..4fc755c43 100644
--- a/tv/2configs/default.nix
+++ b/tv/2configs/default.nix
@@ -17,6 +17,7 @@ with import <stockholm/lib>;
./bash
./htop.nix
./nginx
+ ./pki
./ssh.nix
./sshd.nix
./vim.nix
@@ -91,15 +92,6 @@ with import <stockholm/lib>;
}
{
- environment.variables =
- flip genAttrs (_: "${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt") [
- "CURL_CA_BUNDLE"
- "GIT_SSL_CAINFO"
- "SSL_CERT_FILE"
- ];
- }
-
- {
services.cron.enable = false;
services.nscd.enable = false;
services.ntp.enable = false;
diff --git a/tv/2configs/pki/default.nix b/tv/2configs/pki/default.nix
new file mode 100644
index 000000000..f22b9a6da
--- /dev/null
+++ b/tv/2configs/pki/default.nix
@@ -0,0 +1,14 @@
+with import <stockholm/lib>;
+{ config, ... }: let
+
+ certFile = config.environment.etc."ssl/certs/ca-certificates.crt".source;
+
+in {
+
+ environment.variables = flip genAttrs (_: toString certFile) [
+ "CURL_CA_BUNDLE"
+ "GIT_SSL_CAINFO"
+ "SSL_CERT_FILE"
+ ];
+
+}