Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
f3333d2
feat(imagevector): add stackit-pod-identity-webhook image
jastBytes Mar 23, 2026
1c3d5d7
feat(charts): add stackit-pod-identity-webhook charts
jastBytes Mar 23, 2026
0f65310
feat(controlplane): implement STACKIT pod identity webhook deployment
jastBytes Mar 23, 2026
5d86145
test(controlplane): add tests for STACKIT pod identity webhook
jastBytes Mar 23, 2026
21751f2
feat(seed-controlplane): add stackit-pod-identity-webhook dependency
jastBytes Mar 25, 2026
e300dff
feat(stackit): update pod identity webhook name to match standard pat…
jastBytes Mar 25, 2026
50efe80
feat(deployment): add high-availability server type label
jastBytes Mar 25, 2026
8afe654
chore(deployment): remove unused networking labels
jastBytes Mar 25, 2026
7a2cac1
chore(deployment): disable service account token automount
jastBytes Mar 25, 2026
3e37fbe
feat(pod-identity-webhook): move security settings from values to dep…
jastBytes Mar 25, 2026
1100329
chore(deployment): simplify webhook component with static labels and …
jastBytes Mar 25, 2026
06e0445
feat(webhook): add image repository and tag configuration
jastBytes Mar 25, 2026
11686a5
feat(vpa): add vertical pod autoscaler for pod identity webhook
jastBytes Mar 25, 2026
70ad3fa
feat(service): use webhook port as targetPort
jastBytes Mar 25, 2026
c62fc7a
feat(pod-identity-webhook): move security and resource limits in depl…
jastBytes Mar 25, 2026
4e3829f
feat(service): set service type to ClusterIP permanently
jastBytes Mar 25, 2026
aa730ee
feat(webhook): remove comment about certmanager
jastBytes Mar 25, 2026
938895f
feat(controlplane): add vertical pod autoscaler for stackit pod ident…
jastBytes Mar 25, 2026
060b49b
feat(controlplane): add stackit pod identity webhook access secret
jastBytes Mar 25, 2026
ffb97e1
chore(deps): add stackit-pod-identity-webhook as dependency and remov…
jastBytes Mar 25, 2026
ac00fa9
chore(deployment): remove unused end block in webhook deployment temp…
jastBytes Mar 25, 2026
04bc7b8
feat(service): add port annotation for webhook service access
jastBytes Mar 25, 2026
47223b8
feat(deployment): add topology spread constraints and auto topology m…
jastBytes Mar 25, 2026
90c5039
feat(controlplane): add pod disruption budget for pod identity webhoo…
jastBytes Mar 25, 2026
c9a9308
feat(controlplane): rename pod identity webhook chart and shoot funct…
jastBytes Mar 25, 2026
1f66f50
feat(controlplane): reduce replica count to 1
jastBytes Mar 25, 2026
598a711
feat(pod-identity-webhook): use raw CA bundle from secret instead of …
jastBytes Mar 25, 2026
f4513a8
feat(controlplane): check ca bundle is not empty
jastBytes Mar 25, 2026
dba7256
feat(pod-identity-webhook): set failurePolicy to Fail in webhook config
jastBytes Mar 25, 2026
377d40d
fix(controlplane): reduce replica count to 1 in tests
jastBytes Mar 25, 2026
8750445
test: add fake CA bundle to ca-provider-openstack-controlplane secret…
jastBytes Mar 25, 2026
a5bac03
fix chart naming after type rename
jastBytes Mar 26, 2026
f8e7258
feat(webhook): add kubeconfig and token from projected secret for pod…
jastBytes Mar 26, 2026
24755b5
feat(webhook): update kubeconfig path to include kubeconfig file
jastBytes Mar 26, 2026
2477a93
feat(webhook): set fixed port and update webhook URL with seed name
jastBytes Mar 26, 2026
0cd5a91
feat(service): set fixed port 443 for pod identity webhook service
jastBytes Mar 26, 2026
bf6fac6
feat(webhook): update webhook URL to use shoot name instead of seed name
jastBytes Mar 26, 2026
ccbd263
feat(webhook): update webhook URL to use control plane namespace inst…
jastBytes Mar 26, 2026
12b8b62
feat(service): add traffic distribution and endpoint hints for pod id…
jastBytes Mar 26, 2026
127036c
feat(service): use dynamic port from values instead of fixed 9443
jastBytes Mar 26, 2026
584bfbd
feat(controlplane): update webhook DNS names to include stackit prefix
jastBytes Mar 26, 2026
7b102ea
feat(webhook): update webhook URL to use server namespace suffix
jastBytes Mar 26, 2026
45185b2
feat(webhook): update webhook URL and DNS names to match
jastBytes Mar 27, 2026
4af394c
feat(webhook): simplify webhook URL to use fixed path and remove name…
jastBytes Mar 27, 2026
0854e31
feat(webhook): use release namespace in webhook URL and remove contro…
jastBytes Mar 27, 2026
a516094
feat(webhook): use control plane namespace in webhook URL and update …
jastBytes Mar 27, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
apiVersion: v1
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you still need to include this chart in the requirements.yaml in the seed-controlplane chart

