Can't deploy
when trying to deploy on railway I always get this:
ERROR: failed to solve: process "/bin/bash -ol pipefail -c npm ci" did not complete successfully: exit code: 1
5 Replies
Project ID:
0a0a8619-9f39-48bd-bb94-74e9b5ad35bd
0a0a8619-9f39-48bd-bb94-74e9b5ad35bd
2.298 npm ERR! npm ci
2.298 npm ERR!
2.298 npm ERR! Options:
2.298 npm ERR! [--install-strategy <hoisted|nested|shallow|linked>] [--legacy-bundling]
2.298 npm ERR! [--global-style] [--omit <dev|optional|peer> [--omit <dev|optional|peer> ...]]
2.298 npm ERR! [--strict-peer-deps] [--foreground-scripts] [--ignore-scripts] [--no-audit]
2.298 npm ERR! [--no-bin-links] [--no-fund] [--dry-run]
2.298 npm ERR! [-w|--workspace <workspace-name> [-w|--workspace <workspace-name> ...]]
2.298 npm ERR! [-ws|--workspaces] [--include-workspace-root] [--install-links]
2.298 npm ERR!
2.298 npm ERR! aliases: clean-install, ic, install-clean, isntall-clean
2.298 npm ERR!
2.298 npm ERR! Run "npm help ci" for more info
2.301
2.301 npm ERR! A complete log of this run can be found in: /root/.npm/_logs/2024-02-18T11_46_42_519Z-debug-0.log
------
Dockerfile:20
--------------------
18 | ENV NIXPACKS_PATH /app/node_modules/.bin:$NIXPACKS_PATH
19 | COPY . /app/.
20 | >>> RUN --mount=type=cache,id=q1qzhXAPMQ8-/root/npm,target=/root/.npm npm ci
21 |
22 | # build phase -------------------- ERROR: failed to solve: process "/bin/bash -ol pipefail -c npm ci" did not complete successfully: exit code: 1 Error: Docker build failed
22 | # build phase -------------------- ERROR: failed to solve: process "/bin/bash -ol pipefail -c npm ci" did not complete successfully: exit code: 1 Error: Docker build failed
most likely the package-lock.json is gitignored and is not getting pushed with the image, and this file is required for running
npm ci
I tried deleting the package-lock.json and npm i
And it's not gitignored
if the lock file is not in the project files
npm ci
is not ran, npm i
would be ran instead
please provide full logs https://bookmarklets.up.railway.app/log-downloader/