Skip to content

Bootstrap Codex project scaffold with Dev Container and Dockerized PostgreSQL#1

Merged
boci11 merged 10 commits into
mainfrom
copilot/add-folder-structure-and-configs
Jul 2, 2026
Merged

Bootstrap Codex project scaffold with Dev Container and Dockerized PostgreSQL#1
boci11 merged 10 commits into
mainfrom
copilot/add-folder-structure-and-configs

Conversation

Copilot AI commented Jul 2, 2026

Copy link
Copy Markdown

This PR reshapes the repository into a Codex-ready project skeleton and adds a consistent local development runtime. It introduces Dev Container support, Docker Compose database provisioning, and startup docs/env conventions for secure, repeatable onboarding.

  • Project scaffold

    • Added top-level structure for ongoing development and information organization:
      • .devcontainer/, src/, docs/, data/, scripts/
    • Added .gitkeep placeholders in new directories to preserve structure in git.
  • Containerized development environment

    • Added .devcontainer/devcontainer.json configured to run against Compose service app.
    • Added .devcontainer/Dockerfile (base dev image + postgresql-client) for local DB tooling in-container.
    • Aligned workspace mount/path naming to codex for consistency.
  • Database runtime via Docker Compose

    • Added docker-compose.yml with:
      • app service for Dev Container workflow
      • db service (postgres:16-alpine) with persistent volume
      • configurable host port via POSTGRES_PORT
      • required POSTGRES_PASSWORD (no weak default fallback)
  • Environment and secret hygiene

    • Added .env.example with:
      • OPENAI_API_KEY=your_openai_api_key_here
      • PostgreSQL variables (POSTGRES_USER, POSTGRES_PASSWORD, POSTGRES_DB, POSTGRES_PORT)
    • Added .gitignore covering local env files, editor state, caches, logs, and build artifacts.
  • README replacement for Codex onboarding

    • Replaced previous repository README with Codex-focused setup:
      • project purpose
      • directory map
      • Dev Container startup
      • Docker Compose DB startup
      • OpenAI env variable usage and expected location
# docker-compose.yml (key behavior)
db:
  image: postgres:16-alpine
  ports:
    - "${POSTGRES_PORT:-5432}:5432"
  environment:
    POSTGRES_USER: ${POSTGRES_USER:-codex}
    POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?Set POSTGRES_PASSWORD in .env}
    POSTGRES_DB: ${POSTGRES_DB:-codex}
  volumes:
    - postgres_data:/var/lib/postgresql/data

Copilot AI changed the title [WIP] Add project structure and Dev Container configuration for Codex Bootstrap Codex project scaffold with Dev Container and Dockerized PostgreSQL Jul 2, 2026
Copilot finished work on behalf of boci11 July 2, 2026 01:13
Copilot AI requested a review from boci11 July 2, 2026 01:13
@boci11 boci11 marked this pull request as ready for review July 2, 2026 01:20
Copilot AI review requested due to automatic review settings July 2, 2026 01:20
@boci11 boci11 merged commit 1bdc917 into main Jul 2, 2026
1 check passed

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR repurposes the repository into a “Codex” project scaffold and adds a consistent local development environment based on Dev Containers and Docker Compose, including a Dockerized PostgreSQL service and example environment variables.

Changes:

  • Replaced the README with Codex onboarding instructions (Dev Container + Compose DB + env usage).
  • Added Dev Container configuration and a minimal dev image with postgresql-client.
  • Added docker-compose.yml, .env.example, and a baseline .gitignore, plus directory placeholders.

Reviewed changes

Copilot reviewed 5 out of 10 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
README.md New onboarding docs for Dev Container + Compose DB + env variables.
docker-compose.yml Adds app (Dev Container) and db (Postgres 16) services with volume persistence.
.devcontainer/devcontainer.json Dev Container config targeting the Compose app service.
.devcontainer/Dockerfile Dev image installs postgresql-client for DB tooling.
.env.example Example env vars for OpenAI key and Postgres configuration.
.gitignore Ignores env files, editor state, caches, logs, and build artifacts.
src/.gitkeep Placeholder to keep src/ in git.
docs/.gitkeep Placeholder to keep docs/ in git.
data/.gitkeep Placeholder to keep data/ in git.
scripts/.gitkeep Placeholder to keep scripts/ in git.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .env.example
Comment on lines +1 to +5
OPENAI_API_KEY=your_openai_api_key_here
POSTGRES_USER=codex
POSTGRES_PASSWORD=__SET_SECURE_PASSWORD__
POSTGRES_DB=codex
POSTGRES_PORT=5432
Comment thread README.md
Comment on lines +41 to +43
Domyślne ustawienia PostgreSQL:
- host: `localhost`
- port: `5432`
Comment thread docker-compose.yml
Comment on lines +3 to +5
build:
context: .
dockerfile: .devcontainer/Dockerfile
Copilot AI added a commit that referenced this pull request Jul 2, 2026
Adds .dockerignore to prevent .env, .git, node_modules, __pycache__,
and other unnecessary files from being included in the Docker build
context. This addresses the review comment (discussion_r3509898653)
and improves security and build performance.

Also includes the project scaffold files (docker-compose.yml,
.devcontainer, .gitignore, .env.example, etc.) that were introduced
in PR #1.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants