Add all-in-one CI mode and make coreos test aio (#1665)
This commit is contained in:
parent
8e731337ba
commit
0aab3c97a0
3 changed files with 23 additions and 7 deletions
|
@ -273,14 +273,14 @@ before_script:
|
||||||
-e cloud_region=${CLOUD_REGION}
|
-e cloud_region=${CLOUD_REGION}
|
||||||
|
|
||||||
# Test matrix. Leave the comments for markup scripts.
|
# Test matrix. Leave the comments for markup scripts.
|
||||||
.coreos_calico_sep_variables: &coreos_calico_sep_variables
|
.coreos_calico_aio_variables: &coreos_calico_aio_variables
|
||||||
# stage: deploy-gce-part1
|
# stage: deploy-gce-part1
|
||||||
AUTHORIZATION_MODES: "{ 'authorization_modes': [ 'RBAC' ] }"
|
AUTHORIZATION_MODES: "{ 'authorization_modes': [ 'RBAC' ] }"
|
||||||
KUBE_NETWORK_PLUGIN: calico
|
KUBE_NETWORK_PLUGIN: calico
|
||||||
CLOUD_IMAGE: coreos-stable-1465-6-0-v20170817
|
CLOUD_IMAGE: coreos-stable-1465-6-0-v20170817
|
||||||
CLOUD_REGION: us-west1-b
|
CLOUD_REGION: us-west1-b
|
||||||
CLOUD_MACHINE_TYPE: "n1-standard-2"
|
CLOUD_MACHINE_TYPE: "n1-standard-2"
|
||||||
CLUSTER_MODE: separate
|
CLUSTER_MODE: aio
|
||||||
BOOTSTRAP_OS: coreos
|
BOOTSTRAP_OS: coreos
|
||||||
RESOLVCONF_MODE: host_resolvconf # This is required as long as the CoreOS stable channel uses docker < 1.12
|
RESOLVCONF_MODE: host_resolvconf # This is required as long as the CoreOS stable channel uses docker < 1.12
|
||||||
##User-data to simply turn off coreos upgrades
|
##User-data to simply turn off coreos upgrades
|
||||||
|
@ -412,13 +412,13 @@ before_script:
|
||||||
STARTUP_SCRIPT: ""
|
STARTUP_SCRIPT: ""
|
||||||
|
|
||||||
# Builds for PRs only (premoderated by unit-tests step) and triggers (auto)
|
# Builds for PRs only (premoderated by unit-tests step) and triggers (auto)
|
||||||
coreos-calico-sep:
|
coreos-calico-aio:
|
||||||
stage: deploy-gce-part1
|
stage: deploy-gce-part1
|
||||||
<<: *job
|
<<: *job
|
||||||
<<: *gce
|
<<: *gce
|
||||||
variables:
|
variables:
|
||||||
<<: *gce_variables
|
<<: *gce_variables
|
||||||
<<: *coreos_calico_sep_variables
|
<<: *coreos_calico_aio_variables
|
||||||
when: on_success
|
when: on_success
|
||||||
except: ['triggers']
|
except: ['triggers']
|
||||||
only: [/^pr-.*$/]
|
only: [/^pr-.*$/]
|
||||||
|
@ -429,7 +429,7 @@ coreos-calico-sep-triggers:
|
||||||
<<: *gce
|
<<: *gce
|
||||||
variables:
|
variables:
|
||||||
<<: *gce_variables
|
<<: *gce_variables
|
||||||
<<: *coreos_calico_sep_variables
|
<<: *coreos_calico_aio_variables
|
||||||
when: on_success
|
when: on_success
|
||||||
only: ['triggers']
|
only: ['triggers']
|
||||||
|
|
||||||
|
|
|
@ -15,6 +15,8 @@
|
||||||
instance_names: >-
|
instance_names: >-
|
||||||
{%- if mode in ['separate', 'separate-scale', 'ha', 'ha-scale'] -%}
|
{%- if mode in ['separate', 'separate-scale', 'ha', 'ha-scale'] -%}
|
||||||
k8s-{{test_name}}-1,k8s-{{test_name}}-2,k8s-{{test_name}}-3
|
k8s-{{test_name}}-1,k8s-{{test_name}}-2,k8s-{{test_name}}-3
|
||||||
|
{%- elif mode == 'aio' -%}
|
||||||
|
k8s-{{test_name}}-1
|
||||||
{%- else -%}
|
{%- else -%}
|
||||||
k8s-{{test_name}}-1,k8s-{{test_name}}-2
|
k8s-{{test_name}}-1,k8s-{{test_name}}-2
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
{% set node1 = gce.instance_data[0].name %}
|
{% set node1 = gce.instance_data[0].name %}
|
||||||
{% set node2 = gce.instance_data[1].name %}
|
|
||||||
{{node1}} ansible_ssh_host={{gce.instance_data[0].public_ip}}
|
{{node1}} ansible_ssh_host={{gce.instance_data[0].public_ip}}
|
||||||
|
{% if mode != "aio" %}
|
||||||
|
{% set node2 = gce.instance_data[1].name %}
|
||||||
{{node2}} ansible_ssh_host={{gce.instance_data[1].public_ip}}
|
{{node2}} ansible_ssh_host={{gce.instance_data[1].public_ip}}
|
||||||
|
{% endif %}
|
||||||
{% if mode is defined and mode in ["ha", "ha-scale", "separate", "separate-scale"] %}
|
{% if mode is defined and mode in ["ha", "ha-scale", "separate", "separate-scale"] %}
|
||||||
{% set node3 = gce.instance_data[2].name %}
|
{% set node3 = gce.instance_data[2].name %}
|
||||||
{{node3}} ansible_ssh_host={{gce.instance_data[2].public_ip}}
|
{{node3}} ansible_ssh_host={{gce.instance_data[2].public_ip}}
|
||||||
|
@ -35,7 +37,7 @@
|
||||||
{{node1}}
|
{{node1}}
|
||||||
{{node2}}
|
{{node2}}
|
||||||
{{node3}}
|
{{node3}}
|
||||||
{% else %}
|
{% elif mode == "default" %}
|
||||||
[kube-master]
|
[kube-master]
|
||||||
{{node1}}
|
{{node1}}
|
||||||
|
|
||||||
|
@ -45,6 +47,18 @@
|
||||||
[etcd]
|
[etcd]
|
||||||
{{node1}}
|
{{node1}}
|
||||||
|
|
||||||
|
[vault]
|
||||||
|
{{node1}}
|
||||||
|
{% elif mode == "aio" %}
|
||||||
|
[kube-master]
|
||||||
|
{{node1}}
|
||||||
|
|
||||||
|
[kube-node]
|
||||||
|
{{node1}}
|
||||||
|
|
||||||
|
[etcd]
|
||||||
|
{{node1}}
|
||||||
|
|
||||||
[vault]
|
[vault]
|
||||||
{{node1}}
|
{{node1}}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
Loading…
Reference in a new issue