Expose environment variables on build

I'm building my Rust project on Railway using a custom Dockerfile. My build requires DATABASE_URL to be set during the build stage since it checks queries at compile-time. How do I expose my environment variables when my app is building?
5 Replies
Percy
Percy2y ago
Project ID: 8faf68d3-92c6-4d93-b6ac-fd5e63e66780
hexcowboy
hexcowboyOP2y ago
8faf68d3-92c6-4d93-b6ac-fd5e63e66780
eirk
eirk2y ago
add
ARG DATABSE_URL
ARG DATABSE_URL
to ur dockerfil
hexcowboy
hexcowboyOP2y ago
got it, thank you
Want results from more Discord servers?
Add your server