Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
350 votes
23 answers
129k views

How to manage local vs production settings in Django?

What is the recommended way of handling settings for local development and the production server? Some of them (like constants, etc) can be changed/accessed in both, but some of them (like paths to ...
akv's user avatar
  • 3,703
157 votes
25 answers
215k views

H14 error in heroku - "no web processes running"

error H14 happen while deploying to heroku this is my procfile: web: gunicorn -w 4 -b 0.0.0.0:$PORT -k gevent main:app log on heroku: 2017-01-23T10:42:58.904480+00:00 heroku[router]: at=error code=...
Ron Miles's user avatar
  • 1,593
88 votes
21 answers
113k views

Collectstatic error while deploying Django app to Heroku

I'm trying to deploy a Django app to Heroku, it starts to build, download and installs everything, but that's what I get when it comes to collecting static files $ python manage.py collectstatic --...
Stefano De Rosso's user avatar
85 votes
4 answers
18k views

Deploying Django with gunicorn and nginx

This is a broad question but I'd like to get a canonical answer. I have been trying to deploy a site using gunicorn and nginx in Django. After reading tons of tutorials I have been successful but I ...
r_31415's user avatar
  • 8,962
81 votes
6 answers
23k views

Is virtualenv recommended for django production server? [closed]

I have always been using virtualenv for testing my app in localhost since I have isolated environment and can safely test new release of packages. Now It comes the time when I have to deploy my app ...
w00d's user avatar
  • 5,546
77 votes
17 answers
17k views

Web application monitoring best practices [closed]

We are finishing up our web application and planning for deployment. Very important aspect of deployment to production is monitoring the health of the system. Having a small team of developers/support ...
45 votes
6 answers
82k views

From virtualenv, pip freeze > requirements.txt give TONES of garbage! How to trim it out?

I'm following this tutorial: http://devcenter.heroku.com/articles/django At some point I'm suposed to do: pip freeze > requirements.txt (Ofc. from virtualenv created instance of python) And I ...
przemo_li's user avatar
  • 4,003
43 votes
8 answers
15k views

How can I detect Heroku's environment?

I have a Django webapp, and I'd like to check if it's running on the Heroku stack (for conditional enabling of debugging, etc.) Is there any simple way to do this? An environment variable, perhaps? I ...
aviraldg's user avatar
  • 9,124
39 votes
10 answers
22k views

Deploying Google Analytics With Django

We're about to deploy a new Django website, and we want to use Google Analytics to keep track of traffic on the site. However, we don't want all of the hits on development instances to contribute to ...
Daniel Watkins's user avatar
37 votes
4 answers
19k views

Atlassian Bamboo with Django & Python - Possible?

At my company, we currently use Atlassian Bamboo for our continuous integration tool. We currently use Java for all of our projects, so it works great. However, we are considering using a Django + ...
TM.'s user avatar
  • 110k
37 votes
3 answers
19k views

Best Fabric scripts for Django [closed]

What are the best stock Fabric scripts for deploying a typical Django project? Fabric looks very good, but seems to require you to start from scratch and write your own deployment script. Coming from ...
Lee's user avatar
  • 2,619
36 votes
7 answers
50k views

Django: Not Found static/admin/css

I just deployed my first Django app on Heroku but I notice that it doesn't have any CSS like when I runserver on the local machine. I know there's something wrong with static files but I don't ...
user avatar
35 votes
3 answers
16k views

How to ignore directories when running Django collectstatic?

I am running a small test project with Django 1.3, Ubuntu 11.10, gunicorn and Nginx, everything in a virtualenv, and now I'm running collectstatic to get my static files into the directory that Nginx ...
Mentakatz's user avatar
  • 735
32 votes
7 answers
67k views

How do I create a superuser account in Django 1.9.6

I am reading a book ("Learning Django Web Development" by Sanjeev Jaiswal and Ratan Kumar) on Django, but the book is based on an earlier version of Django (prior to version 1.9). In order to ...
Zach W's user avatar
  • 331
32 votes
5 answers
15k views

Deploying Django on Google App Engine ==> ERROR: (gcloud.app.deploy) NOT_FOUND: Unable to retrieve P4SA(...)

I'm trying to deploy a Django application on Google App Engine. I followed the instructions given here. The only problem is that when I execute the command gcloud app deploy I than get the error: ...
Benjamin Carafa's user avatar
32 votes
1 answer
10k views

when to use fabric or ansible?

OVERVIEW I'd like to have reliable django deployments and I think I'm not following the best practices here. Till now I've been using fabric as a configuration management tool in order to deploy my ...
BPL's user avatar
  • 9,619
31 votes
3 answers
16k views

how to deploy django under a suburl behind nginx

I have a django application running on http://localhost:12345 . I'd like user to access it via url http://my.server.com/myapp . I use nginx to reverse proxy to it like the following: ... ... ...
John Wang's user avatar
  • 4,652
26 votes
1 answer
4k views

Backup strategy for django

I recently deployed a couple of web applications built using django (on webfaction). These would be some of the first projects of this scale that i am working on, so I wanted to know what an ...
zsquare's user avatar
  • 10.1k
25 votes
5 answers
14k views

How to gracefully restart django running fcgi behind nginx?

I'm running a django instance behind nginx connected using fcgi (by using the manage.py runfcgi command). Since the code is loaded into memory I can't reload new code without killing and restarting ...
evo's user avatar
  • 313
25 votes
2 answers
13k views

What is the disadvantage of using Django's fastcgi server

I'm using nginx + fastcgi( manage.py runfcgi ...) on production for some of my Django projects. A lot of people suggests to use nginx + gunicorn. What is advantage of using gunicorn instead of using ...
Murat Çorlu's user avatar
  • 8,465
23 votes
1 answer
21k views

Which webserver to use with Django? (updated for use in 2011)

I am asking this question because I am a beginner and I've read almost 90% of articles speaking about Django, but the problem is: Django was made and had problems for deploying, it is python, and ...
Abdelouahab's user avatar
  • 7,509
21 votes
6 answers
15k views

how do I deploy Django on AWS? [closed]

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
sa125's user avatar
  • 28.7k
20 votes
5 answers
19k views

Error: No module named staticfiles

I'm newbie with django, I'm trying to deploy my project on a production server but I'm getting this error: Error: No module named staticfiles When trying to start the server: python manage.py ...
Mc-'s user avatar
  • 4,028
19 votes
4 answers
11k views

Managing multiple settings.py files [duplicate]

Possible Duplicate: How to manage local vs production settings in Django? I have managed to deploy successfully a Django project on Apache's Web Server with mod_wsgi. I would like some ...
Pablo Santa Cruz's user avatar
18 votes
3 answers
18k views

gunicorn.socket: Failed with result 'service-start-limit-hit'

I was deploying a django app and it failed because for some reason the gunicorn.socket file was not created even though before adding nginx it worked perfectly fine so I searched the internet and ...
A. Atiyah's user avatar
  • 545
18 votes
3 answers
16k views

Deploying django in a production server

First of all please let me be clear that I am a windows user and very new to the web world. For the past months I have been learning both python and django, and it has been a great experience for me. ...
Benjamin Smith Max's user avatar
18 votes
1 answer
9k views

Deploying Django (fastcgi, apache mod_wsgi, uwsgi, gunicorn)

Can someone explain the difference between apache mod_wsgi in daemon mode and django fastcgi in threaded mode. They both use threads for concurrency I think. Supposing that I'm using nginx as front ...
Roman Dolgiy's user avatar
  • 1,521
17 votes
13 answers
61k views

No web processes running Django in heroku

I was trying to deploy my application in heroku, but when i finally try to run my application in heroku I het in the browser this: Application Error An error occurred in the application and your page ...
Cris Towi's user avatar
  • 1,191
16 votes
3 answers
3k views

Store static files on S3 but staticfiles.json manifest locally

I have a Django application running on Heroku. To store and serve my static files, I'm using django-storages with my S3 bucket, as well as the standard Django ManifestFilesMixin. I'm also using django-...
Danra's user avatar
  • 9,786
16 votes
2 answers
10k views

Django - Deployment for a newbie [closed]

I have finished my first Django/Python Project and now I need to put the things working in a real production webserver. I have read some papers over the Internet and I'm inclined to choose Ngix, ...
André's user avatar
  • 25.4k
15 votes
4 answers
6k views

Good tool for automatic setup and deployment of Django projects [closed]

2021 update Today I'm using Ansible for this and other devops tasks. Along the way I've experimented with Chef, Puppet, Saltstack and Docker images, but I've found that for me, as a solo developer ...
oivvio's user avatar
  • 3,106
15 votes
2 answers
5k views

setup.py exclude some python files from bdist

I have a django project with this kind of architecture : setup.py project/ __init__.py manage.py settings/ __init__.py base.py dev.py urls/ __init__.py base.py dev.py I wanted to deploy it in a ...
Simon Urli's user avatar
14 votes
3 answers
15k views

Heroku/python failed to detect set buildpack

I'm a Django newbie, I created an app and want to deploy it using Heroku. However, when I do git push heroku master (I follow Heroku's getting started), this is what I got: Counting objects: 36, done....
user avatar
14 votes
1 answer
17k views

