I don't recommend setting them in bashrc - cron doesn't read bashrc, so if the server were unexpectedly rebooted or if your processes were terminated for some reason your app wouldn't have its environment when your cron job runs to restart it.
On our setup you can set environment variables in your app's uwsgi.ini
file, eg:
env = FOO=bar
To set multiple variables, add a line with an env
directive for each variable you need.
There are also Django projects that you can use to manage environment variables and settings for you, eg:
You could also set them in the app's start
script that our installer sets up for you - it's a regular bash shell script so feel free to customize it.
Hope this helps 🙂