Docker deployment setup - #128
Draft
ramonechen wants to merge 13 commits into
Draft
Conversation
Add drawers and miscellaneous refinements
Instead of blacklisting files, I adopted the popular whitelist approach that really minifies build size by only keeping the bare necessities needed to build the image.
By default, Node v24.14.0 is bundled with an older version of npm. This line simply updates npm to the version expected by the project's package-lock.json.
Gave the Compose stack and container explicit names, and overall made the file format consistent with the API and SIS scraper configurations.
ramonechen
requested review from
Copilot and
mirmirmirr
and removed request for
Copilot
April 24, 2026 06:20
Contributor
There was a problem hiding this comment.
Pull request overview
Standardizes the project’s Docker/Compose setup (and related CI) to match the deployment conventions used in other CARPI repositories.
Changes:
- Updates
docker-compose.ymlwith clearer dev-environment instructions and more explicit container/image settings. - Adjusts
Dockerfileto pin npm (perpackage-lock.json) and adds clarifying build/run comments. - Adds a GitHub Actions workflow to build/publish the Docker image, and switches
.dockerignoreto an allowlist approach.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
docker-compose.yml |
Renames service and clarifies dev workflow; adds container/image policies and updates volume mounts. |
Dockerfile |
Pins npm version, changes workdir to /site, and documents build/run steps. |
.github/workflows/image-publish.yml |
Adds a reusable workflow call to build/push an image to GHCR on main pushes. |
.dockerignore |
Switches to allowlist-based build context to standardize what’s sent to Docker builds. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
mirmirmirr
requested changes
Apr 24, 2026
To separate dev and prod builds cleanly.
The serve application is very inefficient compared to using NGINX to serve the static files built by `npm build`. Therefore, this commit aims to eliminate the use of serve and the entire Node.js runtime in the production image produced by the Dockerfile. A new build stage has been added to the Dockerfile to build the static files that will be served in production. The production stage has been refactored to use a fresh image with only NGINX to serve those files from the build stage, eliminating the weight of the Node.js runtime. A custom nginx.conf has also been added to provide basic server configuration for the new NGINX server. It simply listens on port 80, and serves the static files within the container.
ramonechen
marked this pull request as draft
April 28, 2026 23:10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request standardizes Compose, Dockerfile, and .dockerignore file formats to be in line with deployment setups of the API and SIS scraper repositories.
Changes include:
.dockerignoreinstead of the old exclusion patternpackage-lock.json