disable metrics server and fix terraform (#4617)
* disable metrics server in centos7-flannel-addons job Change-Id: I1d87923547584896f64dda9ea8feb5581ad48cbe * Fix tf facility->facilities syntax Change-Id: I434bfe53f47e8e4a546890e0b62d24bde6e6d6a7 * Update Terraform CI for facilities * Fix undefined variable error
This commit is contained in:
parent
50751bb610
commit
d89ecb8308
8 changed files with 16 additions and 14 deletions
|
@ -72,7 +72,7 @@ tf-packet-ubuntu16-default:
|
||||||
TF_VAR_number_of_k8s_nodes: "1"
|
TF_VAR_number_of_k8s_nodes: "1"
|
||||||
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_facilities: '["ewr1"]'
|
||||||
TF_VAR_public_key_path: ""
|
TF_VAR_public_key_path: ""
|
||||||
TF_VAR_operating_system: ubuntu_16_04
|
TF_VAR_operating_system: ubuntu_16_04
|
||||||
|
|
||||||
|
@ -87,7 +87,7 @@ tf-packet-ubuntu18-default:
|
||||||
TF_VAR_number_of_k8s_nodes: "1"
|
TF_VAR_number_of_k8s_nodes: "1"
|
||||||
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: "ams1"
|
TF_VAR_facilities: '["ams1"]'
|
||||||
TF_VAR_public_key_path: ""
|
TF_VAR_public_key_path: ""
|
||||||
TF_VAR_operating_system: ubuntu_18_04
|
TF_VAR_operating_system: ubuntu_18_04
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,7 @@ resource "packet_device" "k8s_master" {
|
||||||
count = "${var.number_of_k8s_masters}"
|
count = "${var.number_of_k8s_masters}"
|
||||||
hostname = "${var.cluster_name}-k8s-master-${count.index+1}"
|
hostname = "${var.cluster_name}-k8s-master-${count.index+1}"
|
||||||
plan = "${var.plan_k8s_masters}"
|
plan = "${var.plan_k8s_masters}"
|
||||||
facility = "${var.facility}"
|
facilities = "${var.facilities}"
|
||||||
operating_system = "${var.operating_system}"
|
operating_system = "${var.operating_system}"
|
||||||
billing_cycle = "${var.billing_cycle}"
|
billing_cycle = "${var.billing_cycle}"
|
||||||
project_id = "${var.packet_project_id}"
|
project_id = "${var.packet_project_id}"
|
||||||
|
@ -26,7 +26,7 @@ resource "packet_device" "k8s_master_no_etcd" {
|
||||||
count = "${var.number_of_k8s_masters_no_etcd}"
|
count = "${var.number_of_k8s_masters_no_etcd}"
|
||||||
hostname = "${var.cluster_name}-k8s-master-${count.index+1}"
|
hostname = "${var.cluster_name}-k8s-master-${count.index+1}"
|
||||||
plan = "${var.plan_k8s_masters_no_etcd}"
|
plan = "${var.plan_k8s_masters_no_etcd}"
|
||||||
facility = "${var.facility}"
|
facilities = "${var.facilities}"
|
||||||
operating_system = "${var.operating_system}"
|
operating_system = "${var.operating_system}"
|
||||||
billing_cycle = "${var.billing_cycle}"
|
billing_cycle = "${var.billing_cycle}"
|
||||||
project_id = "${var.packet_project_id}"
|
project_id = "${var.packet_project_id}"
|
||||||
|
@ -39,7 +39,7 @@ resource "packet_device" "k8s_etcd" {
|
||||||
count = "${var.number_of_etcd}"
|
count = "${var.number_of_etcd}"
|
||||||
hostname = "${var.cluster_name}-etcd-${count.index+1}"
|
hostname = "${var.cluster_name}-etcd-${count.index+1}"
|
||||||
plan = "${var.plan_etcd}"
|
plan = "${var.plan_etcd}"
|
||||||
facility = "${var.facility}"
|
facilities = "${var.facilities}"
|
||||||
operating_system = "${var.operating_system}"
|
operating_system = "${var.operating_system}"
|
||||||
billing_cycle = "${var.billing_cycle}"
|
billing_cycle = "${var.billing_cycle}"
|
||||||
project_id = "${var.packet_project_id}"
|
project_id = "${var.packet_project_id}"
|
||||||
|
@ -52,7 +52,7 @@ resource "packet_device" "k8s_node" {
|
||||||
count = "${var.number_of_k8s_nodes}"
|
count = "${var.number_of_k8s_nodes}"
|
||||||
hostname = "${var.cluster_name}-k8s-node-${count.index+1}"
|
hostname = "${var.cluster_name}-k8s-node-${count.index+1}"
|
||||||
plan = "${var.plan_k8s_nodes}"
|
plan = "${var.plan_k8s_nodes}"
|
||||||
facility = "${var.facility}"
|
facilities = "${var.facilities}"
|
||||||
operating_system = "${var.operating_system}"
|
operating_system = "${var.operating_system}"
|
||||||
billing_cycle = "${var.billing_cycle}"
|
billing_cycle = "${var.billing_cycle}"
|
||||||
project_id = "${var.packet_project_id}"
|
project_id = "${var.packet_project_id}"
|
||||||
|
|
|
@ -10,7 +10,7 @@ packet_project_id = "Example-API-Token"
|
||||||
public_key_path = "~/.ssh/id_rsa.pub"
|
public_key_path = "~/.ssh/id_rsa.pub"
|
||||||
|
|
||||||
# cluster location
|
# cluster location
|
||||||
facility = "ewr1"
|
facilities = ["ewr1"]
|
||||||
|
|
||||||
# standalone etcds
|
# standalone etcds
|
||||||
number_of_etcd = 0
|
number_of_etcd = 0
|
||||||
|
|
|
@ -19,8 +19,8 @@ variable "billing_cycle" {
|
||||||
default = "hourly"
|
default = "hourly"
|
||||||
}
|
}
|
||||||
|
|
||||||
variable "facility" {
|
variable "facilities" {
|
||||||
default = "dfw2"
|
default = ["dfw2"]
|
||||||
}
|
}
|
||||||
|
|
||||||
variable "plan_k8s_masters" {
|
variable "plan_k8s_masters" {
|
||||||
|
|
|
@ -157,7 +157,7 @@ def packet_device(resource, tfvars=None):
|
||||||
|
|
||||||
attrs = {
|
attrs = {
|
||||||
'id': raw_attrs['id'],
|
'id': raw_attrs['id'],
|
||||||
'facility': raw_attrs['facility'],
|
'facilities': parse_list(raw_attrs, 'facilities']),
|
||||||
'hostname': raw_attrs['hostname'],
|
'hostname': raw_attrs['hostname'],
|
||||||
'operating_system': raw_attrs['operating_system'],
|
'operating_system': raw_attrs['operating_system'],
|
||||||
'locked': parse_bool(raw_attrs['locked']),
|
'locked': parse_bool(raw_attrs['locked']),
|
||||||
|
@ -178,7 +178,7 @@ def packet_device(resource, tfvars=None):
|
||||||
}
|
}
|
||||||
|
|
||||||
# add groups based on attrs
|
# add groups based on attrs
|
||||||
groups.append('packet_facility=' + attrs['facility'])
|
groups.append('packet_facilities=' + attrs['facilities'])
|
||||||
groups.append('packet_operating_system=' + attrs['operating_system'])
|
groups.append('packet_operating_system=' + attrs['operating_system'])
|
||||||
groups.append('packet_locked=%s' % attrs['locked'])
|
groups.append('packet_locked=%s' % attrs['locked'])
|
||||||
groups.append('packet_state=' + attrs['state'])
|
groups.append('packet_state=' + attrs['state'])
|
||||||
|
|
|
@ -36,4 +36,4 @@
|
||||||
- inventory_hostname == groups['kube-master'][0]
|
- inventory_hostname == groups['kube-master'][0]
|
||||||
- not item is skipped
|
- not item is skipped
|
||||||
loop_control:
|
loop_control:
|
||||||
label: "{{ item.item.file }}"
|
label: "{{ item.item.file }}"
|
||||||
|
|
|
@ -20,7 +20,8 @@ cloud_provider: gce
|
||||||
kube_encrypt_secret_data: true
|
kube_encrypt_secret_data: true
|
||||||
# ingress_nginx_enabled: true
|
# ingress_nginx_enabled: true
|
||||||
cert_manager_enabled: true
|
cert_manager_enabled: true
|
||||||
metrics_server_enabled: true
|
# Disabled temporarily
|
||||||
|
metrics_server_enabled: false
|
||||||
kube_token_auth: true
|
kube_token_auth: true
|
||||||
kube_basic_auth: true
|
kube_basic_auth: true
|
||||||
enable_nodelocaldns: false
|
enable_nodelocaldns: false
|
||||||
|
|
|
@ -17,7 +17,8 @@ dns_min_replicas: 1
|
||||||
kube_encrypt_secret_data: true
|
kube_encrypt_secret_data: true
|
||||||
ingress_nginx_enabled: true
|
ingress_nginx_enabled: true
|
||||||
cert_manager_enabled: true
|
cert_manager_enabled: true
|
||||||
metrics_server_enabled: true
|
# Disabled temporarily
|
||||||
|
metrics_server_enabled: false
|
||||||
kube_token_auth: true
|
kube_token_auth: true
|
||||||
kube_basic_auth: true
|
kube_basic_auth: true
|
||||||
enable_nodelocaldns: false
|
enable_nodelocaldns: false
|
||||||
|
|
Loading…
Reference in a new issue