c12s-kubespray/roles/kubernetes/master/templates/manifests/kubeadm-kube-controller-manager.json.j2
Bogdan Dobrelya 6fa44458db Add kubeadm init, join
* Implement kubeadm init,join for Debian OS family (PoC) with
  the external etcd option set.
* Make certs/tokens management optional and depending on
  the use_kubeadm var
* Do not delegate static pods and config management to kubeadm
  and remove produced artifacts to be regenerated by ansible.
* Add new set of system pods manifests templates based on that kubeadm
  produces by default and parametrize it by ansible vars
* Fix apiserver container logging to follow 12-factor apps
  and scheduler/controller-manager logging setup

Signed-off-by: Bogdan Dobrelya <bdobrelia@mirantis.com>
2016-10-20 11:34:13 +02:00

88 lines
2.6 KiB
Django/Jinja

{
"kind": "Pod",
"apiVersion": "v1",
"metadata": {
"name": "kube-controller-manager",
"namespace": "kube-system",
"creationTimestamp": null,
"labels": {
"component": "kube-controller-manager",
"tier": "control-plane"
}
},
"spec": {
"volumes": [
{% if cloud_provider is defined and cloud_provider == "openstack" %}
{
"name": "cloudconfig",
"hostPath": {
"path": "{{ kube_config_dir }}/cloud_config"
}
},
{% endif %}
{
"name": "pki",
"hostPath": {
"path": "{{ kube_config_dir }}"
}
}
],
"containers": [
{
"name": "kube-controller-manager",
"image": "{{ hyperkube_image_repo }}:{{ hyperkube_image_tag }}",
"command": [
"/hyperkube",
"controller-manager",
"--v={{ kube_log_level | default('2') }}",
"--address=127.0.0.1",
"--leader-elect",
"--master={{ kube_apiserver_endpoint }}",
"--enable-hostpath-provisioner={{ kube_hostpath_dynamic_provisioner }}",
"--cluster-name=kubernetes",
"--root-ca-file={{ kubeadm_certs_dir }}/ca.pem",
"--service-account-private-key-file={{ kubeadm_certs_dir }}/apiserver-key.pem",
"--cluster-signing-cert-file={{ kubeadm_certs_dir }}/ca.pem",
"--cluster-signing-key-file={{ kubeadm_certs_dir }}/ca-key.pem",
{% if cloud_provider is defined and cloud_provider == "openstack" %}
"--cloud-provider={{cloud_provider}}",
"--cloud-config={{ kube_config_dir }}/cloud_config",
{% elif cloud_provider is defined and cloud_provider == "aws" %}
"--cloud-provider={{cloud_provider}}",
{% endif %}
"--insecure-experimental-approve-all-kubelet-csrs-for-group=system:kubelet-bootstrap"
],
"resources": {
"requests": {
"cpu": "200m"
}
},
"volumeMounts": [
{% if cloud_provider is defined and cloud_provider == "openstack" %}
{
"name": "cloudconfig",
"readOnly": true,
"mountPath": "{{ kube_config_dir }}/cloud_config"
},
{% endif %}
{
"name": "pki",
"readOnly": true,
"mountPath": "{{ kube_config_dir }}"
}
],
"livenessProbe": {
"httpGet": {
"path": "/healthz",
"port": 10252,
"host": "127.0.0.1"
},
"initialDelaySeconds": 15,
"timeoutSeconds": 15
}
}
],
"hostNetwork": true
},
"status": {}
}