These are chat archives for django/django

22nd
Oct 2018
Akaash Patel
@Akaash454_twitter
Oct 22 2018 05:10
Hey Guys, I was wondering if anyone had any experience deploying their Django apps to google cloud?
I'm trying to follow the steps listed here, but am having some trouble.
I've tried following Google's official steps for deploying with Django, but I'm getting an error with that too and ran into a block after searching through stackoverflow
Using latest version of Django and Python3. Thanks.
AJ
@ajostergaard
Oct 22 2018 07:29
@Akaash454_twitter error are you getting?
*what
Akaash Patel
@Akaash454_twitter
Oct 22 2018 15:42
Hey @ajostergaard, thanks for the help! So, I added an app.yaml file. My understanding is that this file is just used for storing details about the build config and I'm setting some environment variables in that file, so I don't have to store those values in my settings.py file.
However, I'm confused as to how I should be running my app.yaml file locally (if that makes sense), so that I can get the environment variables set up in bash
so I can push my static project files up to Google Cloud's storage bucket.
connexion2000
@connexion2000
Oct 22 2018 16:39
After running Django app, I need to do some cleanup. Where in Django should I put cleanup code?
Mike Simkins
@msimkins
Oct 22 2018 17:03
@connexion2000 Not really Django specific, and I guess it depends what you are doing, but you could use the atexit handler
connexion2000
@connexion2000
Oct 22 2018 18:42
@msimkins thanks
AJ
@ajostergaard
Oct 22 2018 19:39
@Akaash454_twitter I set my local environment variables in a local file and my remote environment variables in a file I upload... Obviously some variables are repeated but most are not. Not sure if that answers your question - sorry. I thought you had an error... I like errors. :)