From 10133f0b5b30e4d36a0c66742e1483d126d86f28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Forsman?= Date: Sat, 17 Aug 2013 10:35:56 +0200 Subject: [PATCH] Add /etc/ssl/certs/ca-certificates.crt symlink for Ubuntu compatibility NixOS and Fedora uses .../ca-bundle.crt. Ubuntu uses .../ca-certificates.crt. Add .../ca-certificates.crt symlink to be compatible with Ubuntu. Example use case: Bob has a ~/.msmtprc file that he brings over from Ubuntu. It also works on NixOS. --- modules/security/ca.nix | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/modules/security/ca.nix b/modules/security/ca.nix index e42f5ffe3b8..0fcfc446d42 100644 --- a/modules/security/ca.nix +++ b/modules/security/ca.nix @@ -7,8 +7,15 @@ with pkgs.lib; config = { environment.etc = - [ { source = "${pkgs.cacert}/etc/ca-bundle.crt"; - target = "ssl/certs/ca-bundle.crt"; + [ + # Provide both Fedora and Ubuntu certificate locations for + # compatibility. + { source = "${pkgs.cacert}/etc/ca-bundle.crt"; + target = "ssl/certs/ca-bundle.crt"; # Same location as in Fedora + } + + { source = "${pkgs.cacert}/etc/ca-bundle.crt"; + target = "ssl/certs/ca-certificates.crt"; # Same location as in Ubuntu } # Backward compatibility; may remove at some point.