]> git.donarmstrong.com Git - dsa-puppet.git/blob - modules/motd/templates/motd.erb
Remove pointer to http://lists.debian.org/debian-devel-announce/2003/debian-devel...
[dsa-puppet.git] / modules / motd / templates / motd.erb
1
2 This device is for authorized users only.  All traffic on this device
3 is monitored and will be used as evidence for prosecutions.
4
5 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
6
7 <%=
8 purp = ''
9 if nodeinfo.has_key?('nameinfo')
10   purp += nodeinfo['nameinfo'] + "\n\n"
11 end
12
13 purp += 'Welcome to ' + fqdn
14 if (nodeinfo['ldap'].at(0)) and (nodeinfo['ldap'][0].has_key?('purpose'))
15   if nodeinfo['ldap'][0]['purpose'].include?('buildd')
16     purp += ", the Debian "
17     if nodeinfo['ldap'][0].has_key?('architecture')
18       purp += nodeinfo['ldap'][0]['architecture'][0]
19     end
20     purp += " build daemon\n"
21   elsif nodeinfo['ldap'][0]['purpose'].include?('porterbox')
22     purp += ", the Debian "
23     if nodeinfo['ldap'][0].has_key?('architecture')
24       purp += nodeinfo['ldap'][0]['architecture'][0]
25     end
26     purp += " porterbox\n"
27   else
28     purp += ", used for the following services:\n"
29     nodeinfo['ldap'][0]['purpose'].sort.each do |l|
30       if l =~ /\[\[(\*|-)?(.*?)\]\]/
31         l = $2
32       end
33       if l =~ /\[\[(.*?)\|(.*?)\]\]/
34         l = $2
35       end
36       purp += "\t" + l + "\n"
37     end
38   end
39 else
40   purp += "\n"
41 end
42
43 if nodeinfo.has_key?('footer')
44   purp += "\n" + nodeinfo['footer'] + "\n"
45 end
46 purp
47 -%>
48
49 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
50