summaryrefslogtreecommitdiff
path: root/roles/kubernetes/kubeadm/base/tasks/net_cilium.yml
blob: 733fbdec34e47d9516569becf2eed5eafd7a8315 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
---
- name: make sure local-redirect-policy is confgured when node-local dnscache is enabled
  run_once: yes
  assert:
    msg: "nodelocal dns-caches needs cilium local-redirect policies to be enabled, please enable it like this kubernetes_cilium_config['enable-local-redirect-policy'] = true."
    that: "(not kubernetes_enable_nodelocal_dnscache) or (('enable-local-redirect-policy' in kubernetes_cilium_config) and (kubernetes_cilium_config['enable-local-redirect-policy']))"

- name: make sure cilium local-redirect-policy is only enabled if cilium replaces kube-proxy
  run_once: yes
  assert:
    msg: "cilium local-redirect policies only work if cilium is used to replace kube-proxy, please set kubernetes_network_plugin_replaces_kube_proxy = yes."
    that: "('enable-local-redirect-policy' not in kubernetes_cilium_config) or (not kubernetes_cilium_config['enable-local-redirect-policy']) or kubernetes_network_plugin_replaces_kube_proxy"