Mercurial > repos > other > Puppet
comparison modules/ssh/manifests/init.pp @ 21:7411baa55c01 puppet-3.6
Fix issues with newer Puppet trying to find files for abstract instances that aren't ever used
Also, fix variable usage issue (which must be in the original PuppetLabs example)
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Sun, 08 Mar 2015 23:56:35 +0000 |
parents | 956e484adc12 |
children | cd79745f0236 |
comparison
equal
deleted
inserted
replaced
20:393acb5f672d | 21:7411baa55c01 |
---|---|
14 # Distribution independent packages | 14 # Distribution independent packages |
15 # See also our Operating System specific sub-classes | 15 # See also our Operating System specific sub-classes |
16 @package { [ | 16 @package { [ |
17 "openssh-clients", | 17 "openssh-clients", |
18 "openssh-server", | 18 "openssh-server", |
19 "denyhosts" | 19 # "denyhosts" |
20 ]: | 20 ]: |
21 ensure => installed | 21 ensure => installed |
22 } | 22 } |
23 | 23 |
24 # Virtual Resources get defined before we include $operatingsystem specific | 24 # Virtual Resources get defined before we include $operatingsystem specific |
26 # | 26 # |
27 # Additionally, this way we can realize() in sub-classes as much as we want | 27 # Additionally, this way we can realize() in sub-classes as much as we want |
28 # to, and not concern ourselves with duplicate type definitions | 28 # to, and not concern ourselves with duplicate type definitions |
29 # | 29 # |
30 | 30 |
31 @file { "/etc/denyhosts.conf": | 31 # @file { "/etc/denyhosts.conf": |
32 notify => Service["denyhosts"], | 32 # notify => Service["denyhosts"], |
33 require => Package["denyhosts"], | 33 # require => Package["denyhosts"], |
34 source => [ | 34 # source => [ |
35 "puppet://$server/private/$domain/denyhosts/denyhosts.conf", | 35 # "puppet://$server/private/$domain/denyhosts/denyhosts.conf", |
36 "puppet://$server/files/denyhosts/denyhosts.conf", | 36 # "puppet://$server/files/denyhosts/denyhosts.conf", |
37 "puppet://$server/denyhosts/denyhosts.conf" | 37 # "puppet://$server/denyhosts/denyhosts.conf" |
38 ] | 38 # ] |
39 } | 39 # } |
40 | 40 |
41 @file { "/etc/ssh/ssh_config": | 41 @file { "/etc/ssh/ssh_config": |
42 owner => "root", | 42 owner => "root", |
43 mode => 644, | 43 mode => 644, |
44 require => Package["openssh-clients"], | 44 require => Package["openssh-clients"], |
45 source => [ | 45 source => [ |
46 # | 46 # |
47 # See rationale for an explanation on this list of sources | 47 # See rationale for an explanation on this list of sources |
48 # http://reductivelabs.com/trac/puppet/wiki/PuppetCommonModules/SSH | 48 # http://reductivelabs.com/trac/puppet/wiki/PuppetCommonModules/SSH |
49 # | 49 # |
50 "puppet://$server/private/$domain/ssh/$os/$osver/ssh_config.$hostname", | 50 "puppet://$server/private/$domain/ssh/$operatingsystem/$osver/ssh_config.$hostname", |
51 "puppet://$server/private/$domain/ssh/$os/$osver/ssh_config", | 51 "puppet://$server/private/$domain/ssh/$operatingsystem/$osver/ssh_config", |
52 "puppet://$server/private/$domain/ssh/$os/ssh_config.$hostname", | 52 "puppet://$server/private/$domain/ssh/$operatingsystem/ssh_config.$hostname", |
53 "puppet://$server/private/$domain/ssh/$os/ssh_config", | 53 "puppet://$server/private/$domain/ssh/$operatingsystem/ssh_config", |
54 "puppet://$server/private/$domain/ssh/ssh_config.$hostname", | 54 "puppet://$server/private/$domain/ssh/ssh_config.$hostname", |
55 "puppet://$server/private/$domain/ssh/ssh_config", | 55 "puppet://$server/private/$domain/ssh/ssh_config", |
56 "puppet://$server/files/ssh/$os/$osver/ssh_config.$hostname", | 56 "puppet://$server/files/ssh/$operatingsystem/$osver/ssh_config.$hostname", |
57 "puppet://$server/files/ssh/$os/$osver/ssh_config", | 57 "puppet://$server/files/ssh/$operatingsystem/$osver/ssh_config", |
58 "puppet://$server/files/ssh/$os/ssh_config.$hostname", | 58 "puppet://$server/files/ssh/$operatingsystem/ssh_config.$hostname", |
59 "puppet://$server/files/ssh/$os/ssh_config", | 59 "puppet://$server/files/ssh/$operatingsystem/ssh_config", |
60 "puppet://$server/files/ssh/ssh_config.$hostname", | 60 "puppet://$server/files/ssh/ssh_config.$hostname", |
61 "puppet://$server/files/ssh/ssh_config", | 61 "puppet://$server/files/ssh/ssh_config", |
62 "puppet://$server/ssh/$os/$osver/ssh_config", | 62 "puppet://$server/ssh/$operatingsystem/$osver/ssh_config", |
63 "puppet://$server/ssh/$os/ssh_config", | 63 "puppet://$server/ssh/$operatingsystem/ssh_config", |
64 "puppet://$server/ssh/ssh_config" | 64 "puppet://$server/ssh/ssh_config" |
65 ], | 65 ], |
66 sourceselect => first | 66 sourceselect => first |
67 } | 67 } |
68 | 68 |
74 source => [ | 74 source => [ |
75 # | 75 # |
76 # See rationale for an explanation on this list of sources | 76 # See rationale for an explanation on this list of sources |
77 # http://reductivelabs.com/trac/puppet/wiki/PuppetCommonModules/SSH | 77 # http://reductivelabs.com/trac/puppet/wiki/PuppetCommonModules/SSH |
78 # | 78 # |
79 "puppet://$server/private/$domain/ssh/$os/$osver/sshd_config.$hostname", | 79 "puppet://$server/private/$domain/ssh/$operatingsystem/$osver/sshd_config.$hostname", |
80 "puppet://$server/private/$domain/ssh/$os/$osver/sshd_config", | 80 "puppet://$server/private/$domain/ssh/$operatingsystem/$osver/sshd_config", |
81 "puppet://$server/private/$domain/ssh/$os/sshd_config.$hostname", | 81 "puppet://$server/private/$domain/ssh/$operatingsystem/sshd_config.$hostname", |
82 "puppet://$server/private/$domain/ssh/$os/sshd_config", | 82 "puppet://$server/private/$domain/ssh/$operatingsystem/sshd_config", |
83 "puppet://$server/private/$domain/ssh/sshd_config.$hostname", | 83 "puppet://$server/private/$domain/ssh/sshd_config.$hostname", |
84 "puppet://$server/private/$domain/ssh/sshd_config", | 84 "puppet://$server/private/$domain/ssh/sshd_config", |
85 "puppet://$server/files/ssh/$os/$osver/sshd_config.$hostname", | 85 "puppet://$server/files/ssh/$operatingsystem/$osver/sshd_config.$hostname", |
86 "puppet://$server/files/ssh/$os/$osver/sshd_config", | 86 "puppet://$server/files/ssh/$operatingsystem/$osver/sshd_config", |
87 "puppet://$server/files/ssh/$os/sshd_config.$hostname", | 87 "puppet://$server/files/ssh/$operatingsystem/sshd_config.$hostname", |
88 "puppet://$server/files/ssh/$os/sshd_config", | 88 "puppet://$server/files/ssh/$operatingsystem/sshd_config", |
89 "puppet://$server/files/ssh/sshd_config.$hostname", | 89 "puppet://$server/files/ssh/sshd_config.$hostname", |
90 "puppet://$server/files/ssh/sshd_config", | 90 "puppet://$server/files/ssh/sshd_config", |
91 "puppet://$server/ssh/$os/$osver/sshd_config", | 91 "puppet://$server/ssh/$operatingsystem/$osver/sshd_config", |
92 "puppet://$server/ssh/$os/sshd_config", | 92 "puppet://$server/ssh/$operatingsystem/sshd_config", |
93 "puppet://$server/ssh/sshd_config" | 93 "puppet://$server/ssh/sshd_config" |
94 ], | 94 ], |
95 sourceselect => first | 95 sourceselect => first |
96 } | 96 } |
97 | 97 |