First stage of porting
This commit is contained in:
parent
cf1bd28c12
commit
2e988626e2
@ -144,33 +144,45 @@ def setup_haproxies():
|
|||||||
|
|
||||||
for single_hpsc in hpsc_http:
|
for single_hpsc in hpsc_http:
|
||||||
for riak in riaks:
|
for riak in riaks:
|
||||||
signals.connect(riak, single_hpsc, {'riak_hostname': 'servers',
|
# signals.connect(riak, single_hpsc, {'riak_hostname': 'servers',
|
||||||
'riak_port_http': 'ports'})
|
# 'riak_port_http': 'ports'})
|
||||||
|
signals.connect(riak, single_hpsc, {'riak_hostname': 'backends:server',
|
||||||
|
'riak_port_http': 'backends:port'})
|
||||||
|
|
||||||
for single_hpsc in hpsc_pb:
|
for single_hpsc in hpsc_pb:
|
||||||
for riak in riaks:
|
for riak in riaks:
|
||||||
signals.connect(riak, single_hpsc, {'riak_hostname': 'servers',
|
# signals.connect(riak, single_hpsc, {'riak_hostname': 'servers',
|
||||||
'riak_port_pb': 'ports'})
|
# 'riak_port_pb': 'ports'})
|
||||||
|
signals.connect(riak, single_hpsc, {'riak_hostname': 'backends:server',
|
||||||
|
'riak_port_pb': 'backends:port'})
|
||||||
|
|
||||||
# haproxy config to haproxy service
|
# haproxy config to haproxy service
|
||||||
|
|
||||||
for single_hpc, single_hpsc in zip(hpc, hpsc_http):
|
for single_hpc, single_hpsc in zip(hpc, hpsc_http):
|
||||||
signals.connect(single_hpsc, single_hpc, {'protocol': 'configs_protocols',
|
# signals.connect(single_hpsc, single_hpc, {'protocol': 'configs_protocols',
|
||||||
'listen_port': 'listen_ports',
|
# 'listen_port': 'listen_ports',
|
||||||
'name': 'configs_names',
|
# 'name': 'configs_names',
|
||||||
'servers': 'configs',
|
# 'servers': 'configs',
|
||||||
'ports': 'configs_ports'})
|
# 'ports': 'configs_ports'})
|
||||||
|
signals.connect(single_hpsc, single_hpc, {"backends": "config:backends",
|
||||||
|
"listen_port": "config:listen_port",
|
||||||
|
"protocol": "config:protocol",
|
||||||
|
"name": "config:name"})
|
||||||
|
|
||||||
for single_hpc, single_hpsc in zip(hpc, hpsc_pb):
|
for single_hpc, single_hpsc in zip(hpc, hpsc_pb):
|
||||||
signals.connect(single_hpsc, single_hpc, {'protocol': 'configs_protocols',
|
# signals.connect(single_hpsc, single_hpc, {'protocol': 'configs_protocols',
|
||||||
'listen_port': 'listen_ports',
|
# 'listen_port': 'listen_ports',
|
||||||
'name': 'configs_names',
|
# 'name': 'configs_names',
|
||||||
'servers': 'configs',
|
# 'servers': 'configs',
|
||||||
'ports': 'configs_ports'})
|
# 'ports': 'configs_ports'})
|
||||||
|
signals.connect(single_hpsc, single_hpc, {"backends": "config:backends",
|
||||||
|
"listen_port": "config:listen_port",
|
||||||
|
"protocol": "config:protocol",
|
||||||
|
"name": "config:name"})
|
||||||
|
|
||||||
for single_hps, single_hpc in zip(hps, hpc):
|
# for single_hps, single_hpc in zip(hps, hpc):
|
||||||
signals.connect(single_hpc, single_hps, {'listen_ports': 'ports'},
|
# signals.connect(single_hpc, single_hps, {'listen_ports': 'ports'},
|
||||||
events=False)
|
# events=False)
|
||||||
|
|
||||||
# assign haproxy services to each node
|
# assign haproxy services to each node
|
||||||
|
|
||||||
|
@ -8,20 +8,23 @@ input:
|
|||||||
config_dir:
|
config_dir:
|
||||||
schema: {src: str!, dst: str!}
|
schema: {src: str!, dst: str!}
|
||||||
value: {src: /etc/solar/haproxy, dst: /etc/haproxy}
|
value: {src: /etc/solar/haproxy, dst: /etc/haproxy}
|
||||||
listen_ports:
|
# listen_ports:
|
||||||
schema: [int]
|
# schema: [int]
|
||||||
value: []
|
# value: []
|
||||||
configs:
|
# configs:
|
||||||
schema: [[str]]
|
# schema: [[str]]
|
||||||
value: []
|
# value: []
|
||||||
configs_names:
|
# configs_names:
|
||||||
schema: [str]
|
# schema: [str]
|
||||||
value: []
|
# value: []
|
||||||
configs_ports:
|
# configs_ports:
|
||||||
schema: [[int]]
|
# schema: [[int]]
|
||||||
value: []
|
# value: []
|
||||||
configs_protocols:
|
# configs_protocols:
|
||||||
schema: [str]
|
# schema: [str]
|
||||||
|
# value: []
|
||||||
|
config:
|
||||||
|
schema: [{backends: [{server: str!, port: int!}], listen_port: int!, protocol: str!, name: str!}]
|
||||||
value: []
|
value: []
|
||||||
ssh_user:
|
ssh_user:
|
||||||
schema: str!
|
schema: str!
|
||||||
|
@ -5,17 +5,19 @@ input:
|
|||||||
name:
|
name:
|
||||||
schema: str!
|
schema: str!
|
||||||
value: general_haproxy
|
value: general_haproxy
|
||||||
|
backends:
|
||||||
|
schema: [{server: str!, port: int!}]
|
||||||
listen_port:
|
listen_port:
|
||||||
schema: int!
|
schema: int!
|
||||||
value: 9999
|
value: 9999
|
||||||
protocol:
|
protocol:
|
||||||
schema: str!
|
schema: str!
|
||||||
value: http
|
value: http
|
||||||
ports:
|
# ports:
|
||||||
schema: [int]
|
# schema: [int]
|
||||||
value: []
|
# value: []
|
||||||
servers:
|
# servers:
|
||||||
schema: [str]
|
# schema: [str]
|
||||||
value: []
|
# value: []
|
||||||
|
|
||||||
tags: [resources/haproxy, resource/haproxy_general_config]
|
tags: [resources/haproxy, resource/haproxy_general_config]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user