Lukoolios
Lukoolios
RRailway
Created by Lukoolios on 12/20/2023 in #✋|help
Docker build failed Next.js
I am looking to deploy my next.js app on railway. I've added environment variables, added railway.toml file to root and I am still getting a docker failed error. It seems to be that there is a space after ENV on line 12 but not sure how to correct that? I dont have docker or access to that file. here is a copy of the build log:
Dockerfile:12

-------------------

10 |

11 | ARG CI NIXPACKS_METADATA NODE_ENV NPM_CONFIG_PRODUCTION RAILWAY_ENVIRONMENT RAILWAY_ENVIRONMENT_ID RAILWAY_ENVIRONMENT_NAME RAILWAY_GIT_AUTHOR RAILWAY_GIT_BRANCH RAILWAY_GIT_COMMIT_MESSAGE RAILWAY_GIT_COMMIT_SHA RAILWAY_GIT_REPO_NAME RAILWAY_GIT_REPO_OWNER RAILWAY_PROJECT_ID RAILWAY_PROJECT_NAME RAILWAY_PUBLIC_DOMAIN RAILWAY_SERVICE_ID RAILWAY_SERVICE_NAME RAILWAY_SERVICE_PROJECT_PIXEL_POUCH_URL RAILWAY_STATIC_URL

12 | >>> ENV =$ CI=$CI NIXPACKS_METADATA=$NIXPACKS_METADATA NODE_ENV=$NODE_ENV NPM_CONFIG_PRODUCTION=$NPM_CONFIG_PRODUCTION RAILWAY_ENVIRONMENT=$RAILWAY_ENVIRONMENT RAILWAY_ENVIRONMENT_ID=$RAILWAY_ENVIRONMENT_ID RAILWAY_ENVIRONMENT_NAME=$RAILWAY_ENVIRONMENT_NAME RAILWAY_GIT_AUTHOR=$RAILWAY_GIT_AUTHOR RAILWAY_GIT_BRANCH=$RAILWAY_GIT_BRANCH RAILWAY_GIT_COMMIT_MESSAGE=$RAILWAY_GIT_COMMIT_MESSAGE RAILWAY_GIT_COMMIT_SHA=$RAILWAY_GIT_COMMIT_SHA RAILWAY_GIT_REPO_NAME=$RAILWAY_GIT_REPO_NAME RAILWAY_GIT_REPO_OWNER=$RAILWAY_GIT_REPO_OWNER RAILWAY_PROJECT_ID=$RAILWAY_PROJECT_ID RAILWAY_PROJECT_NAME=$RAILWAY_PROJECT_NAME RAILWAY_PUBLIC_DOMAIN=$RAILWAY_PUBLIC_DOMAIN RAILWAY_SERVICE_ID=$RAILWAY_SERVICE_ID RAILWAY_SERVICE_NAME=$RAILWAY_SERVICE_NAME RAILWAY_SERVICE_PROJECT_PIXEL_POUCH_URL=$RAILWAY_SERVICE_PROJECT_PIXEL_POUCH_URL RAILWAY_STATIC_URL=$RAILWAY_STATIC_URL

13 |

14 | # setup phase

-------------------

ERROR: failed to solve: dockerfile parse error on line 12: ENV names can not be blank



Error: Docker build failed
Dockerfile:12

-------------------

10 |

11 | ARG CI NIXPACKS_METADATA NODE_ENV NPM_CONFIG_PRODUCTION RAILWAY_ENVIRONMENT RAILWAY_ENVIRONMENT_ID RAILWAY_ENVIRONMENT_NAME RAILWAY_GIT_AUTHOR RAILWAY_GIT_BRANCH RAILWAY_GIT_COMMIT_MESSAGE RAILWAY_GIT_COMMIT_SHA RAILWAY_GIT_REPO_NAME RAILWAY_GIT_REPO_OWNER RAILWAY_PROJECT_ID RAILWAY_PROJECT_NAME RAILWAY_PUBLIC_DOMAIN RAILWAY_SERVICE_ID RAILWAY_SERVICE_NAME RAILWAY_SERVICE_PROJECT_PIXEL_POUCH_URL RAILWAY_STATIC_URL

12 | >>> ENV =$ CI=$CI NIXPACKS_METADATA=$NIXPACKS_METADATA NODE_ENV=$NODE_ENV NPM_CONFIG_PRODUCTION=$NPM_CONFIG_PRODUCTION RAILWAY_ENVIRONMENT=$RAILWAY_ENVIRONMENT RAILWAY_ENVIRONMENT_ID=$RAILWAY_ENVIRONMENT_ID RAILWAY_ENVIRONMENT_NAME=$RAILWAY_ENVIRONMENT_NAME RAILWAY_GIT_AUTHOR=$RAILWAY_GIT_AUTHOR RAILWAY_GIT_BRANCH=$RAILWAY_GIT_BRANCH RAILWAY_GIT_COMMIT_MESSAGE=$RAILWAY_GIT_COMMIT_MESSAGE RAILWAY_GIT_COMMIT_SHA=$RAILWAY_GIT_COMMIT_SHA RAILWAY_GIT_REPO_NAME=$RAILWAY_GIT_REPO_NAME RAILWAY_GIT_REPO_OWNER=$RAILWAY_GIT_REPO_OWNER RAILWAY_PROJECT_ID=$RAILWAY_PROJECT_ID RAILWAY_PROJECT_NAME=$RAILWAY_PROJECT_NAME RAILWAY_PUBLIC_DOMAIN=$RAILWAY_PUBLIC_DOMAIN RAILWAY_SERVICE_ID=$RAILWAY_SERVICE_ID RAILWAY_SERVICE_NAME=$RAILWAY_SERVICE_NAME RAILWAY_SERVICE_PROJECT_PIXEL_POUCH_URL=$RAILWAY_SERVICE_PROJECT_PIXEL_POUCH_URL RAILWAY_STATIC_URL=$RAILWAY_STATIC_URL

13 |

14 | # setup phase

-------------------

ERROR: failed to solve: dockerfile parse error on line 12: ENV names can not be blank



Error: Docker build failed
project id: 7a7981e0-b081-4941-8efd-d9c6a55d5383
37 replies
RRailway
Created by Lukoolios on 6/4/2023 in #✋|help
React front end MongoDB Cannot connect
I am having issues connecting my mongoDB back end and react front end. I have store proper env variables within railway and updated url within front end to reference new backend url. These are the error messages i have recieved: Invalid Host header - This is from the front end Cannot GET / - This is from the back end id: 929d0c8e-0db8-48c7-960f-034b7b907500
61 replies
RRailway
Created by Lukoolios on 4/27/2023 in #✋|help
Deploying React App with Sanity backend
Project ID: 0de2004b-a959-415e-ab35-f0522f3f8ac0 I am having issues with deployment. I have a React app with a Sanity backend that runs on local but is having issues deploying. Specifically receiving this error: npm WARN config production Use --omit=dev instead. npm ERR! Missing script: "start" npm ERR! npm ERR! Did you mean one of these? npm ERR! npm star # Mark your favorite packages npm ERR! npm stars # View packages marked as favorites npm ERR! npm ERR! To see a list of scripts, run: npm ERR! npm run npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2023-04-27T19_54_41_363Z-debug-0.log I have all dependencies installed and ran npm install on both the front and backend to ensure all were available and verified that the JSON files both have the start script.
51 replies