Skip to content

Add container security context to K8s deployment#43

Merged
eswan18 merged 1 commit into
mainfrom
add-container-security-context
Feb 7, 2026
Merged

Add container security context to K8s deployment#43
eswan18 merged 1 commit into
mainfrom
add-container-security-context

Conversation

@eswan18
Copy link
Copy Markdown
Owner

@eswan18 eswan18 commented Feb 7, 2026

Summary

  • Add securityContext to container spec: runAsNonRoot, allowPrivilegeEscalation: false, drop ALL capabilities
  • Defense in depth alongside the non-root USER in the Dockerfile

Test plan

  • kubectl apply --dry-run=client -f k8s/base/deployment.yaml passes
  • Pods start successfully after deploy

🤖 Generated with Claude Code

Enforce non-root execution, prevent privilege escalation, and drop
all Linux capabilities at the K8s level.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@eswan18 eswan18 merged commit 10d3d02 into main Feb 7, 2026
1 check passed
@eswan18 eswan18 deleted the add-container-security-context branch February 7, 2026 02:52
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