@@ -43,20 +43,20 @@ node 'haproxy-server' {
43
43
haproxy::listen { 'puppet00':
44
44
collect_exported => false,
45
45
ipaddress => $facts['networking']['ip'],
46
- ports => ' 8140' ,
46
+ ports => [ 8140] ,
47
47
}
48
48
haproxy::balancermember { 'server00':
49
49
listening_service => 'puppet00',
50
50
server_names => 'server00.example.com',
51
51
ipaddresses => '10.0.0.10',
52
- ports => ' 8140' ,
52
+ ports => [ 8140] ,
53
53
options => 'check',
54
54
}
55
55
haproxy::balancermember { 'server01':
56
56
listening_service => 'puppet00',
57
57
server_names => 'server01.example.com',
58
58
ipaddresses => '10.0.0.11',
59
- ports => ' 8140' ,
59
+ ports => [ 8140] ,
60
60
options => 'check',
61
61
}
62
62
}
@@ -153,7 +153,7 @@ To export the resource for a balancermember and collect it on a single HAProxy l
153
153
~~~ puppet
154
154
haproxy::listen { 'puppet00':
155
155
ipaddress => $facts['networking']['ip'],
156
- ports => ' 8140' ,
156
+ ports => [ 8140] ,
157
157
mode => 'tcp',
158
158
options => {
159
159
'option' => [
@@ -213,7 +213,7 @@ Then create the resource for multiple balancermembers at once:
213
213
~~~ puppet
214
214
haproxy::balancermember { 'haproxy':
215
215
listening_service => 'puppet00',
216
- ports => ' 8140' ,
216
+ ports => 8140,
217
217
server_names => ['server01', 'server02'],
218
218
ipaddresses => ['192.168.56.200', '192.168.56.201'],
219
219
options => 'check',
@@ -231,7 +231,7 @@ node 'haproxy-server' {
231
231
include ::haproxy
232
232
haproxy::listen { 'puppet00':
233
233
ipaddress => $facts['networking']['ip'],
234
- ports => ' 8140' ,
234
+ ports => 8140,
235
235
}
236
236
}
237
237
@@ -240,7 +240,7 @@ node /^server\d+/ {
240
240
listening_service => 'puppet00',
241
241
server_names => $facts['networking']['hostname'],
242
242
ipaddresses => $facts['networking']['ip'],
243
- ports => ' 8140' ,
243
+ ports => 8140,
244
244
options => 'check',
245
245
}
246
246
}
@@ -255,7 +255,7 @@ This example routes traffic from port 8140 to all balancermembers added to a bac
255
255
~~~ puppet
256
256
haproxy::frontend { 'puppet00':
257
257
ipaddress => $facts['networking']['ip'],
258
- ports => ' 8140' ,
258
+ ports => 8140,
259
259
mode => 'tcp',
260
260
bind_options => 'accept-proxy',
261
261
options => {
@@ -274,7 +274,7 @@ If option order is important, pass an array of hashes to the `options` parameter
274
274
~~~ puppet
275
275
haproxy::frontend { 'puppet00':
276
276
ipaddress => $facts['networking']['ip'],
277
- ports => ' 8140' ,
277
+ ports => [ 8140] ,
278
278
mode => 'tcp',
279
279
bind_options => 'accept-proxy',
280
280
options => [
@@ -353,7 +353,7 @@ haproxy::resolver { 'puppet00':
353
353
# Setup the balancermember to use the resolver for DNS resolution
354
354
haproxy::balancermember { 'haproxy':
355
355
listening_service => 'puppet00',
356
- ports => ' 8140' ,
356
+ ports => 8140,
357
357
server_names => ['server01', 'server02'],
358
358
ipaddresses => ['server01', 'server02'],
359
359
options => 'check resolvers puppet00 resolve-prefer ipv4',
@@ -399,7 +399,7 @@ class and uses `haproxy::instance` to add an additional instance called
399
399
instance => 'haproxy',
400
400
collect_exported => false,
401
401
ipaddress => $facts['networking']['ip'],
402
- ports => ' 8800' ,
402
+ ports => 8800,
403
403
}
404
404
405
405
haproxy::instance { 'beta': }
@@ -413,7 +413,7 @@ class and uses `haproxy::instance` to add an additional instance called
413
413
instance => 'beta',
414
414
collect_exported => false,
415
415
ipaddress => $facts['networking']['ip'],
416
- ports => ' 9900' ,
416
+ ports => 9900,
417
417
}
418
418
~~~
419
419
@@ -432,7 +432,7 @@ The second uses a custom package.
432
432
instance => 'group1',
433
433
collect_exported => false,
434
434
ipaddress => $facts['networking']['ip'],
435
- ports => ' 8800' ,
435
+ ports => 8800,
436
436
}
437
437
haproxy::instance { 'group2': }
438
438
->
@@ -446,7 +446,7 @@ The second uses a custom package.
446
446
instance => 'group2',
447
447
collect_exported => false,
448
448
ipaddress => $facts['networking']['ip'],
449
- ports => ' 9900' ,
449
+ ports => 9900,
450
450
}
451
451
~~~
452
452
@@ -481,7 +481,7 @@ Or expressed using `haproxy::frontend`:
481
481
~~~ puppet
482
482
haproxy::frontend { 'ft_allapps':
483
483
ipaddress => '0.0.0.0',
484
- ports => '80',
484
+ ports => [ '80'] ,
485
485
mode => 'http',
486
486
options => {
487
487
'use_backend' => '%[req.hdr(host),lower,map(/etc/haproxy/domains-to-backends.map,bk_default)]'
0 commit comments