EMAIL_BECKEND = 'django_smtp_ssl.SSLEmailBackend' (or EMAIL_BECKEND = 'backends.smtp.SSLEmailBackend')
EMAIL_HOST = 'email-smtp.us-east-1.amazonaws.com'
EMAIL_PORT = 465
EMAIL_HOST_USER = 'SMTP USERNAME'
EMAIL_HOST_PASSWORD = 'SMTP PASSWORD'
EMAIL_USE_TLS = True
Category: Python
Run Python Project On Port 80 Apache2 Configuration
<VirtualHost *:80>
ServerName domain.com
ServerAlias www.domain.com
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html/(python project folder Name)
<Directory /var/www/html/(python project folder Name)>
AllowOverride All
</Directory>
Alias /static /var/www/html/(python project folder Name)/static
<Directory /var/www/html/(python project folder Name)/static>
Require all granted
</Directory>
Alias /static /var/www/html/(python project folder Name)/media
<Directory /var/www/html/(python project folder Name)/media>
Require all granted
</Directory>
<Directory /var/www/html/(python project folder Name)/(python project folder Name)>
<Files wsgi.py>
Require all granted
</Files>
Require all granted
</Directory>
LoadModule wsgi_module “/var/www/html/myenv/lib/python3.6/site-packages/mod_wsgi/server/mod_wsgi-py36.cpython-36m-x86_64-linux-gnu.so”
WSGIDaemonProcess myenv1 python-path=/var/www/html/(python project folder Name):/var/www/html/myenv/lib/python3.6/site-packages
WSGIProcessGroup myenv1
WSGIScriptAlias / /var/www/(python project folder Name)/(python project folder Name)/wsgi.py
WSGIPassAuthorization On
WSGIApplicationGroup %{GLOBAL}
</VirtualHost>
Setup server for python ubuntu 16.04 LTE
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install apache2
sudo apt-get install python-pip
python –version
sudo pip install –upgrade pip
sudo pip install –upgrade virtualenv
sudo apt-get install mysql-server libmysqlclient-dev
cd document root
virtualenv myvenv
source myvenv/bin/activate
pip freeze (show install modules)
pip install Django
pip install mysqlclient