Add CI for contrib/terraform/openstack (#4475)
This commit is contained in:
parent
d2a1ac3b0c
commit
854cc53fa5
1 changed files with 38 additions and 2 deletions
|
@ -64,6 +64,16 @@ before_script:
|
||||||
CI_PLATFORM: "do"
|
CI_PLATFORM: "do"
|
||||||
SSH_USER: root
|
SSH_USER: root
|
||||||
|
|
||||||
|
.ovh_variables: &ovh_variables
|
||||||
|
OS_AUTH_URL: https://auth.cloud.ovh.net/v3
|
||||||
|
OS_PROJECT_ID: 8d3cd5d737d74227ace462dee0b903fe
|
||||||
|
OS_PROJECT_NAME: "9361447987648822"
|
||||||
|
OS_USER_DOMAIN_NAME: Default
|
||||||
|
OS_PROJECT_DOMAIN_ID: default
|
||||||
|
OS_USERNAME: 8XuhBMfkKVrk
|
||||||
|
OS_REGION_NAME: UK1
|
||||||
|
OS_INTERFACE: public
|
||||||
|
OS_IDENTITY_API_VERSION: "3"
|
||||||
|
|
||||||
.testcases: &testcases
|
.testcases: &testcases
|
||||||
<<: *job
|
<<: *job
|
||||||
|
@ -769,7 +779,6 @@ tox-inventory-builder:
|
||||||
- echo "$PACKET_PRIVATE_KEY" | base64 -d > ~/.ssh/id_rsa
|
- echo "$PACKET_PRIVATE_KEY" | base64 -d > ~/.ssh/id_rsa
|
||||||
- chmod 400 ~/.ssh/id_rsa
|
- chmod 400 ~/.ssh/id_rsa
|
||||||
- echo "$PACKET_PUBLIC_KEY" | base64 -d > ~/.ssh/id_rsa.pub
|
- echo "$PACKET_PUBLIC_KEY" | base64 -d > ~/.ssh/id_rsa.pub
|
||||||
- export TF_VAR_public_key_path=""
|
|
||||||
only: ['master', /^pr-.*$/]
|
only: ['master', /^pr-.*$/]
|
||||||
|
|
||||||
.terraform_validate: &terraform_validate
|
.terraform_validate: &terraform_validate
|
||||||
|
@ -785,7 +794,7 @@ tox-inventory-builder:
|
||||||
when: manual
|
when: manual
|
||||||
script:
|
script:
|
||||||
- terraform apply -auto-approve ../../contrib/terraform/$PROVIDER
|
- terraform apply -auto-approve ../../contrib/terraform/$PROVIDER
|
||||||
- ansible-playbook -i hosts ../../cluster.yml
|
- ansible-playbook -i hosts ../../cluster.yml --become
|
||||||
after_script:
|
after_script:
|
||||||
# Cleanup regardless of exit code
|
# Cleanup regardless of exit code
|
||||||
- cd inventory/$CLUSTER
|
- cd inventory/$CLUSTER
|
||||||
|
@ -817,3 +826,30 @@ tf-apply-packet:
|
||||||
TF_VAR_plan_k8s_masters: t1.small.x86
|
TF_VAR_plan_k8s_masters: t1.small.x86
|
||||||
TF_VAR_plan_k8s_nodes: t1.small.x86
|
TF_VAR_plan_k8s_nodes: t1.small.x86
|
||||||
TF_VAR_facility: "ewr1"
|
TF_VAR_facility: "ewr1"
|
||||||
|
TF_VAR_public_key_path: ""
|
||||||
|
|
||||||
|
tf-apply-ovh:
|
||||||
|
<<: *terraform_apply
|
||||||
|
variables:
|
||||||
|
<<: *ovh_variables
|
||||||
|
TF_VERSION: 0.11.11
|
||||||
|
PROVIDER: openstack
|
||||||
|
CLUSTER: $CI_COMMIT_REF_NAME
|
||||||
|
ANSIBLE_TIMEOUT: "60"
|
||||||
|
TF_VAR_cluster_name: $CI_COMMIT_REF_NAME
|
||||||
|
TF_VAR_number_of_k8s_masters: "0"
|
||||||
|
TF_VAR_number_of_k8s_masters_no_floating_ip: "1"
|
||||||
|
TF_VAR_number_of_k8s_masters_no_floating_ip_no_etcd: "0"
|
||||||
|
TF_VAR_number_of_etcd: "0"
|
||||||
|
TF_VAR_number_of_k8s_nodes: "0"
|
||||||
|
TF_VAR_number_of_k8s_nodes_no_floating_ip: "1"
|
||||||
|
TF_VAR_number_of_gfs_nodes_no_floating_ip: "0"
|
||||||
|
TF_VAR_number_of_bastions: "0"
|
||||||
|
TF_VAR_number_of_k8s_masters_no_etcd: "0"
|
||||||
|
TF_VAR_use_neutron: "0"
|
||||||
|
TF_VAR_floatingip_pool: "Ext-Net"
|
||||||
|
TF_VAR_external_net: "6011fbc9-4cbf-46a4-8452-6890a340b60b"
|
||||||
|
TF_VAR_network_name: "Ext-Net"
|
||||||
|
TF_VAR_flavor_k8s_master: "defa64c3-bd46-43b4-858a-d93bbae0a229" #s1-8
|
||||||
|
TF_VAR_flavor_k8s_node: "defa64c3-bd46-43b4-858a-d93bbae0a229" #s1-8
|
||||||
|
TF_VAR_image: "Ubuntu 18.04"
|
||||||
|
|
Loading…
Reference in a new issue