- 206.12.19.0/24
searchpaths: [debprivate-ubc.debian.org]
mirror-debian: http://mirror-ubc.debian.org/debian/
- nameservers: [206.12.19.214, 2607:f8f0:610:4000:224:81ff:fea7:e952, 206.12.19.20, 2607:f8f0:610:4000:218:feff:fe76:2ed0, 206.12.19.21, 2607:f8f0:610:4000:21c:c4ff:fee5:e890]
+ nameservers: ['206.12.19.214', '2607:f8f0:610:4000:224:81ff:fea7:e952', '206.12.19.20', '2607:f8f0:610:4000:218:feff:fe76:2ed0', '206.12.19.21', '2607:f8f0:610:4000:21c:c4ff:fee5:e890']
ugent:
netrange:
- 157.193.0.0/16
<%=
out = []
-restricted_purposes = {'kvm host', 'central syslog server', 'puppet master', 'jumphost'}
+restricted_purposes = ['kvm host', 'central syslog server', 'puppet master', 'jumphost']
restrict_ssh = %w{lebrun geo1 geo2 geo3 beethoven tchaikovsky schroeder draghi}
if (scope.lookupvar('site::nodeinfo')['ldap'].has_key?('purpose')) then
##
## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
-## USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
+## USE then git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
##
<%=
ignore = []
case fqdn
-when "bellini.debian.org": ignore << "mcelog"
-when "cilea.debian.org": ignore << "/freeswitch.*/"
-when /draghi.debian.org/: ignore << %w{userdir-ldap userdir-ldap-cgi libheimdal-kadm5-perl django-ldapdb}
-when /orff.debian.org/: ignore << %w{libnet-dns-sec-perl libnet-dns-zone-parser-perl}
-when /(zandonai|zelenka).debian.org/: ignore << %w{samhain zabbix-agent rrdcollect}
-when /zappa.debian.org/: ignore << %w{samhain}
-when /(mayer|corelli).debian.org/: ignore << "linux-base"
-when /(alkman|caballero|merulo|mundy).debian.org/: ignore << "samhain"
-when "franck.debian.org": ignore << %w{python-apt}
-when /(abel|arnold|alain|alwyn|antheil|arne).debian.org/: ignore << %w{flash-kernel linux-firmware-image}
-when /harris.debian.org/: ignore << %w{flash-kernel kernel linux-firmware-image}
-when /(hasse|hebden|henze|hildegard|howells|hummel|hoiby).debian.org/: ignore << %w{flash-kernel kernel linux-firmware-image schroot schroot-common}
-when /(parry|partch|piston).debian.org/: ignore << "yaboot"
-
-when "grieg.debian.org": ignore << %w{dpkg}
-when "blavet.debian.org": ignore << %w{dpkg-dev libdpkg-perl dpkg}
-when "handel.debian.org": ignore << %w{puppet-dashboard}
-when "reger.debian.org": ignore << %w{librt-extension-commandbymail-perl}
-when /(pasquini|tristano).debian.org/: ignore << %w{ganeti-instance-image}
+when "bellini.debian.org" then ignore << "mcelog"
+when "cilea.debian.org" then ignore << "/freeswitch.*/"
+when /draghi.debian.org/ then ignore << %w{userdir-ldap userdir-ldap-cgi libheimdal-kadm5-perl django-ldapdb}
+when /orff.debian.org/ then ignore << %w{libnet-dns-sec-perl libnet-dns-zone-parser-perl}
+when /(zandonai|zelenka).debian.org/ then ignore << %w{samhain zabbix-agent rrdcollect}
+when /zappa.debian.org/ then ignore << %w{samhain}
+when /(mayer|corelli).debian.org/ then ignore << "linux-base"
+when /(alkman|caballero|merulo|mundy).debian.org/ then ignore << "samhain"
+when "franck.debian.org" then ignore << %w{python-apt}
+when /(abel|arnold|alain|alwyn|antheil|arne).debian.org/ then ignore << %w{flash-kernel linux-firmware-image}
+when /harris.debian.org/ then ignore << %w{flash-kernel kernel linux-firmware-image}
+when /(hasse|hebden|henze|hildegard|howells|hummel|hoiby).debian.org/ then ignore << %w{flash-kernel kernel linux-firmware-image}
+when /(parry|partch|piston).debian.org/ then ignore << "yaboot"
+when "grieg.debian.org" then ignore << %w{dpkg}
+when "blavet.debian.org" then ignore << %w{dpkg-dev libdpkg-perl dpkg}
+when "handel.debian.org" then ignore << %w{puppet-dashboard}
+when "reger.debian.org" then ignore << %w{librt-extension-commandbymail-perl}
+when /(pasquini|tristano).debian.org/ then ignore << %w{ganeti-instance-image}
end
case fqdn
-when /geo[123].debian.org/: ignore << %w{geoip-database}
+when /geo[123].debian.org/ then ignore << %w{geoip-database}
end
if fqdn == "arne.debian.org"
- ignore << %w{/linux-headers-.*/}
+ ignore << %w{/linux-headers-.*/}
end
-#case fqdn
-#when /(draghi|orff|ravel|klecker|geo[123]).debian.org/: ignore << %w{libdns69 libdns66 libdns64 bind9 libbind9-60 liblwres60 bind9-host libisccfg62 libisccfg60 libisc62 libisc60 dnsutils bind9utils libisccc60}
-#end
ignore.flatten.join("\n")
%>
---
:hierarchy:
- - %{hoster}
- - clusters/%{cluster}
- - common
+ - '%{hoster}'
+ - 'clusters/%{cluster}'
+ - 'common'
:backends:
- yaml
:yaml:
required = args.shift.split()
optional = args.shift.split()
- allhosts = function_ldapinfo('*', *(required+optional) )
+ allhosts = function_ldapinfo(['*', *(required+optional) ])
res = {}
allhosts.each_pair do |hostname, host|
# If a returned value doesn't have all the attributes we're searching for, skip
next unless localinfo[node]['entropy_key']
addresses = allnodeinfo[node]['ipHostNumber']
- thishoster = function_whohosts(addresses, "/etc/puppet/modules/debian-org/misc/hoster.yaml")
+ thishoster = function_whohosts([addresses, "/etc/puppet/modules/debian-org/misc/hoster.yaml"])
name = thishoster['name']
provider << node
require '/var/lib/puppet/lib/puppet/parser/functions/ldapinfo.rb'
require '/var/lib/puppet/lib/puppet/parser/functions/whohosts.rb'
- nodeinfo = function_yamlinfo(host, yamlfile)
- nodeinfo['ldap'] = function_ldapinfo(host, '*')
+ nodeinfo = function_yamlinfo([host, yamlfile])
+ nodeinfo['ldap'] = function_ldapinfo([host, '*'])
unless nodeinfo['ldap']['ipHostNumber']
raise Puppet::ParseError, "Host #{host} does not have ipHostNumber values in ldap"
end
- nodeinfo['hoster'] = function_whohosts(nodeinfo['ldap']['ipHostNumber'], "/etc/puppet/modules/debian-org/misc/hoster.yaml")
+ nodeinfo['hoster'] = function_whohosts([nodeinfo['ldap']['ipHostNumber'], "/etc/puppet/modules/debian-org/misc/hoster.yaml"])
nodeinfo['buildd'] = (nodeinfo['ldap']['purpose'].respond_to?('include?') && nodeinfo['ldap']['purpose'].include?('buildd'))
if lookupvar('::mta') == 'exim4'
end
end
- ns = function_hiera('nameservers')
- allow_dns_q = function_hiera('allow_dns_query')
+ ns = function_hiera(['nameservers'])
+ allow_dns_q = function_hiera(['allow_dns_query'])
if ns.empty?
# no nameservers known for this hoster
nodeinfo['misc']['resolver-recursive'] = true
parser = Puppet::Parser::Parser.new(environment)
parser.watch_file(yamlfile)
- def read_yaml(yaml, host)
+ read_yaml = lambda { |yaml, host|
results = {}
['nameinfo', 'footer'].each do |detail|
end
end
return(results)
- end
+ }
require 'yaml'
$KCODE = 'utf-8'
Dir.entries('/var/lib/puppet/yaml/node/').each do |fname|
next unless fname =~ /(.*)\.yaml$/
host_name = $1
- ret[host_name] = read_yaml(yaml, host_name)
+ ret[host_name] = read_yaml.call(yaml, host_name)
end
else
- ret = read_yaml(yaml, host)
+ ret = read_yaml.call(yaml, host)
end
return(ret)
class puppetmaster {
- include site::params
-
package { 'puppetmaster':
- ensure => $site::params::puppetversion,
+ ensure => installed,
}
file { '/etc/puppet/hiera.yaml':
source => 'puppet:///modules/puppetmaster/hiera.yaml'
+++ /dev/null
-class site::params {
- $puppetversion = $::hostname ? {
- handel => '2.7.18-3~bpo60+1',
- default => '2.6.2-5+squeeze5',
- }
-}
### USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
###
-deb <%= scope.lookupvar('url') %> <%= scope.lookupvar('suite') %> <%= scope.lookupvar('components').to_a.join(' ') %>
+deb <%= scope.lookupvar('url') %> <%= scope.lookupvar('suite') %> <%= [scope.lookupvar('components')].flatten.join(' ') %>