Skip to content

Commit

Permalink
(SIMP-10740) Update documentation and acc. tests
Browse files Browse the repository at this point in the history
Updated the README.md file to reflect contributed changes to the module,
and updated the acceptance tests (which I cannot run, so gosh I hope
they work) to use the newer convention for user/password specification.
  • Loading branch information
greatflyingsteve committed Aug 12, 2022
1 parent 32e2140 commit f0161d0
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 29 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ To configure a Compile Master (or other node) to function as both a server
and a client (of the primary server), setup hiera for the node:

```
rsync::server::global::port: 8873
rsync::server::listen_port: 8873
rsync::server::trusted_nets:
- <client_net>
- <client_net>
Expand Down
29 changes: 12 additions & 17 deletions spec/acceptance/suites/default/10_server_client_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@
}
rsync::server::section { 'test':
auth_users => ['test_user'],
user_pass => ['test_user:test_pass'],
auth_users => { 'test_user' => 'test_pass' },
comment => 'A test system',
hosts_allow => ['#{server1_ip}', '#{server2_ip}'],
path => '/srv/rsync/test',
Expand Down Expand Up @@ -80,24 +79,20 @@
}

let(:hieradata_server1) {{
'iptables::precise_match' => true,
'simp_options::pki' => false,
'simp_options::firewall' => true,
'rsync::server::stunnel' => false,
'rsync::server::trusted_nets' => [server2_ip],
'rsync::server::global::trusted_nets' => [server2_ip],
'rsync::server::global::address' => '0.0.0.0',
'iptables::precise_match' => true,
'simp_options::pki' => false,
'simp_options::firewall' => true,
'rsync::server::stunnel' => false,
'rsync::server::trusted_nets' => [server2_ip],
}}

let(:hieradata_server2) {{
'iptables::precise_match' => true,
'simp_options::pki' => false,
'simp_options::firewall' => true,
'rsync::server::stunnel' => false,
'rsync::server::global::port' => 8873,
'rsync::server::trusted_nets' => [server1_ip],
'rsync::server::global::trusted_nets' => [server1_ip],
'rsync::server::global::address' => '0.0.0.0',
'iptables::precise_match' => true,
'simp_options::pki' => false,
'simp_options::firewall' => true,
'rsync::server::stunnel' => false,
'rsync::server::listen_port' => 8873,
'rsync::server::trusted_nets' => [server1_ip],
}}

let(:server1_interface) { get_private_network_interface(server1) }
Expand Down
20 changes: 9 additions & 11 deletions spec/acceptance/suites/default/20_server_client_stunnel_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,10 @@
}
rsync::server::section { 'test':
auth_users => ['test_user'],
user_pass => ['test_user:test_pass'],
comment => 'A test system',
path => '/srv/rsync/test',
require => File['/srv/rsync/test/test_file_srvcli2_server1']
auth_users => { 'test_user' => 'test_pass' },
comment => 'A test system',
path => '/srv/rsync/test',
require => File['/srv/rsync/test/test_file_srvcli2_server1']
}
stunnel::connection { 'rsync':
Expand Down Expand Up @@ -88,11 +87,10 @@
}
rsync::server::section { 'test':
auth_users => ['test_user'],
user_pass => ['test_user:test_pass'],
comment => 'A test system',
path => '/srv/rsync/test',
require => File['/srv/rsync/test/test_file_srvcli2_server2']
auth_users => { 'test_user' => 'test_pass' },
comment => 'A test system',
path => '/srv/rsync/test',
require => File['/srv/rsync/test/test_file_srvcli2_server2']
}
stunnel::connection { 'rsync':
Expand Down Expand Up @@ -141,7 +139,7 @@
'simp_options::pki::source' => '/etc/pki/simp-testing/pki',
'simp_options::firewall' => true,
'rsync::server::stunnel' => true,
'rsync::server::global::port' => 8873,
'rsync::server::listen_port' => 8873,
'rsync::server::trusted_nets' => [server1_ip],
}}

Expand Down

0 comments on commit f0161d0

Please sign in to comment.