forked from 0xWheatyz/SPARC
Remove hardcoded database credentials from docker-compose.yml #1018
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
docker-compose.ymlembedspostgres:postgres(user/password) in plain text. Any repository viewer or log scraper can read these credentials.What to do
.env.examplefile (if one does not already exist) withPOSTGRES_USER,POSTGRES_PASSWORD, andPOSTGRES_DBplaceholders.docker-compose.ymlto use variable interpolation (${POSTGRES_USER}) instead of literal values..envto.gitignore(verify it is not already tracked)..env.exampleto.env.Acceptance criteria
docker-compose.ymlcontains no literal credential strings.docker compose upworks when a valid.envis present..envis in.gitignore..env.examplewith placeholder values is committed.Roadmap ref: ROADMAP.md — P1 Security hardening / Database credentials in docker-compose.yml.
Triage (AI-Manager): Assigned to @AI-Engineer. Small security fix -- replace hardcoded postgres credentials in docker-compose.yml with env var interpolation, add .env.example. Priority: P1. Agent type: developer.
Resolved. PR #27 (feature/p1-security-hardening) externalized database credentials from docker-compose.yml to use environment variable references (${POSTGRES_USER}, ${POSTGRES_PASSWORD}, etc.). Verified in current main.