aboutsummaryrefslogtreecommitdiff
path: root/bigtop-deploy/puppet
diff options
context:
space:
mode:
Diffstat (limited to 'bigtop-deploy/puppet')
-rw-r--r--bigtop-deploy/puppet/modules/kafka/manifests/init.pp3
-rw-r--r--bigtop-deploy/puppet/modules/kafka/templates/server.properties4
2 files changed, 6 insertions, 1 deletions
diff --git a/bigtop-deploy/puppet/modules/kafka/manifests/init.pp b/bigtop-deploy/puppet/modules/kafka/manifests/init.pp
index 482b51b8..736cfe08 100644
--- a/bigtop-deploy/puppet/modules/kafka/manifests/init.pp
+++ b/bigtop-deploy/puppet/modules/kafka/manifests/init.pp
@@ -22,9 +22,10 @@ class kafka {
}
class server(
+ $bind_addr = undef,
$broker_id = "0",
$port = "9092",
- $zookeeper_connection_string = "localhost:2181"
+ $zookeeper_connection_string = "localhost:2181",
) {
package { 'kafka':
diff --git a/bigtop-deploy/puppet/modules/kafka/templates/server.properties b/bigtop-deploy/puppet/modules/kafka/templates/server.properties
index a30e9709..dbda3119 100644
--- a/bigtop-deploy/puppet/modules/kafka/templates/server.properties
+++ b/bigtop-deploy/puppet/modules/kafka/templates/server.properties
@@ -25,7 +25,11 @@ broker.id=<%= @broker_id %>
port=<%= @port %>
# Hostname the broker will bind to. If not set, the server will bind to all interfaces
+<% if @bind_addr.nil? -%>
#host.name=localhost
+<% else -%>
+host.name=<%= @bind_addr %>
+<% end -%>
# Hostname the broker will advertise to producers and consumers. If not set, it uses the
# value for "host.name" if configured. Otherwise, it will use the value returned from