Skip to content

Edgelet kube - #13

Merged
emirhandurmus merged 42 commits into
developfrom
edgelet-kube/10-install-upgrade
Nov 14, 2026
Merged

emirhandurmus merged 42 commits into
developfrom
edgelet-kube/10-install-upgrade

Conversation

@emirhandurmus

Copy link
Copy Markdown

No description provided.

The kube tree is its own module and replaces the root module for extract, the file lock, and the data directory. Agent CI skips that tree, so an agent change does not compile it and a kube change does not rerun the agent suites.
The thin binary unpacks one zstd bundle and execs the fat runtime. server returns without listening, and kubectl, ctr, and crictl are dispatched to that same executable. A separate workflow builds the linux binary and runs that check.
One patch, the matching cri-api module, the three chart versions, and the twelve default images are listed with digests.
Read the config file and the drop-in directory beside it. A missing or empty file keeps the built-in options and does not write a file. Drop-ins apply in alphabetical order and the last value wins. An unknown key fails and names the key, as does every key this server does not accept. --config and EDGELET_KUBE_CONFIG_FILE move the file and its drop-in directory.

A plus suffix appends list elements, and a string is one element. The same suffix on a scalar key fails and names the key. The repeatable keys are the certificate names, node labels, node taints, disabled addons, and the extra process arguments. The node pod range is the first /24 of the cluster network. Cluster DNS is the 10th service address when it is unset, and a DNS address outside the service network fails and names both values.

An EDGELET_KUBE_* variable replaces a file value, and a flag replaces the environment. List append in the files finishes before that replacement.
The bundle carries the fat runtime, the shim, crun, the four CNI plugins, and the aux host tools. An OCI image is rejected.
The socket is /run/edgelet-kube/containerd.sock, the containerd root is /var/lib/edgelet-kube/agent/containerd, and CNI config is /var/lib/edgelet-kube/agent/etc/cni/net.d. CNI binaries and iptables stay in the extracted bundle.
The child switch --edgelet-kube-containerd-child runs containerd with crun and systemd cgroups, and ctr and crictl use its socket. That process does not open the API port.
An empty images directory pulls the pinned list. Imported images are pinned so garbage collection does not remove them. A tar added after startup is imported without a process restart. A registry prefix retags the pinned names, and an image an operator created is left unchanged.
A missing registries file leaves containerd on upstream endpoints. private-registry selects another file, and disable-default-registry-endpoint stops fallback for names listed there. system-default-registry prefixes the pinned names, including pause, and an empty key leaves those names unchanged. kubelet receives that pause name as --pod-infra-container-image.
edgelet-kube-airgap-images-amd64.tar.zst is that list and nothing else. An empty images directory and this archive pin the same names in k8s.io. The archive is published beside the binary and is not linked into the runtime.
An empty endpoint opens state.db with leader election off and does not touch the agent database. Other endpoints are passed through. A NATS credentials file is injected and URL userinfo is dropped. A CA keeps nats:// and disables embedded JetStream. Client certificates stay optional. Secrets encryption writes its config on first boot and refuses a flag that does not match the key file.
…ficates

Start kube-apiserver once the datastore is open, then kube-controller-manager and kube-scheduler after that point, without kubelet or kube-proxy. Pass the configured cluster and service networks through, leave aggregation on, and refuse a SELinux request when the host has none. Issue the CA once under the server TLS directory and reuse it together with the serving and client certificates, write the admin kubeconfig as system:admin in system:masters mode 0600, serve the configured names, and pass the encryption file through only when startup is allowed.
Write one conflist before any sandbox, without contacting the apiserver. The bridge is a gateway with masquerade and hairpin, host-local uses the node pod range, and portmap is the second plugin.
When bundled binaries are preferred, PATH lists the bundle aux directory first so iptables resolves to xtables-legacy. Otherwise the host directories stay first.
Image import finishes before kubelet. The conflist is written first, then kubelet and kube-proxy start with the controller manager and the scheduler. Kubelet uses the bundle CNI directories and the pause image. Kube-proxy uses iptables. No join flag is accepted, and an unset node taint stays unset.

The cgroup driver is systemd. Another driver is rejected. protect-kernel-defaults is passed only when that setting is on. Bundled iptables is placed on PATH before containerd starts, so the bridge plugin can find it. Kubelet is given its dependencies before it runs.
CoreDNS is rendered with the cluster DNS address and domain. The default StorageClass is local-path and uses the configured storage path. The metrics manifest registers metrics.k8s.io. A disable flag removes only that addon, and disabling the metrics server leaves aggregation on.
…ervices

Manifests are applied after the API server is ready, and caller YAML is applied after them. The controller writes the node address and does not create a DaemonSet. Disabling it leaves an existing Service pending.
The service starts the server and links kubectl, ctr, and crictl to the thin binary. A later run replaces that binary and restarts the service without removing the database, certificates, or encryption config.
Clears the net/http HTTP/1 server crash in MaxBytesReader.
Follow the current embed tree for containerd, cri-api, crun, and k3s-root. Stage the Gateway API CRD chart and one RuntimeClass per handler, and keep the iptables family on nft.
macOS builds inside the embed image. arm and riscv64 cross-compile with the matching C toolchain.
amd64, arm64, and arm take the full pin list. riscv64 omits metrics-server and cert-manager.
The guest checks extract, the containerd socket, the bridge conflist, and CoreDNS after restart.
Gosec runs in the server module after the root module scan.
Agent tags stay on the agent release. The server tag signs the four Linux binaries, the four airgap archives, and the checksum file.
The node is installed from the release binary and the matching airgap archive. Traefik, cert-manager, metrics-server, and local-path stay installed.
@emirhandurmus
emirhandurmus merged commit 64e0e18 into develop Nov 14, 2026
4 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant