15 Replies
2 years ago
Would probably need to use dockerfile and define an env var there with some kind of library you add during build
2 years ago
ty, ideally it would be the git SHA for the current release
2 years ago
hmmm
2 years ago
RAILWAYDEPLOYMENTID
2 years ago
maybe this would work
2 years ago
RAILWAYGITCOMMIT_SHA
2 years ago
oooo
2 years ago
even better!!
@macwilko how did you solve this? I tried using RAILWAY_GIT_COMMIT_SHA but I get an empty string
10 months ago
RAILWAY_GIT_COMMIT_SHA works fine.

10 months ago
are you perhaps trying to reference it in a service variable? or are you using a dockerfile?
oh I can't reference it from a service variable? I was trying to create an alias to APP_VERSION
it's weird that some variables work and some don't. RAILWAY_ENVIRONMENT_NAME for example can be used in service variables just fine
10 months ago
the SHA variable is a dynamic variable and by its nature would only be available on container build and start since it's only know when you push to GitHub, how would the dashboard have any way of knowing it's value?