how to have railways know my secret key
Anonymous
TRIALOP

2 years ago

this is how i've set up my secret key on github. But this doesnt work for railways, so how do i hide my key while giving it to railways. the key is stored in a config.py file

18 Replies

Anonymous
TRIALOP

2 years ago

e3b076a9-e09a-44e9-a06a-732b5ca69de8


brody
EMPLOYEE

2 years ago

use environment variables, set the environment variable in the variables tab of your railway service


Anonymous
TRIALOP

2 years ago

1223321316606607600


Anonymous
TRIALOP

2 years ago

like this?


brody
EMPLOYEE

2 years ago

yep! then just use os.getenv() in code


Anonymous
TRIALOP

2 years ago

on which line


Anonymous
TRIALOP

2 years ago

im not sure how os.getenv() works


brody
EMPLOYEE

2 years ago


Anonymous
TRIALOP

2 years ago

😅

1223323276634488800


brody
EMPLOYEE

2 years ago

well there you go


Anonymous
TRIALOP

2 years ago

well it doesnt work


Anonymous
TRIALOP

2 years ago

idk why


brody
EMPLOYEE

2 years ago

can you provide more information then "doesn't work"


Anonymous
TRIALOP

2 years ago

it says Application failed to respond


Anonymous
TRIALOP

2 years ago

on the domain


brody
EMPLOYEE

2 years ago

what kind of app


Anonymous
TRIALOP

2 years ago

Flask?


brody
EMPLOYEE

2 years ago

you would need to run it with gunicorn then


Loading...