summaryrefslogtreecommitdiff
path: root/roles/kubernetes/kubeadm/master/tasks/net_kube-router.yml
blob: 0a21641434d9a636a14ed9c66413481b279f76c3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
---
- name: generate kube-router configuration
  template:
    src: "net_kube-router/config.{{ kubernetes_network_plugin_version }}.yml.j2"
    dest: /etc/kubernetes/network-plugin.yml

  ## TODO: move to server-side apply (GA since 1.22)
- name: install kube-router on to the cluster
  command: kubectl --kubeconfig /etc/kubernetes/admin.conf apply -f /etc/kubernetes/network-plugin.yml
  register: kube_router_apply_result
  changed_when: (kube_router_apply_result.stdout_lines | reject("regex", " unchanged$") | list | length) > 0