Drupal setup on a Django server.

Posted July 10, 2014 3k views

Hi I have a Ubuntu 14.04 LAMP server. I am currently using Django to serve the content of my site. I would like to add Drupal to my site and use it for a blog. Django is serveing the root right now ( but I want to add a folder (/blog) to install Drupal to so if you go to ( it’ll load the Drupal project. If i use Django to serve the Drupal project I will have to create a view and add it to my urls for every page as well as configure each page to use CSRF. That will make things very complicated. So my question is can I setup Apache to serve a folder on a site without Django if the rest of my site is using Django.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

If you are just going to keep the Drupal site in a sub-directory, you can set this up using Alias directive. It would look something like:

Alias /blog /path/to/drupal/
<Directory /path/to/drupal>
   # You Drupal configuration options here

WSGIScriptAlias / /path/to/django/project/app.wsgi
<Directory /path/to/django/project>
   # You Django configuration options here

Of course, you’ll need to install the rest of the LAMP stack (PHP, MySql) for Drupal.

by Justin Ellingwood
One of the most common steps to take when setting up a new server is to install a LAMP stack. LAMP stands for Linux, Apache, MySQL, and PHP. These individual components, when used together, allow us to host dynamic web content like websites and web apps on our server. We will demonstrate how to install these pieces and configure a basic setup for Ubuntu 14.04 in this guide.