Skip to content

Commit

Permalink
Add cluster-port option to redis config file (#496)
Browse files Browse the repository at this point in the history
  • Loading branch information
zygisa authored Apr 30, 2024
1 parent 769a5bb commit 30f707d
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ This file is used to list changes made in each version of the redisio cookbook.

## Unreleased

- Add option to specify `cluster-port`

## 7.1.1 - *2024-04-21*

- Fix default `tls*` attribute names
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,7 @@ Available options and their defaults
'clusterenabled' => 'no',
'clusterconfigfile' => nil, # Defaults to redis instance name inside of template if cluster is enabled.
'clusternodetimeout' => 5000,
'clusterport' => nil,
'includes' => nil,
'aclfile' => nil, # Requires redis 6+
'breadcrumb' => true # Defaults to create breadcrumb lock-file.
Expand Down
1 change: 1 addition & 0 deletions attributes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@
'clusterenabled' => 'no',
'clusterconfigfile' => nil, # Defaults to redis instance name inside of template if cluster is enabled.
'clusternodetimeout' => 5000,
'clusterport' => nil,
'includes' => nil,
'aclfile' => nil,
'data_bag_name' => nil,
Expand Down
1 change: 1 addition & 0 deletions providers/configure.rb
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,7 @@
clusterenabled: current['clusterenabled'],
clusterconfigfile: current['clusterconfigfile'],
clusternodetimeout: current['clusternodetimeout'],
clusterport: current['clusterport'],
includes: current['includes'],
aclfile: current['aclfile'],
minreplicastowrite: current['minreplicastowrite'],
Expand Down
1 change: 1 addition & 0 deletions templates/default/redis.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -1033,6 +1033,7 @@ aof-rewrite-incremental-fsync <%= @aofrewriteincrementalfsync %>
cluster-enabled yes
cluster-config-file <%= @clusterconfigfile || "nodes-#{@name}.conf" %>
cluster-node-timeout <%= @clusternodetimeout %>
<%= "cluster-port #{@clusterport}" unless @clusterport.nil? %>
<%end%>

<% if @version[:major].to_i >= 6 %>
Expand Down

0 comments on commit 30f707d

Please sign in to comment.