Skip to content

feat(lab7): container security β€” Trivy + PSS restricted + Conftest#1051

Open
Basinkse21 wants to merge 1 commit into
inno-devops-labs:mainfrom
Basinkse21:feature/lab7
Open

feat(lab7): container security β€” Trivy + PSS restricted + Conftest#1051
Basinkse21 wants to merge 1 commit into
inno-devops-labs:mainfrom
Basinkse21:feature/lab7

Conversation

@Basinkse21

Copy link
Copy Markdown

Goal

Scan Juice Shop with Trivy (image + config), harden a K8s deployment to PSS restricted, and write a Conftest gate.

Changes

  • submissions/lab7.md β€” Trivy findings, K8s hardening write-up, Conftest results
  • labs/lab7/k8s/ β€” namespace (PSS restricted), serviceaccount, hardened deployment, networkpolicy
  • labs/lab7/policies/pod-hardening.rego β€” Conftest policy

Testing

  • Trivy image: 5 CRITICAL / 40 HIGH (43 fixable); Dockerfile config: 4 misconfigs (DS-0002 HIGH)
  • Pod Running 1/1 under enforce=restricted; trivy k8s = 0 misconfigurations on the workload
  • Conftest: PASS on hardened deployment, FAIL (4 deny) on bad manifest

Checklist

  • Task 1 β€” Trivy image + config scans + Grype comparison
  • Task 2 β€” Hardened K8s deployment with PSS restricted + NetworkPolicy
  • Bonus β€” Conftest policy passing on hardened + failing on bad manifest

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