diff --git a/src/pages/manage/integrations/kubernetes/index.mdx b/src/pages/manage/integrations/kubernetes/index.mdx index 2618685cc..bc3a127bf 100644 --- a/src/pages/manage/integrations/kubernetes/index.mdx +++ b/src/pages/manage/integrations/kubernetes/index.mdx @@ -325,6 +325,35 @@ spec: ... ``` +### Init Sidecar Mode +By default, the NetBird container is injected as a regular sidecar container. For workloads like Jobs and CronJobs where the pod +should terminate after the main container completes, you can use init sidecar mode. This injects NetBird as an init container +with `restartPolicy: Always`. + +To enable init sidecar mode, add the following annotation: + +```yaml +netbird.io/init-sidecar: "true" +``` + +Below is an example of a Job using init sidecar mode: + +```yaml +kind: Job +... +spec: +... + template: + metadata: + annotations: + netbird.io/setup-key: app-setup-key # Must match the name of an NBSetupKey object in the same namespace + netbird.io/init-sidecar: "true" +... + spec: + containers: +... +``` + ### Using Extra Labels to Access Multiple Pods Using the Same Name Starting with `v0.27.0`, NetBird supports extra DNS labels, allowing you to define extended DNS names for peers. This enables grouping peers under a shared DNS name and distributing traffic using DNS round-robin load balancing.