nixpkgs/nixos/modules/services
Christian Albrecht 62f03750e4
nixos/kubernetes: Stabilize services startup across machines
by adding targets and curl wait loops to services to ensure services
are not started before their depended services are reachable.

Extra targets cfssl-online.target and kube-apiserver-online.target
syncronize starts across machines and node-online.target ensures
docker is restarted and ready to deploy containers on after flannel
has discussed the network cidr with apiserver.

Since flannel needs to be started before addon-manager to configure
the docker interface, it has to have its own rbac bootstrap service.

The curl wait loops within the other services exists to ensure that when
starting the service it is able to do its work immediately without
clobbering the log about failing conditions.

By ensuring kubernetes.target is only reached after starting the
cluster it can be used in the tests as a wait condition.

In kube-certmgr-bootstrap mkdir is needed for it to not fail to start.

The following is the relevant part of systemctl list-dependencies

default.target
● ├─certmgr.service
● ├─cfssl.service
● ├─docker.service
● ├─etcd.service
● ├─flannel.service
● ├─kubernetes.target
● │ ├─kube-addon-manager.service
● │ ├─kube-proxy.service
● │ ├─kube-apiserver-online.target
● │ │ ├─flannel-rbac-bootstrap.service
● │ │ ├─kube-apiserver-online.service
● │ │ ├─kube-apiserver.service
● │ │ ├─kube-controller-manager.service
● │ │ └─kube-scheduler.service
● │ └─node-online.target
● │   ├─node-online.service
● │   ├─flannel.target
● │   │ ├─flannel.service
● │   │ └─mk-docker-opts.service
● │   └─kubelet.target
● │     └─kubelet.service
● ├─network-online.target
● │ └─cfssl-online.target
● │   ├─certmgr.service
● │   ├─cfssl-online.service
● │   └─kube-certmgr-bootstrap.service
2019-03-03 19:39:02 +01:00
..
admin salt: Restart on config changes 2018-10-15 19:59:25 -07:00
amqp rabbitmq module: Update documentation after proofreading 2018-11-03 19:19:04 +01:00
audio squeezelite: fix 'cfg' reference (#56271) 2019-02-23 18:28:02 -06:00
backup Merge pull request #54514 from LeOtaku/fix/restic-timer-config 2019-01-24 00:40:52 +01:00
cluster nixos/kubernetes: Stabilize services startup across machines 2019-03-03 19:39:02 +01:00
computing nixos/slurm: add extraConfigPaths options 2018-11-22 11:43:05 +01:00
continuous-integration nixos: add preferLocalBuild=true; on derivations for config files 2019-02-22 20:11:27 +01:00
databases nixos: add preferLocalBuild=true; on derivations for config files 2019-02-22 20:11:27 +01:00
desktops nixos/gnome-settings-daemon: init 2019-03-01 14:55:12 -05:00
development nixos/jupyter: wait for network.target 2018-11-06 20:40:20 +01:00
editors Treewide: use HTTPS on GNU domains 2018-12-02 15:51:59 +01:00
games nixos/mincraft-server: refactor 2019-02-03 02:16:11 +01:00
hardware nixos: add preferLocalBuild=true; on derivations for config files 2019-02-22 20:11:27 +01:00
logging nixos: add preferLocalBuild=true; on derivations for config files 2019-02-22 20:11:27 +01:00
mail rmilter: fix inetSocket 2019-03-02 01:12:21 +00:00
misc nixos/home-assistant: use preferLocalBuild = true for configuration 2019-03-02 12:37:48 +01:00
monitoring datadog-agent: 6.9.0 -> 6.10.0 (#56523) 2019-02-28 11:48:49 -08:00
network-filesystems openafs: minor documentation fix 2019-02-26 14:49:59 -05:00
networking nixos/coredns: init (#54931) 2019-03-01 11:10:44 +02:00
printing nixos: add preferLocalBuild=true; on derivations for config files 2019-02-22 20:11:27 +01:00
scheduling nixos/modules: users.(extraUsers|extraGroup->users|group) 2018-06-30 03:02:58 +02:00
search pythonPackages.elasticsearch-curator: 5.5.4 -> 5.6.0 2018-12-13 20:58:58 +01:00
security munge: fix module munge.key permissions from 0700 -> 0400 readonly 2019-01-30 12:53:54 -05:00
system Merge remote-tracking branch 'upstream/master' into staging 2018-12-16 22:55:06 +01:00
torrent nixos/transmission: Bug fix Appamor Transmission startup errors (#54873) 2019-01-31 17:51:48 +00:00
ttys nixos: add preferLocalBuild=true; on derivations for config files 2019-02-22 20:11:27 +01:00
web-apps Merge pull request #56496 from bachp/nextcloud-nginx-recommended 2019-03-02 01:18:18 +00:00
web-servers Merge pull request #56233 from jtojnar/nginx-tlsv13 2019-03-03 14:19:38 +01:00
x11 Merge pull request #56562 from worldofpeace/module/gsd 2019-03-01 22:01:26 -05:00