开发者

how do I deploy Django on AWS? [closed]

开发者 https://www.devze.com 2022-12-14 03:58 出处:网络
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
开发者_StackOverflow中文版

We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.

Closed 5 years ago.

Improve this question

I'm looking to deploy a django app on AWS (since I have some credit coupon) and am looking for a good place to read about it - mostly b/c I never used it before. thanks


looking for a good place to read about it

Here you go


I am a developer at BitNami, you may want to take a look at our free Django AMI. It is compatible with the AWS free tier.


2 new tutorials are given realpython doc

and Ashok Fernandez blog


The simplest approach is to simply spin up an EC2 instance, install nginx (mysql? and any other dependencies you might have) then follow the steps on the django site: https://code.djangoproject.com/wiki/DjangoAndNginx to deploying it. This basically goes through setting up a script to run "python [your app directory]/manage.py runfcgi host=127.0.0.1 port=8080" and setting up nginx to proxy requests to that port.

Another approach is to simply use a 3rd party tool like http://nudow.com to automate the deployment. For now the initial deployment I believe has to be done manually, however subsequent deployments can be done with one click. (and has other benefits like versioning)


I usually use Nginx on an EC2 instance


If you wish to deploy your Django app ASAP, without scratching your head :

You can use this script that I wrote: Safely deploy your Django app in less 1 minute!

Instructions

Installing the DeployDjango script

$ wget https://raw.githubusercontent.com/yask123/DeployDjango/master/deploydjango.sh && chmod +x deploydjango.sh

From your Django App’s root directory (Where manage.py file exists).

$ sudo ./deploydjango.sh project_name

Done!

Visit http://ip-address-of-your-instance to see your web app live!

0

精彩评论

暂无评论...
验证码 换一张
取 消