Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add custom zookeeper_id for each host based in inventory #99

Merged
merged 1 commit into from
Oct 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions roles/amq_streams_zookeeper/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ zknode3
|`amq_streams_zookeeper_admin_enable_server` | Enable zookeeper administration server | `false` |
|`amq_streams_zookeeper_instance_count_enabled` | Count zookeeper instances | `true` |
|`amq_streams_zookeeper_instance_count` | | `0` |
|`amq_streams_zookeeper_zookeeper_id` | Zookeeper variable to identify the zookeeper in a cluster | |
|`amq_streams_zookeeper_java_opts` | Default values to apply to `KAFKA_OPTS` env variable | |
|`amq_streams_zookeeper_java_heap_opts` | Default values to apply to `KAFKA_HEAP_OPTS` env variable | `-Xmx512M -Xms512M` |
|`amq_streams_zookeeper_java_performance_opts` | Default values to apply to `KAFKA_JVM_PERFORMANCE_OPTS` env variable | |
Expand Down
2 changes: 1 addition & 1 deletion roles/amq_streams_zookeeper/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

- name: "Configure 'myid' file based on the position in the zookeepers group"
copy:
content: "{{ amq_streams_zookeeper_inventory_group.index(inventory_hostname) + 1 }}"
content: "{{ amq_streams_zookeeper_zookeeper_id | default(amq_streams_zookeeper_inventory_group.index(inventory_hostname) + 1) }}"
dest: "{{ amq_streams_zookeeper_data_dir }}/myid"
owner: "{{ amq_streams_zookeeper_user | default(omit) }}"
group: "{{ amq_streams_zookeeper_group | default(omit) }}"
Expand Down