Minimum server requirements for a django project [closed]

I want to deploy a django project with the following stack: Django with Nginx, Gunicorn, virtualenv, supervisor and PostgreSQL. I was thinking to use a Linode 1GB server which has: 1 GB RAM 1 CPU ...
user avatar
14 votes
2 answers
26k views

Django newbie deployment question - ImportError: Could not import settings 'settings'

The app runs fine using django internal server however when I use apache + mod_python I get the below error File "/usr/local/lib/python2.6/dist-packages/django/conf/__init__.py", line 75, in ...
Ankur Gupta's user avatar
  • 2,302
14 votes
1 answer
2k views

Docker, web app static files. Best practices?

How do people tend to handle static assets in web deployment on docker? For example, in a django app deployed in a container, do you have the app server serve up the static files from the container, ...
jvc26's user avatar
  • 6,493
13 votes
2 answers
12k views

AWS Elastic Beanstalk health check issue

My web application is Django and web server use Nginx, use Docker image and Elastic Beanstalk for deployment. Normally there was no problem, but as the load balancer expands EC2, my web server ...
Seung's user avatar
  • 133
12 votes
2 answers
2k views

Fabric + buildout as opposed to Fabric + pip + virtualenv

I've recently started playing around with Mezzanine, a django-based CMS. I recently just managed to configure Fabric to get it uploading to my host, webfaction.com, as its a bit more involved ...
foxwoods's user avatar
  • 500
