#How to get Port as Env var?
10 messages · Page 1 of 1 (latest)
Project ID: N/A
N/A
The port environment variable is automatically generated, but if you want to create one specifically for a particular port just set an environment variable in your service called PORT to your desired port number
Thanks for the response.
To clarify, I want to know what Railway;s dynamic port is
so I can remap it to an app specific env var
It will tell you when you deploy the service in the deploy log
It would just be PORT
so in my env var I would do
VAR_NAME = ${PORT}
Yes