Watch paths does not work properly with railway config file

In my first project, I have defined watch paths via railway.json file and it is not working.
tried both ways by adding prefixing the paths with / and still does not seems to work.

In my second project, I have defined watch paths via UI and works as expected.

11 Replies

In my first project, I have defined watch paths via railway.json file and it is not working.

tried both ways by adding prefixing the paths with / and still does not seems to work.

In my second project, I have defined watch paths via UI and works as expected.


a year ago

are you trying to use the new builder?


Yes


a year ago

the new builder does not support pulling service config from the railway.json file and it also does not support watch paths


Are there any future plans to support watch pattern in new builder?


a year ago

when / if it goes into GA it will support those things, i dont have an ETA. we recommend you use the legacy builder for now, its much faster now that we use buildkit now


I tied disabling the new builder, but for some reason it gets back on automatically


a year ago

you likely are enabling it elsewhere


Hmm…. Wdym


a year ago

like in a railway.toml file


I don’t see any explicit property set for that,

{
  "$schema": "https://railway.app/railway.schema.json",
  "build": {
    "builder": "DOCKERFILE",
    "watchPatterns": [
    // ….
    ],
    "dockerfilePath": "api-v2.prod.Dockerfile",
    "buildEnvironment": "V2"
  },
  "deploy": {
    "runtime": "V2",
    "numReplicas": 1,
    "sleepApplication": false,
    "restartPolicyType": "ON_FAILURE",
    "restartPolicyMaxRetries": 10
  }
}

Loading...