12 votes
2 answers
17k views

Deploy Django with Gunicorn and APACHE

I have a Django project and I wanna delivery it using gunicorn (and apache proxing). I can't use Nginx, so that's no possible. I've set the Apache proxy and setup a runner script to gunicorn, but i ...
Fernando Ferreira's user avatar
12 votes
3 answers
1k views

Django and multi-stage servers

I am working with a client that demands multi-stage server setup: development server, stage server and production/live server. Stage should be as stable as it can be to test all those new features we ...
Hellnar's user avatar
  • 64k
12 votes
4 answers
2k views

Django Deployment: Handling data in database

Right now I am using git for Django deployment which seems satisfying to me. My only problem is still how to handle the data in the database properly. Eg. I need often to edit data coming from the ...
Bernhard Vallant's user avatar
11 votes
4 answers
5k views

Should I use git to deploy websites? [closed]

I have a site running on django, (but the question applies to anything, php, etc) Currently I'm using unison to deploy my changes, and I (kinda used to) love it because before that I was doing it ...
hasen's user avatar
  • 165k
11 votes
1 answer
2k views

Jython + Django not ready for production?

So recently I was playing around with Django on the Jython platform and wanted to see its performance in "production". The site I tested with was just a simple return HttpResponse("Time %.2f" % time....
AndiDog's user avatar
  • 69.8k
11 votes
4 answers
2k views

Deploying a (single node) Django Web application with virtually zero downtime on EC2

Question: What are good strategies for achieving 0 (or as close as possible to 0) downtime when using Django? Most of the answer I read say "use south" or "use fabric", but those are very vague ...
rburhum's user avatar
  • 1,651
10 votes
3 answers
6k views

Capistrano for Django

Does anyone know of a good Django equivalent of Capistrano/Webistrano?
Jake's user avatar
  • 12.9k
10 votes
2 answers
15k views

Which are the best web free hosts to practice Django deployment? [closed]

I'm a beginner with Django but I'd like to see my projects online without having to pay for the host as it is just to learn to deployment process.
Luis Martínez-Brocal's user avatar
10 votes
1 answer
8k views

Django / Apache / mod_wsgi: No module named importlib

After working with django's dev server for the past two months, the time finally came to move to apache + mod_wsgi. The problem is when I go to my site (let's call it junux), to the URL mapped to ...
scooz's user avatar
  • 828
10 votes
5 answers
5k views

Deploying Django to Heroku (Psycopg2 Error)

So I'm following the getting started guide from heroku with django. However when I run this command: heroku run python manage.py syncdb I get this error psycopg2.OperationalError: could not connect ...
Msencenb's user avatar
  • 5,104
10 votes
5 answers
12k views

Problems configuring deployment with Heroku/gunicorn/django

I'm trying to run my django application on heroku. Folder structure: app/ Procfile docs/ ... project/ manage.py wsgi.py <django apps> Procfile web: gunicorn --pythonpath=...
Avi Meir's user avatar
  • 1,000
10 votes
4 answers
2k views

Private settings in Django and Deployment

I am using Django and deploy my stack with Ansible. Finally, I am using Fabric to deploy my Django project pulling my code from GitHub. My question: What is the best practice to deal with private ...
Falk Schuetzenmeister's user avatar

1
2 3 4 5
28