a year ago
I am trying to deploy a django application and I've gone through the steps of trying to reach an environment variable.
On my settings.py file I have:
from decouple import config
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql',
'NAME': config('POSTGRESNAME'), 'USER': config('POSTGRESUSER'),
'PASSWORD': config('POSTGRESPASSWORD'), 'HOST': config('POSTGRESHOST'),
'PORT': config('POSTGRES_PORT', cast=int),
},
}
Added those variables to my project and it's not able to pick it up
ⓘ Deployment information is only viewable by Project members and Railway admins.
4 Replies
a year ago
Locally, it was pulling from .env
. I left my computer for a few minutes and when I got back, the config()
was magically reaching Railway env variables (like it's shown in the logs). Not sure if it takes some time for these variables to propagate once they're added.
Attachments
Status changed to Solved railway[bot] • about 1 year ago
a year ago
That was probably it. Thank you!