name: pod-identity-webhook
version: 0.1.0
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: stackit-pod-identity-webhook
namespace: {{ .Release.Namespace }}
labels:
app.kubernetes.io/name: stackit-pod-identity-webhook
high-availability-config.resources.gardener.cloud/type: server
spec:
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
app.kubernetes.io/name: stackit-pod-identity-webhook
template:
metadata:
labels:
app.kubernetes.io/name: stackit-pod-identity-webhook
workload-identity.stackit.cloud/skip-pod-identity-webhook: "true"
gardener.cloud/role: controlplane
spec:
topologySpreadConstraints:
- maxSkew: 1
topologyKey: "topology.kubernetes.io/zone"
whenUnsatisfiable: DoNotSchedule
labelSelector:
matchLabels:
app.kubernetes.io/name: stackit-pod-identity-webhook
- maxSkew: 1
topologyKey: "kubernetes.io/hostname"
whenUnsatisfiable: ScheduleAnyway
labelSelector:
matchLabels:
app.kubernetes.io/name: stackit-pod-identity-webhook
automountServiceAccountToken: false
podSecurityContext:
runAsNonRoot: true
runAsUser: 1239
runAsGroup: 1239
fsGroup: 1239
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
priorityClassName: gardener-system-200
containers:
- name: stackit-pod-identity-webhook
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
image: {{ index .Values.images "stackit-pod-identity-webhook" }}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add an example value for images to values.yaml?

args:
- --cert-dir=/etc/webhook/certs
- --port={{ .Values.webhook.port }}
env:
- name: KUBECONFIG
value: /var/run/secrets/gardener.cloud/shoot/generic-kubeconfig/kubeconfig
ports:
- name: https
containerPort: {{ .Values.webhook.port }}
protocol: TCP
- name: metrics
containerPort: 8080
protocol: TCP
- name: health
containerPort: 8081
protocol: TCP
livenessProbe:
httpGet:
path: /healthz
port: health
readinessProbe:
httpGet:
path: /readyz
port: health
resources:
limits:
memory: 128Mi
requests:
cpu: 50m
memory: 64Mi
volumeMounts:
- name: certs
mountPath: /etc/webhook/certs
readOnly: true
- mountPath: /var/run/secrets/gardener.cloud/shoot/generic-kubeconfig
name: kubeconfig
readOnly: true
volumes:
- name: certs
secret:
secretName: {{ .Values.webhook.tlsSecretName }}
- name: kubeconfig
projected:
defaultMode: 420
sources:
- secret:
items:
- key: kubeconfig
path: kubeconfig
name: {{ .Values.global.genericTokenKubeconfigSecretName }}
optional: false
- secret:
items:
- key: token
path: token
name: shoot-access-pod-identity-webhook
optional: false
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: stackit-pod-identity-webhook
namespace: {{ .Release.Namespace }}
labels:
app.kubernetes.io/name: stackit-pod-identity-webhook
spec:
maxUnavailable: 1
selector:
matchLabels:
app.kubernetes.io/name: stackit-pod-identity-webhook
unhealthyPodEvictionPolicy: AlwaysAllow
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
apiVersion: v1
kind: Service
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

