Python Django deployment from GitHub to AWS EC2



Python django deployment from GitHub to aws ec2 (Elastic Compute Cloud)

cd Downloads/
mv zillows.pem ~/Desktop/
cd ..
cd desktop

chmod

ssh

yes

sudo apt-get update
sudo apt-get install python-pip python-dev nginx git

Y

sudo apt-get update
sudo pip install virtualenv
git clone
cd zillow
virtualenv venv
source venv/bin/activate
pip install -r requirements.txt
pip install django bcrypt django-extensions
pip install gunicorn
cd zillow
sudo vim…

11 Comments

  1. very good notes but i got this error at last
    command : sudo nginx -t
    error : nginx: [emerg] unexpected "}" in /etc/nginx/sites-enabled/ssmart_project:11
    nginx: configuration file /etc/nginx/nginx.conf test failed

    please help me

  2. Followed your instructions mentioned above but when visited the line http://<my ip>
    returns nothing just page loads 'this site can't be reached'
    when checked the status for the Nginx service it was active but displayed this error :
    nginx.service: Failed to read PID from file /run/nginx.pid: Invalid argument

  3. Hi Mauricio Ruanova-Hurtado,
    I followed your tutorial exactly except project name. However, I got 502 bad gateway error. I checked the web server log and it said: "connect() to unix:/home/ubuntu/blog_project/blog_project.sock failed (2: No such file or directory) while connecting to upstream" How can I fix it? Thanks

Leave a Reply

Your email address will not be published.


*