diff --git a/playbooks/roles/confluent-community-broker/tasks/main.yml b/playbooks/roles/confluent-community-broker/tasks/main.yml index 992d04d..e1ddaad 100644 --- a/playbooks/roles/confluent-community-broker/tasks/main.yml +++ b/playbooks/roles/confluent-community-broker/tasks/main.yml @@ -52,6 +52,11 @@ src: zookeeper.properties dest: /etc/kafka/ +- name: Template schema-registry.properties + template: + src: schema-registry.properties + dest: /etc/schema-registry/ + - name: start kafka server systemd: name: confluent-kafka diff --git a/playbooks/roles/confluent-community-broker/templates/schema-registry.properties b/playbooks/roles/confluent-community-broker/templates/schema-registry.properties new file mode 100644 index 0000000..e06edb1 --- /dev/null +++ b/playbooks/roles/confluent-community-broker/templates/schema-registry.properties @@ -0,0 +1,43 @@ +# +# Copyright 2018 Confluent Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# The address the socket server listens on. +# FORMAT: +# listeners = listener_name://host_name:port +# EXAMPLE: +# listeners = PLAINTEXT://your.host.name:9092 +listeners=http://0.0.0.0:8081 + +# Zookeeper connection string for the Zookeeper cluster used by your Kafka cluster +# (see zookeeper docs for details). +# This is a comma separated host:port pairs, each corresponding to a zk +# server. e.g. "127.0.0.1:3000,127.0.0.1:3001,127.0.0.1:3002". +kafkastore.connection.url={% for node in groups['kafka-zk-nodes'] %}{{ hostvars[node]['ansible_'~hostvars[node].cluster_interface|default(hostvars[node].ansible_default_ipv4.alias)]['ipv4']['address'] }}:2181{% if not loop.last %},{% endif %}{% endfor %} + +# Alternatively, Schema Registry can now operate without Zookeeper, handling all coordination via +# Kafka brokers. Use this setting to specify the bootstrap servers for your Kafka cluster and it +# will be used both for selecting the master schema registry instance and for storing the data for +# registered schemas. +# (Note that you cannot mix the two modes; use this mode only on new deployments or by shutting down +# all instances, switching to the new configuration, and then starting the schema registry +# instances again.) +#kafkastore.bootstrap.servers=PLAINTEXT://localhost:9092 + +# The name of the topic to store schemas in +kafkastore.topic=_schemas + +# If true, API requests that fail will include extra debugging information, including stack traces +debug=false