Skip to content
This repository was archived by the owner on Oct 31, 2019. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions instances/k8smaster/cloud_init/bootstrap.template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,11 @@ write_files:
encoding: "gzip+base64"
content: |
${ca-pem-content}
- path: "/etc/kubernetes/ssl/ca-key.pem"
permissions: "0600"
encoding: "gzip+base64"
content: |
${ca-key-content}
- path: "/etc/kubernetes/ssl/apiserver.pem"
permissions: "0600"
encoding: "gzip+base64"
Expand Down
1 change: 1 addition & 0 deletions instances/k8smaster/datasources.tf
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ data "template_file" "kube_master_cloud_init_file" {
kube_scheduler_template_content = "${base64gzip(data.template_file.kube-scheduler.rendered)}"
kubelet_service_content = "${base64gzip(data.template_file.kubelet-service.rendered)}"
ca-pem-content = "${base64gzip(var.root_ca_pem)}"
ca-key-content = "${base64gzip(var.root_ca_key)}"
api-server-key-content = "${base64gzip(var.api_server_private_key_pem)}"
api-server-cert-content = "${base64gzip(var.api_server_cert_pem)}"
api-token_auth_template_content = "${base64gzip(data.template_file.token_auth_file.rendered)}"
Expand Down
2 changes: 2 additions & 0 deletions instances/k8smaster/manifests/kube-controller-manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ spec:
- --leader-elect=true
- --service-account-private-key-file=/etc/kubernetes/ssl/apiserver-key.pem
- --root-ca-file=/etc/kubernetes/ssl/ca.pem
- --cluster-signing-cert-file=/etc/kubernetes/ssl/ca.pem
- --cluster-signing-key-file=/etc/kubernetes/ssl/ca-key.pem
- --v=2
livenessProbe:
httpGet:
Expand Down
5 changes: 0 additions & 5 deletions instances/k8smaster/manifests/kubernetes-dashboard.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,13 @@ spec:
- containerPort: 9090
protocol: TCP
args:
# Uncomment the following line to manually specify Kubernetes API server Host
# If not specified, Dashboard will attempt to auto discover the API server and connect
# to it. Uncomment only if the default does not work.
# - --apiserver-host=http://my-address:port
livenessProbe:
httpGet:
path: /
port: 9090
initialDelaySeconds: 30
timeoutSeconds: 30
serviceAccountName: kubernetes-dashboard
# Comment the following tolerations if Dashboard must not be deployed on master
tolerations:
- key: node-role.kubernetes.io/master
effect: NoSchedule
Expand Down
1 change: 1 addition & 0 deletions instances/k8smaster/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ variable "k8s_dns_ver" {
variable "api_server_count" {}

variable "root_ca_pem" {}
variable "root_ca_key" {}
variable "api_server_private_key_pem" {}
variable "api_server_cert_pem" {}
variable "k8s_apiserver_token_admin" {}
Expand Down
3 changes: 3 additions & 0 deletions k8s-oci.tf
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,7 @@ module "instances-k8smaster-ad1" {
k8s_ver = "${var.k8s_ver}"
label_prefix = "${var.label_prefix}"
root_ca_pem = "${module.k8s-tls.root_ca_pem}"
root_ca_key = "${module.k8s-tls.root_ca_key}"
shape = "${var.k8sMasterShape}"
ssh_private_key = "${module.k8s-tls.ssh_private_key}"
ssh_public_key_openssh = "${module.k8s-tls.ssh_public_key_openssh}"
Expand Down Expand Up @@ -263,6 +264,7 @@ module "instances-k8smaster-ad2" {
k8s_ver = "${var.k8s_ver}"
label_prefix = "${var.label_prefix}"
root_ca_pem = "${module.k8s-tls.root_ca_pem}"
root_ca_key = "${module.k8s-tls.root_ca_key}"
shape = "${var.k8sMasterShape}"
ssh_private_key = "${module.k8s-tls.ssh_private_key}"
ssh_public_key_openssh = "${module.k8s-tls.ssh_public_key_openssh}"
Expand Down Expand Up @@ -305,6 +307,7 @@ module "instances-k8smaster-ad3" {
k8s_ver = "${var.k8s_ver}"
label_prefix = "${var.label_prefix}"
root_ca_pem = "${module.k8s-tls.root_ca_pem}"
root_ca_key = "${module.k8s-tls.root_ca_key}"
shape = "${var.k8sMasterShape}"
ssh_private_key = "${module.k8s-tls.ssh_private_key}"
ssh_public_key_openssh = "${module.k8s-tls.ssh_public_key_openssh}"
Expand Down