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

Fix systemd paths for sentinel service #332

Merged
merged 2 commits into from
Apr 27, 2017
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
10 changes: 8 additions & 2 deletions recipes/sentinel.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,16 @@
base_piddir redis['base_piddir']
end

template '/usr/lib/systemd/system/redis-sentinel@.service' do
bin_path = if node['redisio']['install_dir']
::File.join(node['redisio']['install_dir'], 'bin')
else
node['redisio']['bin_path']
end

template '/lib/systemd/system/redis-sentinel@.service' do
source 'redis-sentinel@.service'
variables(
bin_path: node['redisio']['bin_path'],
bin_path: bin_path,
limit_nofile: redis['default_settings']['maxclients'] + 32
)
only_if { node['redisio']['job_control'] == 'systemd' }
Expand Down
2 changes: 1 addition & 1 deletion recipes/sentinel_enable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
end

execute 'reload-systemd-sentinel' do
command '/usr/bin/systemctl daemon-reload'
command 'systemctl daemon-reload'
only_if { node['redisio']['job_control'] == 'systemd' }
action :nothing
end
Expand Down