Skip to content
Snippets Groups Projects
  • Mark Goddard's avatar
    ade5bfa3
    Use ansible_facts to reference facts · ade5bfa3
    Mark Goddard authored
    By default, Ansible injects a variable for every fact, prefixed with
    ansible_. This can result in a large number of variables for each host,
    which at scale can incur a performance penalty. Ansible provides a
    configuration option [0] that can be set to False to prevent this
    injection of facts. In this case, facts should be referenced via
    ansible_facts.<fact>.
    
    This change updates all references to Ansible facts within Kolla Ansible
    from using individual fact variables to using the items in the
    ansible_facts dictionary. This allows users to disable fact variable
    injection in their Ansible configuration, which may provide some
    performance improvement.
    
    This change disables fact variable injection in the ansible
    configuration used in CI, to catch any attempts to use the injected
    variables.
    
    [0] https://docs.ansible.com/ansible/latest/reference_appendices/config.html#inject-facts-as-vars
    
    Change-Id: I7e9d5c9b8b9164d4aee3abb4e37c8f28d98ff5d1
    Partially-Implements: blueprint performance-improvements
    ade5bfa3
    History
    Use ansible_facts to reference facts
    Mark Goddard authored
    By default, Ansible injects a variable for every fact, prefixed with
    ansible_. This can result in a large number of variables for each host,
    which at scale can incur a performance penalty. Ansible provides a
    configuration option [0] that can be set to False to prevent this
    injection of facts. In this case, facts should be referenced via
    ansible_facts.<fact>.
    
    This change updates all references to Ansible facts within Kolla Ansible
    from using individual fact variables to using the items in the
    ansible_facts dictionary. This allows users to disable fact variable
    injection in their Ansible configuration, which may provide some
    performance improvement.
    
    This change disables fact variable injection in the ansible
    configuration used in CI, to catch any attempts to use the injected
    variables.
    
    [0] https://docs.ansible.com/ansible/latest/reference_appendices/config.html#inject-facts-as-vars
    
    Change-Id: I7e9d5c9b8b9164d4aee3abb4e37c8f28d98ff5d1
    Partially-Implements: blueprint performance-improvements
main.yml 10.31 KiB
---
project_name: "heat"

heat_services:
  heat-api:
    container_name: heat_api
    group: heat-api
    enabled: true
    image: "{{ heat_api_image_full }}"
    volumes: "{{ heat_api_default_volumes + heat_api_extra_volumes }}"
    dimensions: "{{ heat_api_dimensions }}"
    healthcheck: "{{ heat_api_healthcheck }}"
    haproxy:
      heat_api:
        enabled: "{{ enable_heat }}"
        mode: "http"
        external: false
        port: "{{ heat_api_port }}"
        listen_port: "{{ heat_api_listen_port }}"
        tls_backend: "{{ heat_enable_tls_backend }}"
      heat_api_external:
        enabled: "{{ enable_heat }}"
        mode: "http"
        external: true
        port: "{{ heat_api_port }}"
        listen_port: "{{ heat_api_listen_port }}"
        tls_backend: "{{ heat_enable_tls_backend }}"
  heat-api-cfn:
    container_name: heat_api_cfn
    group: heat-api-cfn
    enabled: true
    image: "{{ heat_api_cfn_image_full }}"
    volumes: "{{ heat_api_cfn_default_volumes + heat_api_cfn_extra_volumes }}"
    dimensions: "{{ heat_api_cfn_dimensions }}"
    healthcheck: "{{ heat_api_cfn_healthcheck }}"
    haproxy:
      heat_api_cfn:
        enabled: "{{ enable_heat }}"
        mode: "http"
        external: false
        port: "{{ heat_api_cfn_port }}"
        listen_port: "{{ heat_api_cfn_listen_port }}"
        tls_backend: "{{ heat_enable_tls_backend }}"
      heat_api_cfn_external:
        enabled: "{{ enable_heat }}"
        mode: "http"
        external: true
        port: "{{ heat_api_cfn_port }}"
        listen_port: "{{ heat_api_cfn_listen_port }}"
        tls_backend: "{{ heat_enable_tls_backend }}"
  heat-engine:
    container_name: heat_engine
    group: heat-engine
    enabled: true
    image: "{{ heat_engine_image_full }}"
    volumes: "{{ heat_engine_default_volumes + heat_engine_extra_volumes }}"
    dimensions: "{{ heat_engine_dimensions }}"
    healthcheck: "{{ heat_engine_healthcheck }}"

####################
# Database
####################
heat_database_name: "heat"
heat_database_user: "{% if use_preconfigured_databases | bool and use_common_mariadb_user | bool %}{{ database_user }}{% else %}heat{% endif %}"
heat_database_address: "{{ database_address | put_address_in_context('url') }}:{{ database_port }}"


####################
# Docker
####################