Compare commits

...

5 Commits

6 changed files with 17 additions and 11 deletions

View File

@ -0,0 +1,3 @@
---
infrastructure: dev
conductor_workers_server: http://conductor-dev.int.d4science.net/api

View File

@ -0,0 +1,3 @@
---
infrastructure: pre
conductor_workers_server: https://conductor.pre.d4science.org/api

View File

@ -2,4 +2,4 @@
nw_cluster nw_cluster
[nw_cluster] [nw_cluster]
nubis1.int.d4science.net infrastructure=dev nubis1.int.d4science.net

View File

@ -1,5 +1,5 @@
[pre_infra:children] [pre_infra:children]
nw_cluster pre_cluster
[nw_cluster] [pre_cluster]
docker-swarm1.int.d4science.net docker_swarm_manager_main_node=True infrastructure=pre docker-swarm1.int.d4science.net docker_swarm_manager_main_node=True

View File

@ -21,7 +21,7 @@ haproxy_docker_swarm_additional_networks: []
haproxy_docker_swarm_haproxy_constraints: haproxy_docker_swarm_haproxy_constraints:
- 'node.role == manager' - 'node.role == manager'
haproxy_docker_swarm_additional_services: [{ acl_name: 'conductor-server', acl_rule: 'hdr_dom(host) -i conductor-dev.int.d4science.net', stack_name: 'conductor', service_name: 'conductor-server', service_replica_num: '2', service_port: '8080', service_overlay_network: 'conductor-network', stick_sessions: False, stick_on_cookie: True, stick_cookie: 'JSESSIONID', stick_table: 'type ip size 2m expire 180m', balance_type: 'roundrobin', backend_options: '', http_check_enabled: True, http_check: 'meth GET uri /api/health ver HTTP/1.1 hdr Host localhost', http_check_expect: 'rstatus (2|3)[0-9][0-9]' }, { acl_name: 'conductor-ui', acl_rule: 'hdr_dom(host) -i conductorui-dev.int.d4science.net', stack_name: 'conductor', service_name: 'conductor-ui', service_replica_num: '2', service_port: '5000', service_overlay_network: 'conductor-network', stick_sessions: False, stick_on_cookie: True, stick_cookie: 'JSESSIONID', stick_table: 'type ip size 2m expire 180m', balance_type: 'roundrobin', backend_options: '', http_check_enabled: True, http_check: 'meth GET uri / ver HTTP/1.1 hdr Host localhost', http_check_expect: 'rstatus (2|3)[0-9][0-9]' }] haproxy_docker_swarm_additional_services: [{ acl_name: 'conductor-server', acl_rule: 'hdr_dom(host) -i conductor-dev.int.d4science.net', stack_name: 'conductor-{{ infrastructure }}', service_name: 'conductor-server', service_replica_num: '2', service_port: '8080', service_overlay_network: 'conductor-network', stick_sessions: False, stick_on_cookie: True, stick_cookie: 'JSESSIONID', stick_table: 'type ip size 2m expire 180m', balance_type: 'roundrobin', backend_options: '', http_check_enabled: True, http_check: 'meth GET uri /api/health ver HTTP/1.1 hdr Host localhost', http_check_expect: 'rstatus (2|3)[0-9][0-9]' }, { acl_name: 'conductor-ui', acl_rule: 'hdr_dom(host) -i conductorui-dev.int.d4science.net', stack_name: 'conductor-{{ infrastructure }}', service_name: 'conductor-ui', service_replica_num: '2', service_port: '5000', service_overlay_network: 'conductor-network', stick_sessions: False, stick_on_cookie: True, stick_cookie: 'JSESSIONID', stick_table: 'type ip size 2m expire 180m', balance_type: 'roundrobin', backend_options: '', http_check_enabled: True, http_check: 'meth GET uri / ver HTTP/1.1 hdr Host localhost', http_check_expect: 'rstatus (2|3)[0-9][0-9]' }]
# - { acl_name: 'service', acl_rule: 'hdr_dom(host) -i service.example.com', stack_name: 'stack', service_name: 'service', service_replica_num: '1', service_port: '9999', service_overlay_network: 'service-network', stick_sessions: False, stick_on_cookie: True, stick_cookie: 'JSESSIONID', stick_table: 'type ip size 2m expire 180m', balance_type: 'roundrobin', backend_options: '', http_check_enabled: True, http_check: 'meth HEAD uri / ver HTTP/1.1 hdr Host localhost', http_check_expect: 'rstatus (2|3)[0-9][0-9]', allowed_networks: '192.168.1.0/24 192.168.2.0/24' } # - { acl_name: 'service', acl_rule: 'hdr_dom(host) -i service.example.com', stack_name: 'stack', service_name: 'service', service_replica_num: '1', service_port: '9999', service_overlay_network: 'service-network', stick_sessions: False, stick_on_cookie: True, stick_cookie: 'JSESSIONID', stick_table: 'type ip size 2m expire 180m', balance_type: 'roundrobin', backend_options: '', http_check_enabled: True, http_check: 'meth HEAD uri / ver HTTP/1.1 hdr Host localhost', http_check_expect: 'rstatus (2|3)[0-9][0-9]', allowed_networks: '192.168.1.0/24 192.168.2.0/24' }
haproxy_default_port: 80 haproxy_default_port: 80

View File

@ -1,5 +1,5 @@
--- ---
- hosts: [nw_cluster] - hosts: pre_infra:dev_infra
roles: roles:
- common - common
- role: cluster-replacement - role: cluster-replacement
@ -18,12 +18,12 @@
compose: compose:
- "{{ target_path }}/{{ db|default('postgres', true) }}-swarm.yaml" - "{{ target_path }}/{{ db|default('postgres', true) }}-swarm.yaml"
- "{{ target_path }}/elasticsearch-swarm.yaml" - "{{ target_path }}/elasticsearch-swarm.yaml"
when: dry is not defined or dry|bool when: dry is not defined or not dry|bool
- name: Waiting for databases - name: Waiting for databases
pause: pause:
seconds: 10 seconds: 10
when: dry is not defined or dry|bool when: dry is not defined or not dry|bool
- name: Start conductor - name: Start conductor
docker_stack: docker_stack:
@ -31,7 +31,7 @@
state: present state: present
compose: compose:
- "{{ target_path }}/conductor-swarm.yaml" - "{{ target_path }}/conductor-swarm.yaml"
when: dry is not defined or dry|bool when: dry is not defined or not dry|bool
- name: Start haproxy - name: Start haproxy
docker_stack: docker_stack:
@ -40,7 +40,7 @@
compose: compose:
- "{{ target_path }}/haproxy-swarm.yaml" - "{{ target_path }}/haproxy-swarm.yaml"
when: when:
- dry is not defined or dry|bool - dry is not defined or not dry|bool
- cluster_replacement is defined - cluster_replacement is defined
- cluster_replacement|bool - cluster_replacement|bool
@ -51,6 +51,6 @@
compose: compose:
- "{{ target_path }}/conductor-workers-swarm.yaml" - "{{ target_path }}/conductor-workers-swarm.yaml"
when: when:
- dry is not defined or dry|bool - dry is not defined or not dry|bool
- no_workers is not defined or not no_workers|bool - no_workers is not defined or not no_workers|bool