-
Notifications
You must be signed in to change notification settings - Fork 183
Commit
Process the configuration file `redis.conf` template twice if some of the templates values are deferred. Currently with deferred values the resulting deferred template cannot be processed since it contains complex datatypes from stdlib in particular. This is a redis specific solution that may arrive genraly one day in puppetlabs/puppetlabs-stdlib#1425
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'spec_helper_acceptance' | ||
|
||
describe 'redis with deferred password' do | ||
include_examples 'an idempotent resource' do | ||
let(:manifest) do | ||
<<-PUPPET | ||
class { 'redis': | ||
manage_repo => true, | ||
redis_apt_repo => true, | ||
port => 10001, | ||
masterauth => Deferred('inline_epp',['<%= $pass %>\n',{'pass' => 'topsecret'}]), | ||
} | ||
PUPPET | ||
end | ||
end | ||
|
||
describe command('redis-cli -p 10001 -a topsecret ping') do | ||
its(:stdout) { is_expected.to match %r{PONG} } | ||
Check failure on line 20 in spec/acceptance/suites/default/redis_deferred_spec.rb GitHub Actions / Puppet / Puppet 8 - CentOS 9
Check failure on line 20 in spec/acceptance/suites/default/redis_deferred_spec.rb GitHub Actions / Puppet / Puppet 7 - CentOS 9
Check failure on line 20 in spec/acceptance/suites/default/redis_deferred_spec.rb GitHub Actions / Puppet / Puppet 8 - AlmaLinux 9
Check failure on line 20 in spec/acceptance/suites/default/redis_deferred_spec.rb GitHub Actions / Puppet / Puppet 7 - AlmaLinux 9
Check failure on line 20 in spec/acceptance/suites/default/redis_deferred_spec.rb GitHub Actions / Puppet / Puppet 8 - Rocky 9
Check failure on line 20 in spec/acceptance/suites/default/redis_deferred_spec.rb GitHub Actions / Puppet / Puppet 7 - Rocky 9
|
||
end | ||
end |