-
Book Overview & Buying
-
Table Of Contents
Python API Development Fundamentals
By :
We previously modified config.py and added ProductionConfig there. Now we have to add the environment variables in Heroku, including the secret key and database URL. In addition to these, let's not forget the Mailgun API key and the Mailgun domain as well. We will set up all of these together in the next exercise.
In this exercise, we will set up the environment variables in the production environment. Fortunately, because we are using Heroku Postgres, the database URL environment variable has already been set up for us. We only need to set ENV, SECRET_KEY, MAILGUN KEY, and DOMAIN. Then, once the setting is complete, after the Deploy code is completed, the application will read the newly added environment variables in App config:
>>>import os >>>os...
Change the font size
Change margin width
Change background colour