Skip to content

Docker improvements#620

Merged
danhalson merged 11 commits intomainfrom
danhalson/docker-improvements
Nov 20, 2025
Merged

Docker improvements#620
danhalson merged 11 commits intomainfrom
danhalson/docker-improvements

Conversation

@danhalson
Copy link
Copy Markdown
Contributor

@danhalson danhalson commented Nov 18, 2025

Status

Ready for review

What's changed?

  • Bump docker postgres to v17
  • Add a healthcheck to the db container and ensure the api depends on that
  • Move the bundle and node_moduels to volumes for easier installs, automate install & db migrations via the entrypoints
  • Add an example override and update docs for dev containers
  • Force copilot to be installed to prevent corrupted state resulting in error: Cannot find module '/root/.vscode-server/extensions/github.copilot-chat-0.33.1/dist/tikTokenizerWorker.js'

Steps to perform after deploying to production

  • Run docker compose down -v --remove-orphans to remove the volumes (especially postgres)
  • Run docker compose build to upgrade postgres

Note

Upgrade to Postgres 17 with healthchecks, add persistent bundle/node_modules volumes with automated installs via new entrypoints, and enhance dev-container config and docs.

  • Docker/Compose:
    • Upgrade database image to postgres:17 and client to postgresql-client-17.
    • Add DB healthcheck and make api depend on healthy DB.
    • Mount bundle-data and node_modules as named volumes; add tmpfs for tmp/pids and tmp/cache.
  • Entrypoints:
    • New bin/docker-entrypoint.sh and bin/docker-debug-entrypoint.sh run in strict mode, auto-run bundle install/yarn install, prepare DB, and start Rails (debug variant uses rdbg).
  • Dev Container:
    • Add GitHub Copilot extensions in .devcontainer/devcontainer.json.
    • Provide .devcontainer/docker-compose.yml override and docker-compose.override.yml.example for using the dev-container target.
  • Docs:
    • Update README.md with dev-container usage and gem install guidance.

Written by Cursor Bugbot for commit 565e417. This will update automatically on new commits. Configure here.

@cla-bot cla-bot Bot added the cla-signed label Nov 18, 2025
@danhalson danhalson self-assigned this Nov 18, 2025
@danhalson danhalson changed the title Danhalson/docker-improvements Docker improvements Nov 18, 2025
@adrian-rpf adrian-rpf requested a review from Copilot November 20, 2025 09:40
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

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 modernizes the Docker setup by upgrading PostgreSQL from v14 to v17, improving container orchestration, and enhancing the development container experience.

Key Changes

  • Upgraded PostgreSQL to v17 with corresponding client updates and added healthcheck for better container dependency management
  • Introduced volume-based dependency management (bundle and node_modules) with automated installation via entrypoint scripts
  • Enhanced dev-container configuration with additional VS Code extensions and improved documentation

Reviewed Changes

Copilot reviewed 5 out of 7 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
docker-compose.yml Upgraded PostgreSQL to v17, added healthcheck, configured bundle and node_modules volumes, improved service dependency handling
docker-compose.override.yml.example Added example override file for easy dev-container setup
bin/docker-entrypoint.sh Added strict mode, automated bundle/yarn installs, and database preparation
bin/docker-debug-entrypoint.sh Similar improvements to debug entrypoint with proper exec usage
README.md Expanded documentation for dev-container usage and dependency management
Dockerfile Upgraded PostgreSQL client to v17, modernized apt key handling with keyring approach
.devcontainer/devcontainer.json Added GitHub Copilot extensions to prevent corrupted state issues

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

Comment thread docker-compose.yml Outdated
Comment thread docker-compose.yml
@danhalson danhalson force-pushed the danhalson/docker-improvements branch from 1534d66 to 3fb7a1c Compare November 20, 2025 17:29
@adrian-rpf adrian-rpf self-requested a review November 20, 2025 17:32
@danhalson danhalson temporarily deployed to editor-api-p-danhalson--hp7uq4 November 20, 2025 17:35 Inactive
adrian-rpf
adrian-rpf previously approved these changes Nov 20, 2025
Copy link
Copy Markdown
Contributor

@adrian-rpf adrian-rpf left a comment

Choose a reason for hiding this comment

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

Solid updates. Copilot has a point but low priority

@danhalson danhalson temporarily deployed to editor-api-p-danhalson--x2zblr November 20, 2025 18:04 Inactive
@danhalson danhalson force-pushed the danhalson/docker-improvements branch from bafc656 to f23d08a Compare November 20, 2025 18:05
@danhalson danhalson requested a review from Copilot November 20, 2025 18:06
@adrian-rpf adrian-rpf self-requested a review November 20, 2025 18:07
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Copilot reviewed 6 out of 8 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

.devcontainer/docker-compose.yml:1

  • Volume name 'node-modules' should be 'node_modules' to match the mount point in line 11 (/app/node_modules). The inconsistent naming between the volume definition and its usage could cause Docker to create separate volumes instead of using the same one.

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

adrian-rpf
adrian-rpf previously approved these changes Nov 20, 2025
Copy link
Copy Markdown
Contributor

@adrian-rpf adrian-rpf left a comment

Choose a reason for hiding this comment

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

👍🏻 LGTM

@adrian-rpf adrian-rpf temporarily deployed to editor-api-p-danhalson--b76val November 20, 2025 18:10 Inactive
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

This PR is being reviewed by Cursor Bugbot

Details

Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

Comment thread .devcontainer/docker-compose.yml Outdated
@adrian-rpf adrian-rpf self-requested a review November 20, 2025 18:21
Copy link
Copy Markdown
Contributor

@adrian-rpf adrian-rpf left a comment

Choose a reason for hiding this comment

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

👍🏻 1 sure this time

@danhalson danhalson merged commit a44daab into main Nov 20, 2025
6 checks passed
@danhalson danhalson deleted the danhalson/docker-improvements branch November 20, 2025 18:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants