Sunday, August 28, 2016

Re: AWS ElasticBeanstalk update without modifying Django wsgi.conf

I just posted an answer on Stackoverflow.

On Friday, 26 August 2016 22:14:44 UTC+8, Ronaldo Bahia wrote:

I have a django app deployed in AWS EB using autoscaling. This app uses Django Rest with Token Authentication. In order for this to work, I have to add the following lines in etc/httpd/conf.d/wsgi.conf file:

RewriteEngine on  RewriteCond %{HTTP:Authorization} ^(.*)  RewriteRule .* - [e=HTTP_AUTHORIZATION:%1]    WSGIPassAuthorization On

The problem is: when AWS do an autoscale or ElasticBeanstalk environment upgrade, the wsgi.conf file is updated and the custom settings are deleted.

How can I avoid that?

Thanks in advance

Stackoverflow thread:

You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To post to this group, send email to
Visit this group at
To view this discussion on the web visit
For more options, visit

No comments:

Post a Comment