diff --git a/redis/manifests/init.pp b/redis/manifests/init.pp index f8b9be7..666a643 100644 --- a/redis/manifests/init.pp +++ b/redis/manifests/init.pp @@ -2,6 +2,9 @@ # # === Parameters # +# $bind: +# Address to bind to. Defaults to "127.0.0.1". +# # $datadir: # Directory for redis database dumps. # Defaults to "/srv/redis". @@ -12,7 +15,7 @@ # $appendonly: # Enable append only mode. Defaults to false. # -class redis($datadir="", $password="", $appendonly=false) { +class redis($bind="127.0.0.1", $datadir="", $password="", $appendonly=false) { package { "redis": ensure => installed, diff --git a/redis/templates/local.conf.erb b/redis/templates/local.conf.erb index 4f8e637..2b569cf 100644 --- a/redis/templates/local.conf.erb +++ b/redis/templates/local.conf.erb @@ -1,4 +1,4 @@ -bind 127.0.0.1 +bind <%= @bind %> dir /srv/redis appendonly <% if @appendonly == true %>yes<% else %>no<% end %> <% if @password -%>