Skip to content

Commit

Permalink
Merge pull request #5 from TelekomCloud/debian-support
Browse files Browse the repository at this point in the history
Debian support
  • Loading branch information
Johan Lyheden committed Feb 24, 2015
2 parents 9527990 + 9145c4f commit dffa4c4
Showing 1 changed file with 43 additions and 81 deletions.
124 changes: 43 additions & 81 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -8,95 +8,57 @@
#
class tinyproxy::params {
$autoupgrade = false
$package = 'tinyproxy'
$service = 'tinyproxy'
$hasstatus = false
$hasrestart = true
$listen = undef
$bind = undef
$bindsame = undef
$connection_timeout = 600
$allow = []
$errorfiles = {}
$defaulterrorfile= '/usr/share/tinyproxy/default.html'
$stathost = undef
$statfile = '/usr/share/tinyproxy/stats.html'
$logfile = '/var/log/tinyproxy/tinyproxy.log'
$syslog = undef
$log_level = 'Info'
$pidfile = '/var/run/tinyproxy/tinyproxy.pid'
$xtinyproxy = undef
$maxclients = 100
$minspareservers = 5
$maxspareservers = 20
$startservers = 10
$maxrequestsperchild = 0
$viaproxyname = 'tinyproxy'
$disableviaheader = undef
$filter = undef
$filterurls = undef
$filterextended = undef
$filtercasesensitive = undef
$filterdefaultdeny = undef
$anonymous = []
$connectport = []
$reverseonly = undef
$reversemagic = undef
$reversebaseurl = undef

case $::osfamily {
'RedHat':{
$configfile = '/etc/tinyproxy/tinyproxy.conf'
$package = 'tinyproxy'
$service = 'tinyproxy'
$hasstatus = false
$hasrestart = true
$user = 'tinyproxy'
$group = 'tinyproxy'
$port = 8888
$listen = undef
$bind = undef
$bindsame = undef
$connection_timeout = 600
$allow = []
$errorfiles = {}
$defaulterrorfile= '/usr/share/tinyproxy/default.html'
$stathost = undef
$statfile = '/usr/share/tinyproxy/stats.html'
$logfile = '/var/log/tinyproxy/tinyproxy.log'
$syslog = undef
$log_level = 'Info'
$pidfile = '/var/run/tinyproxy/tinyproxy.pid'
$xtinyproxy = undef
$maxclients = 100
$minspareservers = 5
$maxspareservers = 20
$startservers = 10
$maxrequestsperchild = 0
$viaproxyname = 'tinyproxy'
$disableviaheader = undef
$filter = undef
$filterurls = undef
$filterextended = undef
$filtercasesensitive = undef
$filterdefaultdeny = undef
$anonymous = []
$connectport = []
$reverseonly = undef
$reversemagic = undef
$reversebaseurl = undef
}
'Debian':{
$configfile = '/etc/tinyproxy.conf'
$user = 'nobody'
$group = 'nogroup'
$port = 3128
}
default: {
case $::lsbdistcodename {
'lucid','precise': {
$configfile = '/etc/tinyproxy.conf'
$package = 'tinyproxy'
$service = 'tinyproxy'
$hasstatus = false
$hasrestart = true
$user = 'nobody'
$group = 'nogroup'
$port = 3128
$listen = undef
$bind = undef
$bindsame = undef
$connection_timeout = 600
$allow = []
$errorfiles = {}
$defaulterrorfile= '/usr/share/tinyproxy/default.html'
$stathost = undef
$statfile = '/usr/share/tinyproxy/stats.html'
$logfile = '/var/log/tinyproxy/tinyproxy.log'
$syslog = undef
$log_level = 'Info'
$pidfile = '/var/run/tinyproxy/tinyproxy.pid'
$xtinyproxy = undef
$maxclients = 100
$minspareservers = 5
$maxspareservers = 20
$startservers = 10
$maxrequestsperchild = 0
$viaproxyname = 'tinyproxy'
$disableviaheader = undef
$filter = undef
$filterurls = undef
$filterextended = undef
$filtercasesensitive = undef
$filterdefaultdeny = undef
$anonymous = []
$connectport = []
$reverseonly = undef
$reversemagic = undef
$reversebaseurl = undef
}
default: {
fail("Unsupported osfamily: ${::osfamily}, lsbdistcodename: ${::lsbdistcodename}")
}
}
fail("Unsupported osfamily: ${::osfamily}, lsbdistcodename: ${::lsbdistcodename}")
}
}
}

0 comments on commit dffa4c4

Please sign in to comment.