R
Railway•12mo ago
k0b13

PowerSync Template Review

I'm still tweaking the branding, the Deploy button etc, but @Brody could you eyeball the meat of this and let me know if anything looks off?
30 Replies
Percy
Percy•12mo ago
Project ID: N/A
Brody
Brody•12mo ago
currently out Christmas shopping for the day so I'll look at it when I'm back home!
k0b13
k0b13OP•12mo ago
No rush! On my way out too
Brody
Brody•12mo ago
im seeing DATABASE_HOST=postgres.railway.internal and DATABASE_PORT=5432 on the powersync-nodejs-backend service, instead, on the postgres service set these variables PGHOST_PRIVATE=${{RAILWAY_PRIVATE_DOMAIN}} and PGPORT_PRIVATE=${{RAILWAY_TCP_APPLICATION_PORT}} and then reference those new variables on the powersync-nodejs-backend service
k0b13
k0b13OP•12mo ago
when I edit the template and make those changes, the button at the bottom says Fork Template, that doesn't seem right
No description
Brody
Brody•12mo ago
uhhh you made this template on your team didn't you
k0b13
k0b13OP•12mo ago
yeah
Brody
Brody•12mo ago
that's bugged right now 😬
k0b13
k0b13OP•12mo ago
haha I feel you so fork and delete old one?
Brody
Brody•12mo ago
you can't delete it either I don't think but try
k0b13
k0b13OP•12mo ago
Yep can confirm
k0b13
k0b13OP•12mo ago
No description
Brody
Brody•12mo ago
welp, fix coming in 2024 the majority of the team is on vacation
k0b13
k0b13OP•12mo ago
nice time of year to say that fix could be round the corner!
Brody
Brody•12mo ago
haha yeah not ideal, but there's not much I can do for bugs that don't affect users workloads
k0b13
k0b13OP•12mo ago
yep same... all good, worst case if a developer uses it, I can help them update these vars in their deployed project
Brody
Brody•12mo ago
I mean it would still work just fine
k0b13
k0b13OP•12mo ago
yeah I was able to update the description a bit to include some more info on what the template does, so there's that. Anyway, appreciate all the help thus far and happy holidays 🙂
Brody
Brody•12mo ago
no problem, always happy to help when templates are involved and happy holidays to you too
k0b13
k0b13OP•12mo ago
Thanks! p.s. The Deploy button totally fits into the color scheme of our docs https://docs.powersync.com/integration-guides/railway-+-powersync
Railway + PowerSync
Integration guide for deploying a Postgres database and custom backend using Railway for Postgres and Node.js hosting.
Brody
Brody•12mo ago
I noticed, it looks great!
k0b13
k0b13OP•7mo ago
@Brody We’re gearing up to release our Open Edition by the end of May which will let customers run full-stack Postgres+PowerSync+Backend on Railway and I want to get your input on our updated Template since it seems we've had nonzero downloads of the previous one. Can I still msg you here when it's ready for a review? (previous Template was Postgres + Backend connected to hosted PowerSync, the update will make it fully self-hosted on Railway with no external deps)
Brody
Brody•7mo ago
absolutely!
k0b13
k0b13OP•7mo ago
are mongodb replicasets supported using the stock mongodb?
Brody
Brody•7mo ago
they do not, it's something you'd have to setup yourself, and I've heard mongo does not make it easy
k0b13
k0b13OP•7mo ago
I have a docker-compose config that sets it up, might give it a whirl
entrypoint:
- bash
- -c
- 'sleep 10 && mongosh --host mongo:27017 --eval ''rs.initiate({_id: "rs0", version: 1, members: [{ _id: 0, host : "mongo:27017" }]})'''
entrypoint:
- bash
- -c
- 'sleep 10 && mongosh --host mongo:27017 --eval ''rs.initiate({_id: "rs0", version: 1, members: [{ _id: 0, host : "mongo:27017" }]})'''
oh, you mean mongo doesn't make it easy on Railway
Brody
Brody•7mo ago
never hardcode the host and port like you're doing there
k0b13
k0b13OP•7mo ago
yup!
Brody
Brody•7mo ago
mongo doesn't make it easy even in a docker compose file lol
Want results from more Discord servers?
Add your server