Questions tagged [django]

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 interface, Django is the most popular of the Python web frameworks.

1012 questions
5
votes
2 answers

RHEL SELinux blocking Apache access to PostgreSQL

I'm running a Django app that uses PostgreSQL. The server is running RHEL 6.5 with SELinux. I'm having an issue where the Django app can't connect to the DB, and I think it's because SELinux is blocking it. Here's the error I'm seeing in…
Geoff
  • 171
  • 1
  • 8
5
votes
1 answer

Split the same virtualhost configuration across multiple files

I have multiple django applications on my server that run each within their own virtualhosts, bound to different ports. (I do this so as to isolate each WSGIProcessGroup). Now I would like to proxy each application to the port 80 for a simplicity…
Olivier H
  • 245
  • 1
  • 3
  • 9
5
votes
1 answer

Installing WSGI on EC2 micro instance

How do I install Apache with WSGI on my Amazon AMI EC2 micro instance? I tried sudo yum install httpd libapache2-mod-wsgi but I got this error message no package libapache2-mod-wsgi available Apache installed successfully. My goal is to run a…
Anthony
  • 201
  • 1
  • 6
  • 12
5
votes
1 answer

Web Server Routing Based On Location

I have a website that has users from both Hong Kong and Australia. Unfortunately, since the server is located in Australia, users from Hong Kong are going to suffer latency problems. Traffic has to go through US before travelling back to…
Eric
  • 153
  • 3
5
votes
2 answers

Safely install MDM Certificate in MDM Server

I am new to server technology.I know how to obtain an Apple iOS MDM Certificate and to use Apple iOS MDM features, we must: 1. Join Apple’s iOS Developer Enterprise Program. 2. Enroll 3. Register the MDM application. Apple will issue an MDM…
rainbow1202
  • 151
  • 4
5
votes
1 answer

MySQL transaction issue with Django and Amazon RDS

I'm having a problem with a MySQL 5.5 database instance running on Amazon RDS. Periodically (once every couple of days) a transaction will fail to complete and appears to leave the tables locked. Normally the transaction times out and everything…
5
votes
1 answer

Analyze uwsgi strace log to find out why it takes high CPU usage

I'm running a django site with nginx through uwsgi. The problem is uwsgi process take a lot of CPU time when traffic become heavy. The same configuration works fine on test server and siege/ab simulate heavy concurrent traffic. Here is one strace…
chenxee
  • 151
  • 1
  • 4
5
votes
3 answers

Measuring and visualing web application performance using apache logs?

I have a Django web application served up by mod_wsgi and Apache. I have apache logs of the web application in a production system, the logs include the time taken to serve the request in microseconds. I would like to look at this data (on a URL by…
Amandasaurus
  • 31,471
  • 65
  • 192
  • 253
5
votes
4 answers

Make mod_wsgi use python2.7.2 instead of python2.6?

i am running Ubuntu 10.04.1 LTS and it came pre-packed with python2.6 but i need to replace it with python2.7.2. (The reason is simple, 2.7 has a lot of features backported from 3 ) i had installed python2.7.2 using ./configure make make…
guron
  • 51
  • 1
  • 1
  • 2
5
votes
1 answer

nginx+ uwsgi gives 502 Bad Gateway

I used this guide to set it up and it was working to server my django app for a while, but after adding a new django module, without touching any of the nginx or uwsgi configs, now the server leads to 502 502 Bad Gateway error. The nginx error.log …
alfish
  • 3,127
  • 15
  • 47
  • 71
5
votes
2 answers

Django rewrites URL as IP address in browser - why?

I am using django, nginx and apache. When I access my site with a URL (e.g., http://www.foo.com/) what appears in my browser address is the IP address with admin appended (e.g., http://123.45.67.890/admin/). When I access the site by IP, it is…
Mitch
  • 291
  • 1
  • 4
  • 7
5
votes
2 answers

Has anyone used uwsgi nginx and django for a high-load environment?

I was wondering if anyone has used uwsgi with nginx to serve a high-load django site before. If so, did they have any problems?
kkubasik
  • 209
  • 3
  • 5
5
votes
2 answers

Broken URL rewriting on Django/modwsgi setup

I am trying to setup my Django app to run under Apache with modwsgi. I have defined the following virtualhost: ServerName www.domain.com ServerAlias domain.com WSGIScriptAlias / /home/domain/apache/django.wsgi …
user31196
4
votes
2 answers

nginx can't find /etc/letsencrypt/options-ssl-ngin.conf file

I'm trying to serve a python-django webapp using a linux box (running ubuntu 18.04) with nginx, gunincorn, letsencrypt and docker. After following a number of online tutorials I have been successful in serving the app via http through port 80 by…
Matt Ellis
  • 41
  • 1
  • 1
  • 2
4
votes
2 answers

How do I execute manage.py in Google App Engine?

I followed this tutorial: https://codeburst.io/beginners-guide-to-deploying-a-django-postgresql-project-on-google-cloud-s-flexible-app-engine-e3357b601b91 to get a Django app deployed to Google App Engine. It's there, it's working, but I need to run…
Pablo Fernandez
  • 7,438
  • 25
  • 71
  • 83