4bc410c6ca
Use case: exposing single external https frontend and load balancing services using FQDNs. Support different ports for internal and external endpoints. Introduced kolla_url filter to normalize urls like: - https://magnum.external:443/v1 - http://magnum.external:80/v1 Change-Id: I9fb03fe1cebce5c7198d523e015280c69f139cd0 Co-Authored-By: Jakub Darmach <jakub@stackhpc.com>
139 lines
5.3 KiB
YAML
139 lines
5.3 KiB
YAML
---
|
|
freezer_services:
|
|
freezer-api:
|
|
container_name: freezer_api
|
|
group: freezer-api
|
|
enabled: true
|
|
image: "{{ freezer_api_image_full }}"
|
|
volumes: "{{ freezer_api_default_volumes + freezer_api_extra_volumes }}"
|
|
dimensions: "{{ freezer_api_dimensions }}"
|
|
haproxy:
|
|
freezer_api:
|
|
enabled: "{{ enable_freezer }}"
|
|
mode: "http"
|
|
external: false
|
|
port: "{{ freezer_api_port }}"
|
|
listen_port: "{{ freezer_api_listen_port }}"
|
|
freezer_api_external:
|
|
enabled: "{{ enable_freezer }}"
|
|
mode: "http"
|
|
external: true
|
|
external_fqdn: "{{ freezer_external_fqdn }}"
|
|
port: "{{ freezer_api_public_port }}"
|
|
listen_port: "{{ freezer_api_listen_port }}"
|
|
freezer-scheduler:
|
|
container_name: freezer_scheduler
|
|
group: freezer-scheduler
|
|
enabled: true
|
|
image: "{{ freezer_scheduler_image_full }}"
|
|
volumes: "{{ freezer_scheduler_default_volumes + freezer_scheduler_extra_volumes }}"
|
|
dimensions: "{{ freezer_scheduler_dimensions }}"
|
|
|
|
####################
|
|
# Config Validate
|
|
####################
|
|
freezer_config_validation:
|
|
- generator: "/freezer/etc/config-generator.conf"
|
|
config: "/etc/freezer/freezer.conf"
|
|
|
|
####################
|
|
## Database
|
|
#####################
|
|
freezer_database_backend: "mariadb"
|
|
freezer_database_name: "freezer"
|
|
freezer_database_user: "{% if use_preconfigured_databases | bool and use_common_mariadb_user | bool %}{{ database_user }}{% else %}freezer{% endif %}"
|
|
freezer_database_address: "{{ database_address | put_address_in_context('url') }}:{{ database_port }}"
|
|
freezer_elasticsearch_replicas: "1"
|
|
freezer_es_protocol: "{{ internal_protocol }}"
|
|
freezer_es_address: "{{ opensearch_address }}"
|
|
freezer_es_port: "{{ opensearch_port }}"
|
|
|
|
####################
|
|
# Database sharding
|
|
####################
|
|
freezer_database_shard_root_user: "{% if enable_proxysql | bool %}root_shard_{{ freezer_database_shard_id }}{% else %}{{ database_user }}{% endif %}"
|
|
freezer_database_shard_id: "{{ mariadb_default_database_shard_id | int }}"
|
|
freezer_database_shard:
|
|
users:
|
|
- user: "{{ freezer_database_user }}"
|
|
password: "{{ freezer_database_password }}"
|
|
rules:
|
|
- schema: "{{ freezer_database_name }}"
|
|
shard_id: "{{ freezer_database_shard_id }}"
|
|
|
|
|
|
####################
|
|
# Docker
|
|
####################
|
|
freezer_tag: "{{ openstack_tag }}"
|
|
|
|
freezer_api_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/freezer-api"
|
|
freezer_api_tag: "{{ freezer_tag }}"
|
|
freezer_api_image_full: "{{ freezer_api_image }}:{{ freezer_api_tag }}"
|
|
|
|
freezer_scheduler_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/freezer-scheduler"
|
|
freezer_scheduler_tag: "{{ freezer_tag }}"
|
|
freezer_scheduler_image_full: "{{ freezer_scheduler_image }}:{{ freezer_scheduler_tag }}"
|
|
|
|
freezer_api_dimensions: "{{ default_container_dimensions }}"
|
|
freezer_scheduler_dimensions: "{{ default_container_dimensions }}"
|
|
|
|
freezer_api_default_volumes:
|
|
- "{{ node_config_directory }}/freezer-api/:{{ container_config_directory }}/:ro"
|
|
- "/etc/localtime:/etc/localtime:ro"
|
|
- "{{ '/etc/timezone:/etc/timezone:ro' if ansible_facts.os_family == 'Debian' else '' }}"
|
|
- "freezer:/var/lib/freezer/"
|
|
- "kolla_logs:/var/log/kolla/"
|
|
- "{{ kolla_dev_repos_directory ~ '/freezer-api/freezer_api:/var/lib/kolla/venv/lib/python' ~ distro_python_version ~ '/site-packages/freezer_api' if freezer_dev_mode | bool else '' }}"
|
|
freezer_scheduler_default_volumes:
|
|
- "{{ node_config_directory }}/freezer-scheduler/:{{ container_config_directory }}/:ro"
|
|
- "/etc/localtime:/etc/localtime:ro"
|
|
- "{{ '/etc/timezone:/etc/timezone:ro' if ansible_facts.os_family == 'Debian' else '' }}"
|
|
- "freezer:/var/lib/freezer/"
|
|
- "kolla_logs:/var/log/kolla/"
|
|
- "{{ kolla_dev_repos_directory ~ '/freezer/freezer:/var/lib/kolla/venv/lib/python' ~ distro_python_version ~ '/site-packages/freezer' if freezer_dev_mode | bool else '' }}"
|
|
|
|
freezer_extra_volumes: "{{ default_extra_volumes }}"
|
|
freezer_api_extra_volumes: "{{ freezer_extra_volumes }}"
|
|
freezer_scheduler_extra_volumes: "{{ freezer_extra_volumes }}"
|
|
|
|
####################
|
|
# OpenStack
|
|
####################
|
|
freezer_internal_endpoint: "{{ freezer_internal_fqdn | kolla_url(internal_protocol, freezer_api_port) }}"
|
|
freezer_public_endpoint: "{{ freezer_external_fqdn | kolla_url(public_protocol, freezer_api_public_port) }}"
|
|
|
|
freezer_logging_debug: "{{ openstack_logging_debug }}"
|
|
|
|
freezer_keystone_user: "freezer"
|
|
|
|
openstack_freezer_auth: "{{ openstack_auth }}"
|
|
|
|
freezer_api_workers: "{{ openstack_service_workers }}"
|
|
|
|
####################
|
|
# Kolla
|
|
####################
|
|
freezer_git_repository: "{{ kolla_dev_repos_git }}/{{ project_name }}"
|
|
freezer_api_git_repository: "{{ kolla_dev_repos_git }}/freezer-api"
|
|
freezer_dev_repos_pull: "{{ kolla_dev_repos_pull }}"
|
|
freezer_dev_mode: "{{ kolla_dev_mode }}"
|
|
freezer_source_version: "{{ kolla_source_version }}"
|
|
|
|
####################
|
|
# Keystone
|
|
####################
|
|
freezer_ks_services:
|
|
- name: "freezer"
|
|
type: "backup"
|
|
description: "Openstack Freezer Backup Service"
|
|
endpoints:
|
|
- {'interface': 'internal', 'url': '{{ freezer_internal_endpoint }}'}
|
|
- {'interface': 'public', 'url': '{{ freezer_public_endpoint }}'}
|
|
|
|
freezer_ks_users:
|
|
- project: "service"
|
|
user: "{{ freezer_keystone_user }}"
|
|
password: "{{ freezer_keystone_password }}"
|
|
role: "admin"
|