nball
nball
RRailway
Created by nball on 9/16/2023 in #✋|help
Payload CMS app 500 error
URL: https://edit.gravybo.at/ ID: 9c654a5e-96b8-42bd-a2a0-d82a9e0b8d11 App builds/runs locally, however returns 500 error in production, failing health check. Logs attached. Observability tab claims the app is running:
[15:38:14] INFO (payload): Connected to MongoDB server successfully!
[15:38:14] INFO (payload): Starting Payload...
[15:38:16] INFO (payload): Payload Admin URL: /admin
[15:38:14] INFO (payload): Connected to MongoDB server successfully!
[15:38:14] INFO (payload): Starting Payload...
[15:38:16] INFO (payload): Payload Admin URL: /admin
4 replies
RRailway
Created by nball on 9/11/2023 in #✋|help
Easy (?) shared variables question
The environment contains the excellent Payload CMS template, attendant Mongo DB, and a Next.js front end. This works well when the env are set manually for each service, however the shared variables don't. What am I missing? This works when set on each service, eg. not shared
NEXT_PUBLIC_SERVER_URL=https://cowcatcher.up.railway.app/
PAYLOAD_PUBLIC_SERVER_URL=https://caboose.up.railway.app/
NEXT_PUBLIC_SERVER_URL=https://cowcatcher.up.railway.app/
PAYLOAD_PUBLIC_SERVER_URL=https://caboose.up.railway.app/
The shared variables do not work
NEXT_PUBLIC_SERVER_URL=https://${{cowcatcher.RAILWAY_PUBLIC_DOMAIN}}
PAYLOAD_PUBLIC_SERVER_URL=https://${{caboose.RAILWAY_PUBLIC_DOMAIN}}
NEXT_PUBLIC_SERVER_URL=https://${{cowcatcher.RAILWAY_PUBLIC_DOMAIN}}
PAYLOAD_PUBLIC_SERVER_URL=https://${{caboose.RAILWAY_PUBLIC_DOMAIN}}
When shared on both front and back end services, the variables look like this
NEXT_PUBLIC_SERVER_URL=${{shared.NEXT_PUBLIC_SERVER_URL}}
PAYLOAD_PUBLIC_SERVER_URL=${{shared.PAYLOAD_PUBLIC_SERVER_URL}}
NEXT_PUBLIC_SERVER_URL=${{shared.NEXT_PUBLIC_SERVER_URL}}
PAYLOAD_PUBLIC_SERVER_URL=${{shared.PAYLOAD_PUBLIC_SERVER_URL}}
Project ID 520ae57c-db3e-4e21-ace6-db67bca65e2a
75 replies
RRailway
Created by nball on 8/28/2023 in #✋|help
Nextjs build fail - runc run failed: unable to start container process
Deployment ID dd25dd4a-51bd-489e-94a0-387b5ef51852 and github repo using Nixpacks with nixpacks.toml courtesy of @Brody on an earlier iteration. Note, build randomly worked once out of dozens of attempts today. Error logs attached. Two key errors appear to be:
#14 0.442 runc run failed: unable to start container process: error during container init: error mounting "/var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff" to rootfs at "/app/tsconfig.tsbuildinfo": mount /var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff:/app/tsconfig.tsbuildinfo (via /proc/self/fd/6), flags: 0x5000: not a directory

#14 ERROR: process "/bin/bash -ol pipefail -c npm run build" did not complete successfully: exit code: 1
#14 0.442 runc run failed: unable to start container process: error during container init: error mounting "/var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff" to rootfs at "/app/tsconfig.tsbuildinfo": mount /var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff:/app/tsconfig.tsbuildinfo (via /proc/self/fd/6), flags: 0x5000: not a directory

