diff options
author | Hunter Haugen <h.haugen@gmail.com> | 2012-10-12 15:08:10 -0700 |
---|---|---|
committer | Hunter Haugen <h.haugen@gmail.com> | 2012-10-12 15:08:10 -0700 |
commit | 57557202f5ccd16ccd276ce3997a3f8d370e8c60 (patch) | |
tree | 2a0bd3156b72e3c9f2aea3298d9def122b277ef1 /manifests | |
parent | a7498ce016087872488e60a2b80680a2096fbf68 (diff) |
No need to manually set ordering
Diffstat (limited to 'manifests')
-rw-r--r-- | manifests/balancermember.pp | 10 | ||||
-rw-r--r-- | manifests/listen.pp | 9 |
2 files changed, 2 insertions, 17 deletions
diff --git a/manifests/balancermember.pp b/manifests/balancermember.pp index a54d92e..a0e2753 100644 --- a/manifests/balancermember.pp +++ b/manifests/balancermember.pp @@ -32,11 +32,6 @@ # configuration. If you use an array in server_names and ipaddresses, the # same port is used for all balancermembers. # -# [*order*] -# The order, or numerical weight, of the fragment created by this defined -# resource type. This is necessary to ensure the fragment is associated -# with the correct listening service instance. -# # [*server_names*] # The name of the balancer member server as known to haproxy in the # listening service's configuration block. This defaults to the @@ -60,7 +55,6 @@ # @@haproxy::balancermember { 'haproxy': # listening_service => 'puppet00', # ports => '8140', -# order => '21', # server_names => $::hostname, # ipaddresses => $::ipaddress, # options => 'check', @@ -78,7 +72,6 @@ # haproxy::balancermember { 'haproxy': # listening_service => 'puppet00', # ports => '8140', -# order => '21', # server_names => ['server01', 'server02'], # ipaddresses => ['192.168.56.200', '192.168.56.201'], # options => 'check', @@ -89,14 +82,13 @@ define haproxy::balancermember ( $listening_service, $ports, - $order = '20', $server_names = $::hostname, $ipaddresses = $::ipaddress, $options = '' ) { # Template uses $ipaddresses, $server_name, $ports, $option concat::fragment { "${listening_service}_balancermember_${name}": - order => $order, + order => "20-${listening_service}-${name}", target => '/etc/haproxy/haproxy.cfg', content => template('haproxy/haproxy_balancermember.erb'), } diff --git a/manifests/listen.pp b/manifests/listen.pp index 40e2cf1..5dea8a8 100644 --- a/manifests/listen.pp +++ b/manifests/listen.pp @@ -26,11 +26,6 @@ # comma-separated string or an array of strings which may be ports or # hyphenated port ranges. # -# [*order*] -# The order, or numerical weight, of the fragment created by this defined -# resource type. This is necessary to ensure the fragment is associated -# with the correct listening service instance. -# # [*ipaddress*] # The ip address the proxy binds to. Empty addresses, '*', and '0.0.0.0' # mean that the proxy listens to all valid addresses on the system. @@ -56,7 +51,6 @@ # Exporting the resource for a balancer member: # # haproxy::listen { 'puppet00': -# order => '20', # ipaddress => $::ipaddress, # ports => '18140', # mode => 'tcp', @@ -75,7 +69,6 @@ # define haproxy::listen ( $ports, - $order = '20', $ipaddress = $::ipaddress, $mode = 'tcp', $collect_exported = true, @@ -89,7 +82,7 @@ define haproxy::listen ( ) { # Template uses: $name, $ipaddress, $ports, $options concat::fragment { "${name}_listen_block": - order => $order, + order => "20-${name}", target => '/etc/haproxy/haproxy.cfg', content => template('haproxy/haproxy_listen_block.erb'), } |