This guide demonstrates how to migrate from storing Vault tokens in terraform.tfvars to using GitHub OIDC (OpenID Connect) for secure, secretless authentication in CI/CD pipelines.
Benefits:
- 🔐 Secretless Authentication: No more storing long-lived tokens in files or secrets
- 🎯 Least Privilege: Granular policies scoped to specific paths and operations
- 🔄 Automatic Rotation: Short-lived tokens (1 hour TTL) generated per workflow run
- 🎭 Role-Based Access: Different permissions for PRs vs production deployments
- 📊 Better Audit Trail: GitHub actor tied to Vault authentication