#14 ERROR: process "/bin/bash -ol pipefail -c npm run build" did not complete successfully: exit code: 1
As well as
> [stage-0 8/11] RUN --mount=type=cache,id=s/a4202936-edb2-4b30-8f88-d5d5dd20d757-next/cache,target=/app/.next/cache --mount=type=cache,id=s/a4202936-edb2-4b30-8f88-d5d5dd20d757-node_modules/cache,target=/app/node_modules/.cache --mount=type=cache,id=s/a4202936-edb2-4b30-8f88-d5d5dd20d757-tsconfigtsbuildinfo,target=/app/tsconfig.tsbuildinfo npm run build:

0.442 runc run failed: unable to start container process: error during container init: error mounting "/var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff" to rootfs at "/app/tsconfig.tsbuildinfo": mount /var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff:/app/tsconfig.tsbuildinfo (via /proc/self/fd/6), flags: 0x5000: not a directory
> [stage-0 8/11] RUN --mount=type=cache,id=s/a4202936-edb2-4b30-8f88-d5d5dd20d757-next/cache,target=/app/.next/cache --mount=type=cache,id=s/a4202936-edb2-4b30-8f88-d5d5dd20d757-node_modules/cache,target=/app/node_modules/.cache --mount=type=cache,id=s/a4202936-edb2-4b30-8f88-d5d5dd20d757-tsconfigtsbuildinfo,target=/app/tsconfig.tsbuildinfo npm run build:

0.442 runc run failed: unable to start container process: error during container init: error mounting "/var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff" to rootfs at "/app/tsconfig.tsbuildinfo": mount /var/lib/docker/overlay2/ylv4o55u3eenxetp8t9mxexop/diff:/app/tsconfig.tsbuildinfo (via /proc/self/fd/6), flags: 0x5000: not a directory
I am way out of my depth on this one.
43 replies
RRailway
Created by nball on 8/23/2023 in #✋|help
Simple next.js build fail
deployment ID 6b59c99d-f9d1-42bb-9733-67e02909cdc5 Repo: https://github.com/ballermatic/nextjs-shadcn Error:
#12 0.524 runc run failed: unable to start container process: error during container init: error mounting "/var/lib/docker/overlay2/e5otij3fmo9s1ewupul8502po/diff" to rootfs at "/app/tsconfig.tsbuildinfo": mount /var/lib/docker/overlay2/e5otij3fmo9s1ewupul8502po/diff:/app/tsconfig.tsbuildinfo (via /proc/self/fd/6), flags: 0x5000: not a directory

#12 ERROR: process "/bin/bash -ol pipefail -c yarn run build" did not complete successfully: exit code: 1
#12 0.524 runc run failed: unable to start container process: error during container init: error mounting "/var/lib/docker/overlay2/e5otij3fmo9s1ewupul8502po/diff" to rootfs at "/app/tsconfig.tsbuildinfo": mount /var/lib/docker/overlay2/e5otij3fmo9s1ewupul8502po/diff:/app/tsconfig.tsbuildinfo (via /proc/self/fd/6), flags: 0x5000: not a directory

#12 ERROR: process "/bin/bash -ol pipefail -c yarn run build" did not complete successfully: exit code: 1
I'm stumped. This is using nixpacks, builds fine locally. Any ideas?
46 replies
RRailway
Created by nball on 8/22/2023 in #✋|help
Payload CMS + Nextjs Deployment Failed during build process
Using the template courtesy of @Brody with Next.js added as seen here, the UI states deployment fails during build process, however it appears that the build completes, but the push times out. Here's the repo and deployment ID is e2d1ce03-417c-4c0e-aa79-d31db48d0ac7
25 replies
RRailway
Created by nball on 3/28/2023 in #✋|help
dotenv not working? How are you accessing your ENV?
Service variables are correct in Railway, yet build fails due to missing variables. Local builds work fine with dotenv, however require('dotenv').config(); does not appear to be working on Railway. I must be missing something obvious! Any ideas? PID: 06cbb529-6fb3-4792-84b5-af7b23eb272f
5 replies