How To Put a File That Is Not On Source Control On a Railway Docker Application
Hello I have a question. I would like to know how I can add a file that is not in my GitHub source control to a Django application. Specifically, I want to add a custom settings file for production. Is there any procedure that I can take to make this happen? Thanks!
Solution:Jump to solution
yeah I think that's fine, just keep everything even remotely sensitive as environment variables
9 Replies
Project ID:
N/A
N/A
without a native filebrowser I can't think of a straight forward way to do this
Thank you @Brody for your response, I had looked into a file browser for railway but it is a template: https://railway.app/template/guiCBv.
I am not sure if I would be able to attach that to my Django application that is pulled from GitHub
yeah I know, I didn't mention it because that's fine if you wanna put something on a volume once and never touch it again but if you need to keep changing the file it's not going to be fun
you would have to move the volumes around since you can only attach one volume to one single service at a time
That makes sense. I suppose it would be rather inefficent to do this. In your opinion, would it make more sense to simply add my settings file to source control but ensure that I am using environment variables over potentially sensitive information? I know that some Django practices typically have a separate settings file for local development and one for production but perhaps doing it this way would be better for railway?
Solution
yeah I think that's fine, just keep everything even remotely sensitive as environment variables
Awesome thank you @Brody !
no problem!