]> git.donarmstrong.com Git - dsa-puppet.git/blob - modules/ferm/templates/me.conf.erb
restrict schroeder ssh
[dsa-puppet.git] / modules / ferm / templates / me.conf.erb
1 ##
2 ## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
3 ## USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
4 ##
5
6 <%=
7   out=''
8   case hostname
9   when 'schroeder' then 
10     out = '@def $CARNET = ( 193.198.184.8/29 161.53.160.133 161.53.160.90 161.53.11.222 161.53.12.134 161.53.12.142 161.53.12.143 )'
11   end
12   out
13 %>
14
15 @def $SSH_SOURCES = (<%=
16
17 sshallowed = []
18
19 case hostname
20   when 'logtest01', 'geo1', 'geo2', 'geo3', 'bartok', 'beethoven', 'tchaikovsky' then sshallowed << [ '$DSA_IPS', '$HOST_NAGIOS_V4', '$HOST_DB_V4' ]
21   when 'schroeder' then sshallowed << [ '$DSA_IPS', '$HOST_NAGIOS_V4', '$HOST_DB_V4', '$CARNET' ]
22 end
23
24 case hostname
25   when 'bartok', 'beethoven' then sshallowed << '$HOST_DEBIAN_V4'
26 end
27
28 if sshallowed.length == 0
29   sshallowed = [ '0.0.0.0/0' ]
30 end
31
32 sshallowed.join(' ')
33 %>);
34
35 @def $SSH_V6_SOURCES = (<%=
36
37 sshallowed = []
38
39 case hostname
40   when 'logtest01', 'geo1', 'geo2', 'geo3', 'bartok', 'beethoven', 'schroeder', 'tchaikovsky' then sshallowed << [ '$DSA_V6_IPS', '$HOST_NAGIOS_V6', '$HOST_DB_V6' ]
41 end
42
43 case hostname
44   when 'bartok', 'beethoven' then sshallowed << '$HOST_DEBIAN_V6'
45 end
46
47 if sshallowed.length == 0
48   sshallowed = [ '::' ]
49 end
50
51 sshallowed.join(' ')
52 %>);
53
54 def $SMTP_SOURCES =(<%=
55
56 smtpallowed = []
57
58 if not nodeinfo['smarthost'].empty?
59   smtpallowed = [ '$HOST_MAILRELAY_V4', '$HOST_NAGIOS_V4' ]
60 end
61
62 if smtpallowed.length == 0
63   smtpallowed = [ '0.0.0.0/0' ]
64 end
65
66 smtpallowed.join(' ')
67 %>);
68
69 def $SMTP_V6_SOURCES =(<%=
70
71 smtpallowed = []
72
73 if not nodeinfo['smarthost'].empty?
74   smtpallowed = [ '$HOST_MAILRELAY_V6', '$HOST_NAGIOS_V6' ]
75 end
76
77 if smtpallowed.length == 0
78   smtpallowed = [ '::' ]
79 end
80
81 smtpallowed.join(' ')
82 %>);