0
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-07-11 21:06:19 +03:00

nixos/kubernetes: Address review: Separate preStart from certificates

This commit is contained in:
Christian Albrecht 2019-03-06 16:52:27 +01:00
parent 52fe1d2e7a
commit 7323b77435
No known key found for this signature in database
GPG key ID: 866AF4B25DF7EB00
6 changed files with 39 additions and 34 deletions

View file

@ -111,12 +111,11 @@ in
after = [ "kube-apiserver.service" ];
before = [ "kube-control-plane-online.target" ];
preStart = ''
${top.lib.mkWaitCurl (with top.pki.certs.controllerManagerClient; {
${top.lib.mkWaitCurl ( with config.systemd.services.kube-controller-manager; {
sleep = 1;
path = "/api";
cacert = top.caFile;
inherit cert key;
})}
} // optionalAttrs (environment ? cert) { inherit (environment) cert key; })}
'';
serviceConfig = {
RestartSec = "30s";