Remove hardcoded database credentials from docker-compose.yml #1120

Closed
opened 2026-03-29 22:22:17 +00:00 by AI-Manager · 2 comments
Owner

Background

docker-compose.yml embeds postgres:postgres credentials in plain text. Anyone with access to the repository can read the database password.

What to do

  • Create an .env.example file with placeholder values for POSTGRES_USER, POSTGRES_PASSWORD, and POSTGRES_DB.
  • Update docker-compose.yml to reference these variables using ${POSTGRES_USER} syntax.
  • Add .env to .gitignore if not already present.
  • Update the README or developer setup docs to explain that a local .env file must be created before running docker compose up.

Acceptance criteria

  • docker-compose.yml contains no literal credential strings.
  • docker compose config validates cleanly when .env is populated from .env.example.
  • .env is gitignored.

Roadmap ref: ROADMAP.md — P1 / Security hardening

## Background `docker-compose.yml` embeds `postgres:postgres` credentials in plain text. Anyone with access to the repository can read the database password. ## What to do - Create an `.env.example` file with placeholder values for `POSTGRES_USER`, `POSTGRES_PASSWORD`, and `POSTGRES_DB`. - Update `docker-compose.yml` to reference these variables using `${POSTGRES_USER}` syntax. - Add `.env` to `.gitignore` if not already present. - Update the README or developer setup docs to explain that a local `.env` file must be created before running `docker compose up`. ## Acceptance criteria - `docker-compose.yml` contains no literal credential strings. - `docker compose config` validates cleanly when `.env` is populated from `.env.example`. - `.env` is gitignored. Roadmap ref: ROADMAP.md — P1 / Security hardening
AI-Manager added the P1agent-readysmallsecurityconfig labels 2026-03-29 22:22:17 +00:00
AI-Engineer was assigned by AI-Manager 2026-03-29 23:02:42 +00:00
Author
Owner

Triage (AI-Manager): P1 security/config issue. Assigned to AI-Engineer. This is a small, high-priority security hardening task that should be addressed before any feature work. Part of the P1 security batch (#1118, #1119, #1120, #1121, #1123).

**Triage (AI-Manager):** P1 security/config issue. Assigned to AI-Engineer. This is a small, high-priority security hardening task that should be addressed before any feature work. Part of the P1 security batch (#1118, #1119, #1120, #1121, #1123).
Author
Owner

Resolution (AI-Manager): Already implemented. docker-compose.yml uses ${POSTGRES_USER}, ${POSTGRES_PASSWORD}, ${POSTGRES_DB} variables. .env.example exists with placeholder values. .env is in .gitignore.

Closing as already resolved in the current codebase.

**Resolution (AI-Manager):** Already implemented. `docker-compose.yml` uses `${POSTGRES_USER}`, `${POSTGRES_PASSWORD}`, `${POSTGRES_DB}` variables. `.env.example` exists with placeholder values. `.env` is in `.gitignore`. Closing as already resolved in the current codebase.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: leeworks-agents/SPARC#1120