The following files contain sensitive information and are protected by .gitignore:
.argocd-credentials- Argo CD login credentialsterraform/terraform.tfvars- OpenStack API credentials.envfiles - Environment variables
terraform/cpouta_key.pem- Auto-generated SSH private key- Any
*.pemor*.keyfiles
terraform/*.tfstate- Contains resource IDs and sensitive dataterraform/*.tfstate.backup- Backup of state files
Before committing to Git, verify sensitive files are ignored:
# Check if sensitive files are tracked
git status
# Verify .gitignore is working
git check-ignore .argocd-credentials
git check-ignore terraform/cpouta_key.pem
git check-ignore terraform/terraform.tfvarsAll three commands should return the filename if properly ignored.
After deployment, consider:
- Changing the Argo CD admin password
- Rotating OpenStack API credentials periodically
- The SSH key
cpouta_key.pemis auto-generated by Terraform - Keep it secure and don't share it
- Use
-iflag when SSHing:ssh -i terraform/cpouta_key.pem ubuntu@<IP>
- Security groups restrict access by IP (0.0.0.0/0 by default)
- Consider restricting to your IP range for production
- Update
terraform/network_and_secgroups.tfto limit access
- Change the default admin password after first login
- Use RBAC to create limited users
- Enable SSO if available
- Never force-add ignored files:
git add -f <file>β - Review files before committing:
git diff --staged - Use
.gitignoreconsistently across environments
- Don't just delete and recommit - secrets remain in Git history
- Remove from history:
git filter-branch --force --index-filter \ "git rm --cached --ignore-unmatch <FILE>" \ --prune-empty --tag-name-filter cat -- --all - Rotate the compromised credentials immediately
- Force push (if remote exists):
git push --force --all
Before committing:
-
.gitignoreexists in root - No
*.pemor*.keyfiles staged - No
terraform.tfvarsstaged - No
.argocd-credentialsstaged - No
*.tfstatefiles staged - Run
git statusto verify
These files are safe and should be committed:
- β
terraform/*.tffiles (except*.tfvars) - β
deploy-k8s-cluster.ps1 - β
README.md,QUICKSTART.md,SECURITY.md - β
.gitignore - β
ansible-reference-backup/*.yml(playbooks only)
If you discover a security issue:
- Rotate affected credentials immediately
- Update the relevant services
- Review access logs for suspicious activity