Skip to content

Instantly share code, notes, and snippets.

@datakop
Last active October 10, 2019 18:23
Show Gist options
  • Save datakop/4689964 to your computer and use it in GitHub Desktop.
Save datakop/4689964 to your computer and use it in GitHub Desktop.
.htaccess config file for wsgi-script for django projects based on virtualenv enviroment
AddHandler wsgi-script .wsgi
RewriteEngine on
RewriteBase /
RewriteRule ^(media/.*)$ - [L]
RewriteRule ^(static/.*)$ - [L]
RewriteCond %{REQUEST_URI} !(django.wsgi)
RewriteRule ^(.*)$ django.wsgi/$1 [L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment