I want to run a Django application on the App Engine flexible environment.
For the Django sample app, on Cloud SQL I'm using PostgreSQL
At step 4, "Run the Django migrations to set up your models and assets" when I run the "python manage.py makemigrations" command I get a series of errors:
File "C:\Users\zzz\AppData\Local\Programs\Python\Python39\lib\site-packages\environ\environ.py", line 367, in get_value
value = self.ENVIRON[var]
File "C:\Users\zzz\AppData\Local\Programs\Python\Python39\lib\os.py", line 679, in __getitem__
raise KeyError(key) from None
KeyError: 'SECRET_KEY'
During handling of the above exception, another exception occurred:
....
File "C:\Users\zzz\AppData\Local\Programs\Python\Python39\lib\site-packages\environ\environ.py", line 371, in get_value
raise ImproperlyConfigured(error_msg)
django.core.exceptions.ImproperlyConfigured: Set the SECRET_KEY environment variable
What could be the cause? I followed the documentation step by step.
Of course, on the code samples I edited the db name, the db password, project ID, region, instance name, bucket name etc
Thank you!
Valdinia