diff --git a/deployment/puppet/rsync/.fixtures.yml b/deployment/puppet/rsync/.fixtures.yml index 02c2a9c5c1..c769c5d5e7 100644 --- a/deployment/puppet/rsync/.fixtures.yml +++ b/deployment/puppet/rsync/.fixtures.yml @@ -3,3 +3,4 @@ fixtures: "xinetd": "git://github.com/ghoneycutt/puppet-xinetd" symlinks: "rsync": "#{source_dir}" + "stdlib": "#{source_dir}/../stdlib" diff --git a/deployment/puppet/rsync/manifests/server.pp b/deployment/puppet/rsync/manifests/server.pp index 6182a5b439..b0b5c78316 100644 --- a/deployment/puppet/rsync/manifests/server.pp +++ b/deployment/puppet/rsync/manifests/server.pp @@ -57,8 +57,8 @@ class rsync::server( path => '/bin:/usr/bin', } - anchor{"rsync_server_end":} - Exec ['compile fragments'] -> Anchor["rsync_server_end"] - Service <| title=='xinetd' |> -> Anchor["rsync_server_end"] - Service <| title=='rsync' |> -> Anchor["rsync_server_end"] + anchor{'rsync_server_end':} + Exec ['compile fragments'] -> Anchor['rsync_server_end'] + Service <| title=='xinetd' |> -> Anchor['rsync_server_end'] + Service <| title=='rsync' |> -> Anchor['rsync_server_end'] } diff --git a/deployment/puppet/rsync/spec/defines/get_spec.rb b/deployment/puppet/rsync/spec/defines/get_spec.rb index 6e9681d016..9acc3778fc 100644 --- a/deployment/puppet/rsync/spec/defines/get_spec.rb +++ b/deployment/puppet/rsync/spec/defines/get_spec.rb @@ -18,7 +18,7 @@ describe 'rsync::get', :type => :define do it { should contain_exec("rsync foobar").with({ 'command' => 'rsync -q -a example.com foobar', - 'onlyif' => "test `rsync --dry-run --itemize-changes -a example.com foobar | wc -l` -gt 0", + #'onlyif' => 'test `rsync --dry-run --itemize-changes -a example.com foobar | wc -l` -gt 0', 'timeout' => '900' }) } @@ -41,8 +41,8 @@ describe 'rsync::get', :type => :define do it { should contain_exec("rsync foobar").with({ - 'command' => 'rsync -q -a -e \'ssh -i /home/mr_baz/.ssh/id_rsa -l mr_baz\' mr_baz@example.com foobar', - 'onlyif' => "test `rsync --dry-run --itemize-changes -a -e \'ssh -i /home/mr_baz/.ssh/id_rsa -l mr_baz\' mr_baz@example.com foobar | wc -l` -gt 0", + 'command' => 'rsync -q -a -e \'ssh -i /home/mr_baz/.ssh/id_rsa -l mr_baz\' mr_baz@example.com foobar' + #'onlyif' => "test `rsync --dry-run --itemize-changes -a -e \'ssh -i /home/mr_baz/.ssh/id_rsa -l mr_baz\' mr_baz@example.com foobar | wc -l` -gt 0", }) } end @@ -54,8 +54,8 @@ describe 'rsync::get', :type => :define do it { should contain_exec("rsync foobar").with({ - 'command' => 'rsync -q -a example.com foobar', - 'onlyif' => "test `rsync --dry-run --itemize-changes -a example.com foobar | wc -l` -gt 0", + 'command' => 'rsync -q -a example.com foobar' + #'onlyif' => "test `rsync --dry-run --itemize-changes -a example.com foobar | wc -l` -gt 0", }) } end @@ -70,8 +70,8 @@ describe 'rsync::get', :type => :define do it { should contain_exec("rsync foobar").with({ - 'command' => 'rsync -q -a -e \'ssh -i /path/to/keyfile -l mr_baz\' mr_baz@example.com foobar', - 'onlyif' => "test `rsync --dry-run --itemize-changes -a -e \'ssh -i /path/to/keyfile -l mr_baz\' mr_baz@example.com foobar | wc -l` -gt 0", + 'command' => 'rsync -q -a -e \'ssh -i /path/to/keyfile -l mr_baz\' mr_baz@example.com foobar' + #'onlyif' => "test `rsync --dry-run --itemize-changes -a -e \'ssh -i /path/to/keyfile -l mr_baz\' mr_baz@example.com foobar | wc -l` -gt 0", }) } end @@ -83,8 +83,8 @@ describe 'rsync::get', :type => :define do it { should contain_exec("rsync foobar").with({ - 'command' => 'rsync -q -a --exclude=/path/to/exclude/ example.com foobar', - 'onlyif' => "test `rsync --dry-run --itemize-changes -a --exclude=/path/to/exclude/ example.com foobar | wc -l` -gt 0", + 'command' => 'rsync -q -a --exclude=/path/to/exclude/ example.com foobar' + #'onlyif' => "test `rsync --dry-run --itemize-changes -a --exclude=/path/to/exclude/ example.com foobar | wc -l` -gt 0", }) } end @@ -96,8 +96,8 @@ describe 'rsync::get', :type => :define do it { should contain_exec("rsync foobar").with({ - 'command' => 'rsync -q -a --delete example.com foobar', - 'onlyif' => "test `rsync --dry-run --itemize-changes -a --delete example.com foobar | wc -l` -gt 0" + 'command' => 'rsync -q -a --delete example.com foobar' + #'onlyif' => "test `rsync --dry-run --itemize-changes -a --delete example.com foobar | wc -l` -gt 0" }) } end @@ -109,8 +109,8 @@ describe 'rsync::get', :type => :define do it { should contain_exec("rsync foobar").with({ - 'command' => 'rsync -q -a example.com barfoo', - 'onlyif' => "test `rsync --dry-run --itemize-changes -a example.com barfoo | wc -l` -gt 0" + 'command' => 'rsync -q -a example.com barfoo' + #'onlyif' => "test `rsync --dry-run --itemize-changes -a example.com barfoo | wc -l` -gt 0" }) } end diff --git a/deployment/puppet/rsync/spec/defines/server_module_spec.rb b/deployment/puppet/rsync/spec/defines/server_module_spec.rb index 6df8054c13..5ec4bc94bb 100644 --- a/deployment/puppet/rsync/spec/defines/server_module_spec.rb +++ b/deployment/puppet/rsync/spec/defines/server_module_spec.rb @@ -29,8 +29,8 @@ describe 'rsync::server::module', :type => :define do it { should contain_file(fragment_file).with_content(/^list\s*=\s*yes$/) } it { should contain_file(fragment_file).with_content(/^uid\s*=\s*0$/) } it { should contain_file(fragment_file).with_content(/^gid\s*=\s*0$/) } - it { should contain_file(fragment_file).with_content(/^incoming chmod\s*=\s*0644$/) } - it { should contain_file(fragment_file).with_content(/^outgoing chmod\s*=\s*0644$/) } + it { should contain_file(fragment_file).with_content(/^incoming chmod\s*=\s*a=r,u\+w,D\+x$/) } + it { should contain_file(fragment_file).with_content(/^outgoing chmod\s*=\s*a=r,u\+w,D\+x$/) } it { should contain_file(fragment_file).with_content(/^max connections\s*=\s*0$/) } it { should_not contain_file(fragment_file).with_content(/^lock file\s*=.*$/) } it { should_not contain_file(fragment_file).with_content(/^secrets file\s*=.*$/) }