Trying to deploy to Railway - what am I missing?

default discord avatar
.mike100111 months ago
2

Just gives me "Application failed to respond" with a 503 in the console. If anyone can point me towards a deploy guide for Railway that would be amazing

:niceone:



Mongo set and working


Node_env set to prod


Payload_config path set


Payload_secret set



Have tried with docker and nixpacks. Have run build command before push



Gives me this after build



yarn run v1.22.19


$ yarn build && yarn serve


$ yarn copyfiles && yarn build:payload && yarn build:server


$ copyfiles -u 1 "src/*

/

.{html,css,scss,ttf,woff,woff2,eot,svg,jpg,png}" dist/


$ cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts payload build


$ tsc


$ cross-env PAYLOAD_CONFIG_PATH=dist/payload.config.js NODE_ENV=production node dist/server.js


[19:45:51] INFO (payload): Connected to MongoDB server successfully!


[19:45:51] INFO (payload): Starting Payload...


[19:45:52] INFO (payload): Payload Admin URL: Correct URL/admin

  • discord user avatar
    alessiogr
    11 months ago

    Railway also requires a

    PORT

    environment variable to be set. This is specific to Railway.



    I've also recorded a railway deployment tutorial a while back here:

    https://www.youtube.com/watch?v=0XmQE03y5Ek

    🙂

  • default discord avatar
    .mike100111 months ago

    Amazing - thanks for the help.

    :payloadlove:
Star on GitHub

Star

Chat on Discord

Discord

online

Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.