2e933dceb5
A system-scoped token implies the user has authorization to act on the deployment system. These tokens are useful for interacting with resources that affect the deployment as a whole, or exposes resources that may otherwise violate project or domain isolation. Since Queens, the keystone-manage bootstrap command assigns the admin role to the admin user with system scope, as well as in the admin project. This patch transitions the Keystone admin user from authenticating using project scoped tokens to system scoped tokens. This is a necessary step towards being able to enable the updated oslo policies in services that allow finer grained access to system-level resources and APIs. An etherpad with discussion about the transition to the new oslo service policies is: https://etherpad.opendev.org/p/enabling-system-scope-in-kolla-ansible Change-Id: Ib631e2211682862296cce9ea179f2661c90fa585 Signed-off-by: Niklas Hagman <ubuntu@post.blinkiz.com>
77 lines
2.4 KiB
Django/Jinja
77 lines
2.4 KiB
Django/Jinja
[DEFAULT]
|
|
debug = {{ freezer_logging_debug }}
|
|
|
|
log_dir = /var/log/kolla/freezer
|
|
|
|
{% if service_name == 'freezer-api' %}
|
|
bind_host = {{ api_interface_address }}
|
|
bind_port = {{ freezer_api_port }}
|
|
{% endif %}
|
|
|
|
{% if service_name == 'freezer-scheduler' %}
|
|
client_id = {{ inventory_hostname }}
|
|
jobs_dir = /etc/freezer/scheduler/conf.d
|
|
|
|
os_username = {{ openstack_auth.username }}
|
|
os_password = {{ openstack_auth.password }}
|
|
os_auth_url = {{ openstack_auth.auth_url }}/v3
|
|
os_project_name = {{ keystone_admin_project }}
|
|
os_project_domain_name = {{ openstack_auth.domain_name }}
|
|
# TODO: transition to system scoped token when freezer supports that
|
|
# configuration option
|
|
os_user_domain_name = {{ openstack_auth.user_domain_name }}
|
|
{% endif %}
|
|
|
|
{% if service_name == 'freezer-api' %}
|
|
[keystone_authtoken]
|
|
www_authenticate_uri = {{ keystone_internal_url }}
|
|
auth_url = {{ keystone_admin_url }}
|
|
auth_type = password
|
|
project_domain_id = {{ default_project_domain_id }}
|
|
user_domain_id = {{ default_user_domain_id }}
|
|
project_name = service
|
|
username = {{ freezer_keystone_user }}
|
|
password = {{ freezer_keystone_password }}
|
|
cafile = {{ openstack_cacert }}
|
|
region_name = {{ openstack_region_name }}
|
|
|
|
memcache_security_strategy = ENCRYPT
|
|
memcache_secret_key = {{ memcache_secret_key }}
|
|
memcached_servers = {% for host in groups['memcached'] %}{{ 'api' | kolla_address(host) | put_address_in_context('memcache') }}:{{ memcached_port }}{% if not loop.last %},{% endif %}{% endfor %}
|
|
|
|
{% if freezer_policy_file is defined %}
|
|
[oslo_policy]
|
|
policy_file = {{ freezer_policy_file }}
|
|
{% endif %}
|
|
|
|
[oslo_middleware]
|
|
enable_proxy_headers_parsing = True
|
|
|
|
[paste_deploy]
|
|
config_file = /etc/freezer/freezer-paste.ini
|
|
|
|
|
|
{% if freezer_database_backend == 'mariadb' %}
|
|
[storage]
|
|
backend = sqlachemy
|
|
driver = sqlalchemy
|
|
|
|
[database]
|
|
connection = mysql+pymysql://{{ freezer_database_user }}:{{ freezer_database_password }}@{{ freezer_database_address }}/{{ freezer_database_name }}
|
|
connection_recycle_time = {{ database_connection_recycle_time }}
|
|
max_pool_size = {{ database_max_pool_size }}
|
|
max_retries = -1
|
|
{% endif %}
|
|
|
|
{% if freezer_database_backend == 'elasticsearch' %}
|
|
[storage]
|
|
backend = elasticsearch
|
|
driver = elasticsearch
|
|
|
|
[elasticsearch]
|
|
hosts = {{ freezer_es_protocol }}://{{ freezer_es_address | put_address_in_context('url') }}:{{ freezer_es_port }}
|
|
number_of_replicas = {{ freezer_elasticsearch_replicas }}
|
|
index = freezer
|
|
{% endif %}
|
|
{% endif %}
|