Add horizon domain dropdown

Added ``horizon_keystone_domain_choices`` hash. It can be used to set the
available domains to choose from on the horizon login page. This feature
was introduced in pike release.

Change-Id: Ia7d2bc45e518848a04ce78e7833e1cf9a0ef21ce
This commit is contained in:
Pierre Hanselmann 2017-10-24 15:37:21 +02:00
parent 68d0a213b0
commit 27253723e3
3 changed files with 25 additions and 1 deletions

View File

@ -36,7 +36,8 @@ horizon_services:
- "/etc/localtime:/etc/localtime:ro" - "/etc/localtime:/etc/localtime:ro"
- "kolla_logs:/var/log/kolla/" - "kolla_logs:/var/log/kolla/"
- "/tmp:/tmp" - "/tmp:/tmp"
horizon_keystone_domain_choices:
Default: default
#################### ####################
# Database # Database

View File

@ -89,6 +89,22 @@ OPENSTACK_API_VERSIONS = {
# for login. # for login.
OPENSTACK_KEYSTONE_MULTIDOMAIN_SUPPORT = {{ horizon_keystone_multidomain | bool }} OPENSTACK_KEYSTONE_MULTIDOMAIN_SUPPORT = {{ horizon_keystone_multidomain | bool }}
# Set this to True if you want available domains displayed as a dropdown menu
# on the login screen. It is strongly advised NOT to enable this for public
# clouds, as advertising enabled domains to unauthenticated customers
# irresponsibly exposes private information. This should only be used for
# private clouds where the dashboard sits behind a corporate firewall.
OPENSTACK_KEYSTONE_DOMAIN_DROPDOWN = {{ 'True' if horizon_keystone_domain_choices|length > 1 else 'False' }}
# If OPENSTACK_KEYSTONE_DOMAIN_DROPDOWN is enabled, this option can be used to
# set the available domains to choose from. This is a list of pairs whose first
# value is the domain name and the second is the display name.
OPENSTACK_KEYSTONE_DOMAIN_CHOICES = (
{% for key, value in horizon_keystone_domain_choices.items() %}
('{{ key }}', '{{ value }}'),
{% endfor %}
)
# Overrides the default domain used when running on single-domain model # Overrides the default domain used when running on single-domain model
# with Keystone V3. All entities will be created in the default domain. # with Keystone V3. All entities will be created in the default domain.
# NOTE: This value must be the ID of the default domain, NOT the name. # NOTE: This value must be the ID of the default domain, NOT the name.

View File

@ -0,0 +1,7 @@
---
features:
- |
Added ``horizon_keystone_domain_choices`` hash. It can be used to set the
available domains to choose from on the horizon login page. This feature was introduced in
pike release.
https://docs.openstack.org/horizon/latest/configuration/settings.html#openstack-keystone-domain-choices