2017-09-04 08:29:51 +00:00
|
|
|
kind: ConfigMap
|
|
|
|
apiVersion: v1
|
|
|
|
metadata:
|
|
|
|
name: calico-config
|
2018-03-30 11:29:13 +00:00
|
|
|
namespace: kube-system
|
2017-09-04 08:29:51 +00:00
|
|
|
data:
|
2019-04-25 12:00:48 +00:00
|
|
|
{% if calico_datastore == "etcd" %}
|
2017-10-04 12:27:55 +00:00
|
|
|
etcd_endpoints: "{{ etcd_access_addresses }}"
|
2017-09-04 08:29:51 +00:00
|
|
|
etcd_ca: "/calico-secrets/ca_cert.crt"
|
|
|
|
etcd_cert: "/calico-secrets/cert.crt"
|
|
|
|
etcd_key: "/calico-secrets/key.pem"
|
2019-10-17 14:02:38 +00:00
|
|
|
{% elif calico_datastore == "kdd" and typha_enabled %}
|
2019-04-25 12:00:48 +00:00
|
|
|
# To enable Typha, set this to "calico-typha" *and* set a non-zero value for Typha replicas
|
|
|
|
# below. We recommend using Typha if you have more than 50 nodes. Above 100 nodes it is
|
|
|
|
# essential.
|
|
|
|
typha_service_name: "calico-typha"
|
|
|
|
{% endif %}
|
2022-03-18 01:05:39 +00:00
|
|
|
{% if calico_network_backend == 'bird' %}
|
2017-09-04 08:29:51 +00:00
|
|
|
cluster_type: "kubespray,bgp"
|
|
|
|
calico_backend: "bird"
|
2022-03-18 01:05:39 +00:00
|
|
|
{% else %}
|
|
|
|
cluster_type: "kubespray"
|
|
|
|
calico_backend: "{{ calico_network_backend }}"
|
2018-09-27 10:31:14 +00:00
|
|
|
{% endif %}
|
2021-04-29 12:20:50 +00:00
|
|
|
{% if inventory_hostname in groups['k8s_cluster'] and peer_with_router|default(false) %}
|
2018-02-06 00:38:05 +00:00
|
|
|
as: "{{ local_as|default(global_as_num) }}"
|
|
|
|
{% endif -%}
|