2 years ago
I'm new to railway and I was trying to create a railway.json file do describe my deployment but it seems that this can only be used to describe my app (not including its services). Is there a way to transform my existing docker-compose file into a descriptor that I can use instead of having to fiddle around on the Railway UI? This is what I have for reference (I omitted the details):
version: "3.7"
services:
postgres:
image: postgres
tempo:
image: grafana/tempo:latest
prometheus:
image: prom/prometheus:latest
grafana:
image: grafana/grafana:10.1.114 Replies
2 years ago
You would need to create separate services for each of them, docker-compose isn't supported yet
You might want to take a look at the marketplace to find pre-existing templates for the service you want to use.
postgres: https://railway.app/template/postgres
grafana: https://railway.app/template/anURAt
prometheus: https://railway.app/template/KmJatA
I couldn't find one for tempo
Alternatively, you could write your own dockerfiles, eg. dockerfile.grafana, dockerfile.tempo, and so on, and point them to Railway
i think i'll just leave things as-is until i can use some sort of IaC descriptor
do you have plans to support this config as code use case (describe the whole project, not just services individually)
2 years ago
(Jeremy doesn't work for railway)
2 years ago
yes and what Jeremy said is entirely correct
so I can set up my project by clicking through, but what would be really awesome is if I had a d escriptor (like this docker compose file) that I can use locally like
railway deploy-project localor remotely onto Railway like
railway deploy-project remoteand it would use the same file so I can have consistent environments both locally and remotely and whenever I change this file it would apply the changes to my project
2 years ago
there's a community developed terraform provider, but if I recall correctly it has it's shortcomings, otherwise you need to create the services manually as per Jeremy's message
2 years ago
the project canvas it is!