k8s: deploy.notify-router.runtime moves the router between its container and the cluster
This commit is contained in:
parent
40519f9123
commit
30567ad28f
1 changed files with 671 additions and 187 deletions
|
|
@ -3,8 +3,8 @@
|
|||
# all-local swarm. docs/4-implementation/k8s/node.md has the design.
|
||||
#
|
||||
# The node holds the images of the services ./render.nix renders and has no
|
||||
# registry. No service's objects are applied: a service's host unit keeps
|
||||
# running, and its objects go in when the service moves in.
|
||||
# registry. No service's objects are applied until its `runtime` is `k8s`
|
||||
# (./runtime.nix): until then its host unit runs.
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
|
|
@ -59,9 +59,10 @@ in
|
|||
that runs the swarm's services, which is the one
|
||||
`services.hyperhive.deploy.singleHostSwarm` names.
|
||||
|
||||
The cluster starts with no hyperhive workload: the services keep
|
||||
running as systemd units. Its secrets are encrypted at rest, and
|
||||
traefik and metrics-server stay off. Pods and services take their
|
||||
The cluster starts with no hyperhive workload: a service keeps
|
||||
running as its systemd unit unless its `runtime` option is `k8s`.
|
||||
Its secrets are encrypted at rest, and traefik and metrics-server
|
||||
stay off. Pods and services take their
|
||||
addresses from {option}`services.hyperhive.deploy.k8s.podCidr` and
|
||||
{option}`services.hyperhive.deploy.k8s.serviceCidr`. The firewall
|
||||
trusts the pod network's interfaces (`cni0`, `flannel.1`), so the node
|
||||
|
|
@ -130,6 +131,17 @@ in
|
|||
tokens and the one that signs them, which differ after a rotation.
|
||||
'';
|
||||
};
|
||||
|
||||
manifestDir = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
readOnly = true;
|
||||
internal = true;
|
||||
default = "${dataDir}/server/manifests";
|
||||
description = ''
|
||||
The directory k3s applies manifests from, which
|
||||
{option}`services.k3s.manifests` links its files into.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
|
|
|||
Loading…
Reference in a new issue