Open antonleviathan opened 1 year ago
Hey @Cameri Any updates or suggestions for how this issue could be fixed??
I was using an older version of the relay deployed on railway, but today when I updated to the latest version, I faced this error & my project is crashing & not working right now...
I tried adding this line to my Dockerfile.railwayapp
file as #190 suggested:
...
WORKDIR /app
COPY --from=build /build/dist .
+ ADD resources /app/resources
+ COPY .railwayapp/settings.yaml /app/.nostr/settings.yaml
RUN npm install --omit=dev --quiet
USER 1000:1000
RUN mkdir -p $NOSTR_CONFIG_DIR
And I created a file at ./railwayapp/settings.yaml
with the same content of the default-settings.yaml
file.
But it's now a different error:
node:internal/fs/watchers:255
throw error;
^
Error: ENOENT: no such file or directory, watch '/home/node/.nostr/settings.yaml'
at FSWatcher.<computed> (node:internal/fs/watchers:247:19)
at Object.watch (node:fs:2343:34)
at SettingsStatic.watchSettings (/app/src/utils/settings.js:107:26)
at App.run (/app/src/app/app.js:35:51)
at Object.<anonymous> (/app/src/index.js:33:30)
at Module._compile (node:internal/modules/cjs/loader:1254:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)
at Module.load (node:internal/modules/cjs/loader:1117:32)
at Module._load (node:internal/modules/cjs/loader:958:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12) {
errno: -2,
syscall: 'watch',
code: 'ENOENT',
path: '/home/node/.nostr/settings.yaml',
filename: '/home/node/.nostr/settings.yaml'
}
It seems like it wants me to provide a custom settings file even though there is a default one...
I see in the README that in the QuickStart
section, you say that we should copy default-settigs.yaml file to .nostr/settings.yaml
file, is this the case here too??
Even though the .nostr
folder is gitignored and it won't be uploaded??
Any advice is greatly appreciated. Cause as I said, my relay is currently down.
@antonleviathan Have you fixed the issue for yourself btw?
I fixed the issue.
The path to the settings
file was incorrect.
So when I changed it to this:
COPY --from=build /build/dist .
ADD resources /app/resources
RUN mkdir -p $NOSTR_CONFIG_DIR
COPY .railwayapp/settings.yaml $NOSTR_CONFIG_DIR/settings.yaml
It worked.
I've just encountered the same issue. Trying @MTG2000 's solution now
Fixed it for me, too. Thanks @MTG2000