build: drop rust-engine COPY (gitignored binary, runtime has JS fallback)
The Dockerfile referenced /src/rust-engine/addon and /src/rust-engine/npm under COPY --from=build, but .gitignore (lines 87-89) excludes the .node binaries and the build stage doesn't run `node rust-engine/scripts/build.js`. Result: COPY failed with 'directory not found', breaking the deploy chain. The runtime gracefully falls back to JS implementations (we see NativeUnavailableError → JS fallback in test runs), so the image still boots and serves traffic. Real fix later: add rustup to the build stage and compile the addon per architecture. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
ddec9fd019
commit
1f39539b79
1 changed files with 7 additions and 2 deletions
|
|
@ -85,8 +85,13 @@ COPY --from=build /src/dist /opt/sf/dist
|
|||
COPY --from=build /src/pkg /opt/sf/pkg
|
||||
COPY --from=build /src/src/resources /opt/sf/src/resources
|
||||
COPY --from=build /src/scripts/postinstall.js /src/scripts/link-workspace-packages.cjs /src/scripts/ensure-workspace-builds.cjs /opt/sf/scripts/
|
||||
COPY --from=build /src/rust-engine/addon /opt/sf/rust-engine/addon
|
||||
COPY --from=build /src/rust-engine/npm /opt/sf/rust-engine/npm
|
||||
# rust-engine native addon intentionally not shipped here — .gitignore
|
||||
# excludes the .node binaries (lines 87-89) and the build stage doesn't
|
||||
# install the Rust toolchain. The runtime handles NativeUnavailableError
|
||||
# with a JS fallback (visibleWidth, parseRoadmapFile, etc.), so the
|
||||
# server boots and serves API/web traffic. Follow-up: add `rustup` to the
|
||||
# build stage + `RUN node rust-engine/scripts/build.js --release` to
|
||||
# ship the platform-specific binary.
|
||||
COPY --from=build /src/web/.next/standalone /opt/sf/web/.next/standalone
|
||||
|
||||
WORKDIR /workspace
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue