Last active
July 8, 2019 09:11
-
-
Save SarasaGunawardhana/cf2cee13a7e5a162dd0c17455cf2ea90 to your computer and use it in GitHub Desktop.
Kubeadm initiate configuration file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: kubeadm.k8s.io/v1beta1 | |
kind: ClusterConfiguration #you will need to ensure they match the version of the Kubernetes control plane of kubectl and kubeadm | |
kubernetesVersion: v1.14.3 | |
apiServer: | |
certSANs: #Additional hostnames or IP addresses that should be added to the Subject Alternate Name section for the certificate that the API Server will use. If you expose the API Server through a load balancer and public DNS you could specify this with | |
- 127.0.0.1 | |
- 157.180.200.132 | |
- do-dev-master.sarasa-dev.com | |
extraArgs: # Add this section if you have setup default audit policy. if not, dont add this section | |
authorization-mode: Node,RBAC | |
feature-gates: "TTLAfterFinished=true" #Allow a TTL controller to clean up resources after they finish execution. more details: https://kubernetes.io/docs/reference/command-line-tools-reference/feature-gates/ | |
audit-policy-file: "/etc/kubernetes/audit-policy.yaml" #we created a default policy file in last artical (Prerequisites for Setup Kubenetes Cluster| Part 2) | |
audit-log-path: "/etc/kubernetes/audit/kube-apiserver-audit.log" | |
audit-log-maxage: "2" | |
extraVolumes: # Add this section if you have setup default audit policy. if not, dont add this section | |
- name: "audit-policy" | |
hostPath: "/etc/kubernetes/audit-policy.yaml" | |
mountPath: "/etc/kubernetes/audit-policy.yaml" | |
readOnly: false | |
pathType: File | |
- name: "audit-volume" | |
hostPath: "/var/log/kubernetes/audit" | |
mountPath: "/etc/kubernetes/audit" | |
readOnly: false | |
pathType: DirectoryOrCreate | |
timeoutForControlPlane: 4m0s | |
certificatesDir: /etc/kubernetes/pki | |
clusterName: kubernetes | |
controlPlaneEndpoint: "" | |
controllerManager: | |
extraArgs: | |
feature-gates: "TTLAfterFinished=true" | |
bind-address: 0.0.0.0 | |
dns: | |
type: CoreDNS | |
etcd: | |
local: | |
dataDir: /var/lib/etcd | |
imageRepository: k8s.gcr.io | |
networking: | |
dnsDomain: cluster.local | |
podSubnet: 10.244.0.0/16 | |
serviceSubnet: 10.225.100.0/24 | |
scheduler: | |
extraArgs: | |
feature-gates: "TTLAfterFinished=true" | |
bind-address: 0.0.0.0 | |
--- | |
apiVersion: kubelet.config.k8s.io/v1beta1 | |
kind: KubeletConfiguration | |
FeatureGates: | |
TTLAfterFinished: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment