Django, "the web framework for perfectionists with deadlines", is a Python-based framework for creating web applications. With a powerful object-based database mapper, a clean syntax for mapping URLs to views, a simple template language and a convenient automatically generated administration ...

learn more… | top users | synonyms

-9
votes
0answers
26 views

Nginx domains redirect to main [on hold]

The main working domain is example.com that serves a django application How would direct example.org, example.net, example.info to the working example.com The best approach that does not break down ...
1
vote
1answer
27 views

Ubuntu upgrade broke django mod_wsgi

I'm banging my head here and can't seem to find the answers anywhere. My server is running Ubuntu 14.04. I run several django sites using apache and mod_wsgi Today after an update, the sites will ...
1
vote
0answers
15 views

gunicorn not fully reloading after an HUP signal

I'm trying to get a working supervisor/gunicorn/django setup on vagrant. I am using python-watchdog to try and restart gunicorn when code changes happen. I am using the following supervisor ...
0
votes
0answers
46 views

Nginx & uWSGI: ImportError: No module named site

I'm receiving an error: ImportError: No module named site according to my uWSGI log. test_proj.ini: [uwsgi] chdir = /home/%n/app module = %n.wsgi home = /home/%n/app/venv master = true processes = ...
0
votes
1answer
42 views

configure nginx for serving django development static files

I am using Nginx to serve static files on django development server. However I can't make it work. The server runs fine but nginx is not able to find static files. This is my settings in nginx.conf: ...
0
votes
0answers
8 views

“Error importing middleware” on osqa

I installed osqa with postgresql as backend on ubuntu 14.0.4 using the tutorial below http://wiki.osqa.net/display/docs/ubuntu+12.04,+django+1.3,+mod_wsgi,+virtual_env,+postgresql which asks to ...
0
votes
0answers
28 views

Scale automatically by monitoring the load in app server

I have a regular setup with 4 droplets in DigitalOcean. One for Haproxy as load balancer, two for app servers, run same Django application and one for database. It's quite easy to add another app ...
1
vote
0answers
41 views

Trouble with Uwsgi settings

I have a uwsgi ini that looks like this: [uwsgi] socket = :8001 processes = 4 master = true wsgi-file = /project/dev/myproject/conf/deployment/wsgi/dev/myproject-site.wsgi harakiri = 30 daemonize = ...
0
votes
0answers
48 views

Apache not serving my python app

So here's my apache config: LoadModule wsgi_module /usr/lib/apache2/modules/mod_wsgi.so <VirtualHost *:80> ServerAdmin marijus.merkevicius@gmail.com ServerName 31.220.49.197 ...
0
votes
1answer
46 views

Docker: Django and Postgresql: What is better two separate containers or one?

I plan to deploy my django app in docker. This application uses Postgresql as backend, so I've faced a question, what is better deployment scheme: two docker containers - one for app and one for DB, ...
0
votes
0answers
17 views

scrapping not working Django+Apache+wsgi Production server

I developed a django app which uses beautifulsoup4 and urllib2 to parse the data from webpages.It was working well on my development server but when I put the same on Apache+wsgi server, the scrapping ...
0
votes
0answers
27 views

Tuning and configuring Django Application with Apache & Mod Wsgi

We are running Django Application using Apache+mod-wsgi. application is taking too long to load. even a single list view page load takes 6-15 seconds. Can you suggest improvements? Provided are my ...
0
votes
1answer
52 views

aws ec2 and Django ALLOWED_HOSTS

I have put in place my website using Django, on aws EC2, using Elastic Beanstalk. I have set the ALLOWED_HOSTS to ['www.mydomain.fr', '.mydomain.fr'], as recommanded on the Django website. But I ...
0
votes
0answers
17 views

Elasticsearch service automatilly terminates

When i try to start the elasticsearch service, it starts normally (no error messages). But terminates immidiately. There is no log in the /var/log/elasticsearch directory.I'm using elasticsearch ...
1
vote
1answer
29 views

API and main page as two separated processes

SITUATION I created an REST API for my mobile application and now I want to create a website. API so far is very very simple, just for a couple requests like 'get list of contents', 'update some ...
0
votes
1answer
99 views

Strange behavior with supervisor, gunicorn and Django

I have a really strange problem with supervisor and gunicorn. I read supervisor documentation, all the relevant blog posts, stackexchange questions but none of them solve my strange problem, and I ...
0
votes
1answer
23 views

Django and phpBB server [duplicate]

Is it possible to integrate Django web site and PHP forum by some apache directive in httpd.conf file? For example: <VirtualHost *:80> ServerName myserver DocumentRoot home/myserver/www/ ...
1
vote
1answer
125 views

Django: CONN_MAX_AGE persists connections, but doesn't reuse them with PostgreSQL

I've got a django setup are using Django 1.6.7 and Postgres 9.3 on Ubuntu 14.04 LTS. At any given time, the site gets about ~250 simultaneous connections to the PostgreSQL database, which is a Quad ...
0
votes
1answer
33 views

AWS EC2 Ubuntu - Logging Python print statements

What is the easiest way to see "print" statements made when a Python file is executed on my AWS EC2 Ubuntu server? I have tried the aws cli, but this does not work for me.
0
votes
0answers
42 views

Why use daemon mode of mod-wsgi with apache mpm-worker

I am trying to tune my server which hosts a django app using mod-wsgi on an apache web server. I have been reading some resources on using mod-wsgi with apache2 and beyond a certain point things are ...
0
votes
0answers
42 views

Diagnosing Random Internal Server Errors That Leave Clean Logs

I have a Django site running on an Amazon EC2 Ubuntu instance, and I've been getting random Internal Server Errors that I can't get to the bottom of. I'm using Apache 2.4.10 to serve pages. I also ...
0
votes
1answer
397 views

Django, mod_wsgi, pyvenv-3.4 - configuration

I'm trying to deploy my first, simple django website. I have an VPS with Ubuntu 14.07 Server, Apache 2.4.7 with mod_wsgi. So, i added this vhost: <VirtualHost *:80> ServerName api.XXX.net ...
0
votes
1answer
39 views

Serving a static page using nginx - getting 404

I'm trying to set up a static page on my website using nginx. The folder has a index.html file along with some static files. The directory structure looks something like this olx --static --fonts ...
-1
votes
1answer
149 views

How to reinstall python2.7 on CentOS 6 in order to install mod_wsgi [closed]

I've installed Python2.7 from source on a CentOS 6 VPS, and I'd like to get a Django site up and running. Unfortunately, everything I've Googled so far says that I'll need to install mod_wsgi, which ...
0
votes
0answers
72 views

Cache-Control only working for media files and not static files served in Django

I'm trying to use Cache-Control for my static files. Following is my code for the .htaccess file # 1 YEAR <FilesMatch "\.(ico|svg|woff|eot|ttf)$"> Header set Cache-Control "max-age=31536000, ...
0
votes
0answers
28 views

Webserver needed for django WSGI API?

My app is just a REST API written in django. There is no static content or html pages served. In setting up our production environment, we are planning on using amazon ELB (load balancer) to balance ...
0
votes
0answers
106 views

Running Django Test Server - Segmentation fault (core dumped)

I am running the Django test server from a virtualenv - necessary to use supervisord to run Celery as a background process. When I try: "python manage.py runserver" from the cygwin shell I get the ...
0
votes
0answers
51 views

Django-mailer emails stuck in queue

I have been using the Django-Mailer app for a few years on my large, corporate Django driven web application. I use it to send a custom email to each of our 800 clients. Generally, it has worked well. ...
0
votes
1answer
110 views

nginx wont start after reboot Ubuntu 14.04

I'm getting this error: nginx: [emerg] duplicate upstream "app_server" in /etc/nginx/sites-enabled/django.save:1 this is my config file: upstream app_server { server 127.0.0.1:9000 ...
1
vote
1answer
99 views

Nginx and Django use www-prefixed domain

Trying to understand how to force www. in my domain and redirect anything like ww.example.com or test.example.com -> www.example.com Everything works fine when I go to www.example.com or example.com, ...
-1
votes
1answer
95 views

503 errors on Apache+Mod_wsgi+Django

I'm new to Python and trying to setup Django on my VPS that is running CentoOS 6.5. My Apache version is 2.2.15. Python is running on version 2.7. I created a virtualenv under ...
0
votes
0answers
21 views

Nginx blocks http response with long string

I encountered a issue with my live web service today. The backend setup is Nginx + Django webservice. In the webservice, I have code to return a HttpResponse with a long JSON string (> 1400 char). ...
1
vote
1answer
705 views

Graphite SQLite3 DatabaseError: attempt to write a readonly database

Running graphite under apache httpd, with slqite database, I have the correct folder permissions [root@liaan55 httpd]# ls -ltr /var/lib | grep graphite drwxr-xr-x. 2 apache apache 4096 ...
0
votes
1answer
215 views

How to serve static files for multiple Django projects via nginx to same domain

I am trying to setup my nginx conf so that I can serve the relevant files for my multiple Django projects. Ultimately I want each app to be available at www.example.com/app1, www.example.com/app2 ...
0
votes
2answers
98 views

Repeated EC2 Apache 500 error

I'm running a Django website off Apache and MySQL. I'm using a t1.micro instance. After every couple of days, my server starts giving a 500 error. I solve this problem by restarting the Apache2 and ...
0
votes
2answers
78 views

Why do I see apache's 404 and not Django custom 404?

On my local django runserver I created a custom templates/404.html, and this works no problem. However in production with apache this custom 404.html is no longer shown (even with DEBUG=False). I ...
3
votes
1answer
345 views

psycopg2 not found by django after installing in virtualenv

I want to use postgresql with django so did the following: sudo apt-get install libpq-dev python-dev sudo apt-get update workon myenv sudo pip install psycopg2 And after configuring my settings.py ...
2
votes
0answers
85 views

Not seeing Django logs on Heroku

I'm not seeing log entries (at a level of INFO) made by Django in my Heroku logs. This is my configuration: LOGGING = { 'version': 1, 'disable_existing_loggers': False, 'filters': { ...
0
votes
1answer
77 views

Scalable django app, should message queue be located on load balancer or app server?

I've just architected my first scalable backend for a django app, however I put the message queue service (RabbitMQ) on the load balancer machine. I was able to siege some of my API routes with up to ...
0
votes
1answer
666 views

Internal Server Error when running Gunicorn as a service

I'm trying to deploy my Django app for the first time on a Digital Ocean VPS. I've used their Django droplet which setup things like this except I'm not using a virtual environment. After adding my ...
0
votes
1answer
121 views

Apache web server, virtual hosts, sub domains and multiple web frameworks

I have a website www.mysite.com This is the main site and I will be using the Django web framework for the site I also want to have other subdomains such as: https://mail.mysite.com (handled ...
0
votes
1answer
150 views

Jenkins fighting with Django over permissions

I've got a Jenkins/Nginx server running. But I get the error from Django: attempt to write a readonly database So I solved this problem by changing the ownership of the project folder to the ...
0
votes
2answers
147 views

Nginx + Apache mod_wsgi, troubles understanding how to configure servers

I've been trying for too long to set up a development environment on my Ubuntu 12.04. My intention is to set up everything as I'd have to do later in a production environment, so I followed this ...
1
vote
0answers
62 views

Django wsgi and mod_pagespeed not working

I installed mod_pagespeed on my server and it's working as far as the page header is concerned: X-Mod-Pagespeed:1.7.30.5-3847 The problem is that it's doing nothing else. No whitespace or comment ...
-1
votes
1answer
1k views

Error code: ssl_error_rx_record_too_long on nginx ubuntu server

I have a site which was perfectly running with apache on some old ubuntu server and also has https for it. But now for some reasons i need to move to different(new ubuntu server with high ...
0
votes
0answers
217 views

Apache error log with django application showing “strange” error

My django code was previously in /var/www and all worked just fine. Yesterday, I decided to move the code in /root and keep the static files in /var/www for security purposes. I am using Django 1.6.5 ...
0
votes
0answers
38 views

Djapian in Ubuntu trusty

I'm trying to migrate my Django server to a new server running Ubuntu trusty (the last one ran lucid). I've got almost everything working except for Djapian: when I run python manage.py index ...
0
votes
0answers
109 views

Server configuration in production for Django applications

I want to deploy my Django project to production as follows: example.com # redirect to www www.example.com # for dynamic files static.example.com # for static files media.example.com ...
0
votes
0answers
135 views

Apache single sign on redirecting to success login page, Django application

All I have a Django web application with relative paths url. For instance, I have www.example.com/inventory/get_item/?item_id=5 In the apache configuration I am using oracle single sign on to ...
0
votes
1answer
283 views

Howto rewrite URLs with two nginx as reverse proxies to gunicorn/Django

I have a Django application, deployed with gunicorn on port 8000, on a VM with a backend nginx, port 80, on the same VM. The nginx config is: location / { proxy_http_version 1.1; ...