Sha256: 4f341ecb111d9227768a1383fc27ec78303d68ccdcbdde3fb7e94438c5186c5f
Contents?: true
Size: 463 Bytes
Versions: 8
Compression:
Stored size: 463 Bytes
Contents
namespace :redis do desc "Installs the Redis server" task :install do on roles :db do execute :sudo, "apt-get -y update" execute :sudo, "apt-get -y install redis-server" end end %w[start stop restart].each do |command| desc "#{command} redis" task command do on roles(:db), in: :sequence, wait: 5 do command_string = "redis-server #{command}" execute :service, command_string end end end end
Version data entries
8 entries across 8 versions & 1 rubygems