metadata:
name: stackit-pod-identity-webhook
namespace: {{ .Release.Namespace }}
labels:
app.kubernetes.io/name: stackit-pod-identity-webhook
endpoint-slice-hints.resources.gardener.cloud/consider: "true"
annotations:
networking.resources.gardener.cloud/from-all-webhook-targets-allowed-ports: '[{"protocol":"TCP","port":{{ .Values.webhook.port }}}]'
service.kubernetes.io/topology-mode: auto
spec:
type: ClusterIP
ports:
- port: 443
targetPort: {{ .Values.webhook.port }}
protocol: TCP
name: https
selector:
app.kubernetes.io/name: stackit-pod-identity-webhook
trafficDistribution: PreferClose
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
apiVersion: autoscaling.k8s.io/v1
kind: VerticalPodAutoscaler
metadata:
name: stackit-pod-identity-webhook
namespace: {{ .Release.Namespace }}
spec:
targetRef:
apiVersion: apps/v1
kind: Deployment
name: stackit-pod-identity-webhook
updatePolicy:
updateMode: Auto
resourcePolicy:
containerPolicies:
- containerName: stackit-pod-identity-webhook
minAllowed:
memory: 80M
maxAllowed:
cpu: {{ .Values.vpa.resourcePolicy.maxAllowed.cpu }}
memory: {{ .Values.vpa.resourcePolicy.maxAllowed.memory }}
controlledValues: RequestsOnly
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
replicaCount: 2

images:
stackit-pod-identity-webhook: image-repository:image-tag

webhook:
port: 9443
# The secret name containing tls.crt and tls.key for the webhook server
tlsSecretName: "stackit-pod-identity-webhook-certs"

vpa:
resourcePolicy:
maxAllowed:
cpu: 1
memory: 512Mi
3 changes: 3 additions & 0 deletions charts/internal/seed-controlplane/requirements.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,6 @@ dependencies:
repository: http://localhost:10191
version: 0.1.0
condition: stackit-alb-controller-manager.enabled
- name: pod-identity-webhook
repository: http://localhost:10191
version: 0.1.0
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
apiVersion: v1
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you still need to include this chart in the requirements.yaml in the shoot-system-components chart

name: pod-identity-webhook
version: 0.1.0
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
apiVersion: admissionregistration.k8s.io/v1
kind: MutatingWebhookConfiguration
metadata:
name: stackit-pod-identity-webhook
labels:
app.kubernetes.io/name: stackit-pod-identity-webhook
webhooks:
- name: stackit-pod-identity-webhook.stackit.cloud
clientConfig:
url: {{ .Values.webhook.url | quote }}
caBundle: {{ .Values.webhook.caBundle | quote }}
rules:
- operations: ["CREATE"]
apiGroups: [""]
apiVersions: ["v1"]
resources: ["pods"]
admissionReviewVersions: ["v1"]
sideEffects: None
failurePolicy: Fail
namespaceSelector:
matchExpressions:
- key: app.kubernetes.io/name
operator: NotIn
values: ["gardener-extension-provider-stackit"]
- key: kubernetes.io/metadata.name
operator: NotIn
values: ["kube-system", "garden"]
- key: workload-identity.stackit.cloud/skip-pod-identity-webhook
operator: DoesNotExist
objectSelector:
matchExpressions:
- key: workload-identity.stackit.cloud/skip-pod-identity-webhook
operator: DoesNotExist
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
webhook:
caBundle: "" # will be set by valuesprovider
controlPlaneNamespace: "" # will be set by valuesprovider
3 changes: 3 additions & 0 deletions charts/internal/shoot-system-components/requirements.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ dependencies:
repository: http://localhost:10191
version: 0.1.0
condition: stackit-blockstorage-csi-driver.enabled
- name: pod-identity-webhook
repository: http://localhost:10191
version: 0.1.0
2 changes: 2 additions & 0 deletions imagevector/images.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions imagevector/images.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -135,3 +135,6 @@ images:
- name: stackit-alb-controller-manager
repository: reg3.infra.ske.eu01.stackit.cloud/temp/alb-controller-manager
tag: "1245"
- name: stackit-pod-identity-webhook
repository: reg3.infra.ske.eu01.stackit.cloud/stackitcloud/stackit-pod-identity-webhook
tag: "726f2f0@sha256:fca1f67cd7e6a515e795a34ae45d0c239379d051e494dc202033f6987b41b154"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the record (as discussed in chat): the stackit-pod-identity-webhook repository should be public and released before merging this integration PR in the extension.

Loading