2019-07-08 17:20:03 +08:00
|
|
|
#!/bin/bash
|
|
|
|
DATASTORE_TYPE=kubernetes \
|
2021-03-24 08:26:05 +08:00
|
|
|
{% if inventory_hostname in groups['kube_control_plane'] %}
|
2019-07-15 16:59:06 +08:00
|
|
|
KUBECONFIG=/etc/kubernetes/admin.conf \
|
|
|
|
{% else %}
|
|
|
|
KUBECONFIG=/etc/cni/net.d/calico-kubeconfig \
|
2019-07-08 17:20:03 +08:00
|
|
|
{% endif %}
|
|
|
|
{{ bin_dir }}/calicoctl "$@"
|