Bootstrap CodePress Live Dev Server recipe + dev Dockerfile - #57
Open
codepress-dev[bot] wants to merge 1 commit into
Open
Bootstrap CodePress Live Dev Server recipe + dev Dockerfile#57codepress-dev[bot] wants to merge 1 commit into
codepress-dev[bot] wants to merge 1 commit into
Conversation
Adds the repo-committed Live Dev Server artifacts so previews boot from this repo instead of a runtime heuristic: - .codepress/dev-server/recipe.json - one frontend entry for web/ (CRA, yarn, port 3000) - .codepress/dev-server/Dockerfile.web - thin dev-mode image (no baked node_modules, no source COPY) that binds 0.0.0.0 and wires HMR to env vars Node 18 is pinned because this app is Create React App 1.0.10 (webpack 2.6.1 / webpack-dev-server 2.5.0). Verified during bootstrap that yarn install --frozen-lockfile + react-scripts start compile and serve on Node 18.20.8, honor PORT, bind all interfaces, answer a preview-style Host header with HTTP 200, and expose a live /sockjs-node HMR endpoint. No staging backend URL was detected (repo has no .env*, CI, or deploy config), so staging_backend_url is intentionally omitted. No preview-CORS change was needed: the Django app in server/ serves the built React bundle same-origin and has no CORS surface or cross-origin caller. Co-authored-by: dev@codepress.dev <dev@codepress.dev>
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.
Summary
Adds the repository-owned development-server recipe for the React frontend so preview sessions run the correct Yarn-based development command with hot reload.
Technical details
webCreate React App frontend, its port, lockfile, and required process tooling.Test plan
weband confirm it loads on port 3000.Generated with CodePress