Merge "Use a shared session key among Horizon nodes"

This commit is contained in:
Jenkins 2014-12-18 19:36:19 +00:00 committed by Gerrit Code Review
commit 2d7d86b52a
2 changed files with 5 additions and 1 deletions

View File

@ -83,7 +83,7 @@ heat_cfn_service_password:
## Horizon Options
horizon_container_mysql_password:
horizon_secret_key:
## MaaS Options
# Set maas_auth_method to 'token' to use maas_auth_token/maas_api_url

View File

@ -94,8 +94,12 @@ LOCAL_PATH = os.path.dirname(os.path.abspath(__file__))
# behind a load-balancer). Either you have to make sure that a session gets all
# requests routed to the same dashboard instance or you set the same SECRET_KEY
# for all of them.
{% if horizon_secret_key %}
SECRET_KEY = "{{ horizon_secret_key }}"
{% else %}
from horizon.utils import secret_key
SECRET_KEY = secret_key.generate_or_read_from_file('/var/lib/horizon/.secret_key_store')
{% endif %}
# We recommend you use memcached for development; otherwise after every reload
# of the django development server, you will have to login again. To use