This project uses environment variables to manage sensitive configuration. Never commit actual environment files to the repository.
Create these files locally (they are gitignored):
.env- Development environment.env.staging- Staging environment.env.production- Production environment
Use these template files as a starting point:
.env.example- Contains all required environment variables with example values- Copy
.env.exampleto.envand fill in your actual values
The following variables contain sensitive information and should never be hardcoded:
JWT_SECRET- JWT signing secretDATABASE_PASSWORD- Database passwordSTRIPE_SECRET_KEY- Stripe secret keyGOOGLE_CLIENT_SECRET- Google OAuth secretAWS_SECRET_ACCESS_KEY- AWS secret keySMTP_PASSWORD- Email password- All API keys and tokens
Kubernetes secrets and credentials are managed through:
- Template files (
.yaml.template) for structure - Environment variable substitution for actual values
- External secret management systems in production
-
Copy environment template:
cp .env.example .env
-
Fill in your development values in
.env -
Never commit
.envfiles to git
- Use proper secret management (Kubernetes secrets, AWS Secrets Manager, etc.)
- Rotate secrets regularly
- Use least-privilege access principles
- Monitor for secret exposure
If you discover a security vulnerability, please email security@ephra.com instead of creating a public issue.