Failed to stream build logs: Failed to retrieve build log
rob8624
HOBBYOP

a year ago

Hi, i'm getting this error when using Railway CLI.

The deployment has Backend/Frontend…… project is pointing to repo, with each service having it's root pointing to backend/frontend folder, talking to each other via private url.

I'm trying to test API calls to the backend locally. I railway link, to frontned, then railway up, but this error is being given.

In build logs i get…. Could not find root directory: /frontend

No other problems, deploy is fine. I can push to repo and builds OK.

Project I/D : 4f1d4e07-9f0f-46dd-b818-1e47b72f7c64

Closed

5 Replies

rob8624
HOBBYOP

a year ago

Fixed. User error. Was runnin CLI from within Frontend dir locally. Moved up to main directory, obviously it now sees the frontend dir. 🙂


a year ago

awesome, glad you were able to solve!


a year ago

!s


Status changed to Solved brody 12 months ago


aaryansinha16
HOBBY

a year ago

Hello there,
Project id: 091b1de7-3a3a-4cb4-83c4-f33fc23d9b35
Got something similar in my monorepo.
I want to deploy my api project which is inside apps/api, but it is not able to find it.

My github action:

- name: Deploy to Railway
        run: |
          echo "🚀 Deploying to Railway via CLI using project token"
          # Deploy from the repository root
          railway up --service 78b2b18b-bb84-41e0-be9f-7ba52648069e --detach

Railway.json:

{
  "$schema": "https://railway.app/railway.schema.json",
  "rootDirectory": ".",
  "build": {
    "builder": "NIXPACKS",
    "nixpacksConfigPath": "nixpacks.toml"
  },
  "deploy": {
    "startCommand": "node dist/index.js",
    "healthcheckPath": "/api/hc",
    "healthcheckTimeout": 100,
    "restartPolicyType": "ON_FAILURE",
    "restartPolicyMaxRetries": 10
  },
  "serviceId": "78b2b18b-bb84-41e0-be9f-7ba52648069e"
}

railway logs:
Could not find root directory: apps/api


Status changed to Open Railway 11 months ago


a year ago

This thread was closed, please open your own thread so you can get a more expedient answer


Status changed to Closed adam 11 months ago


Loading...