kolla-ansible/ansible/roles/kafka/defaults/main.yml
Radosław Piliszek 3e75a33ad4 Use the new image naming scheme
Change-Id: Ib4b15ed4feac82d8492b1c0f0238a752eac668e6
2022-05-23 06:37:25 +00:00

52 lines
2.1 KiB
YAML

---
kafka_services:
kafka:
container_name: kafka
group: kafka
enabled: true
image: "{{ kafka_image_full }}"
environment:
LOG_DIR: "{{ kafka_log_dir }}"
KAFKA_HEAP_OPTS: "{{ kafka_heap_opts }}"
volumes: "{{ kafka_default_volumes + kafka_extra_volumes }}"
dimensions: "{{ kafka_dimensions }}"
healthcheck: "{{ kafka_healthcheck }}"
####################
# Kafka
####################
kafka_cluster_name: "kolla_kafka"
kafka_log_dir: "/var/log/kolla/kafka"
kafka_heap_opts: "-Xmx1G -Xms1G"
kafka_zookeeper: "{% for host in groups['zookeeper'] %}{{ 'api' | kolla_address(host) | put_address_in_context('url') }}:{{ zookeeper_client_port }}{% if not loop.last %},{% endif %}{% endfor %}"
####################
# Docker
####################
kafka_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/kafka"
kafka_tag: "{{ openstack_tag }}"
kafka_image_full: "{{ kafka_image }}:{{ kafka_tag }}"
kafka_dimensions: "{{ default_container_dimensions }}"
kafka_enable_healthchecks: "{{ enable_container_healthchecks }}"
kafka_healthcheck_interval: "{{ default_container_healthcheck_interval }}"
kafka_healthcheck_retries: "{{ default_container_healthcheck_retries }}"
kafka_healthcheck_start_period: "{{ default_container_healthcheck_start_period }}"
kafka_healthcheck_test: ["CMD-SHELL", "healthcheck_listen java {{ kafka_port }}"]
kafka_healthcheck_timeout: "{{ default_container_healthcheck_timeout }}"
kafka_healthcheck:
interval: "{{ kafka_healthcheck_interval }}"
retries: "{{ kafka_healthcheck_retries }}"
start_period: "{{ kafka_healthcheck_start_period }}"
test: "{% if kafka_enable_healthchecks | bool %}{{ kafka_healthcheck_test }}{% else %}NONE{% endif %}"
timeout: "{{ kafka_healthcheck_timeout }}"
kafka_default_volumes:
- "{{ node_config_directory }}/kafka/:{{ container_config_directory }}/"
- "/etc/localtime:/etc/localtime:ro"
- "{{ '/etc/timezone:/etc/timezone:ro' if ansible_facts.os_family == 'Debian' else '' }}"
- "{{ kafka_datadir_volume }}:/var/lib/kafka/data"
- "kolla_logs:/var/log/kolla/"
kafka_extra_volumes: "{{ default_extra_volumes }}"