Interview Prep/CI/CD/Secrets and Credentials

How do you secure the connection between CI and a production cluster when pushing deployments?

AdvancedProductionSecrets and Credentials
Answer

The strongest option is not to: use pull-based GitOps so CI has no cluster credentials. If push is required: use short-lived credentials via OIDC mapped to a namespace-scoped Kubernetes RBAC role (EKS access entries), restrict the cluster API to private endpoints or allow-listed runner egress IPs, use a dedicated deploy runner pool, audit via Kubernetes audit logs, and have admission policies (Kyverno) validate what the deploy identity may create.

All CI/CD questions

More on Secrets and Credentials