system-config/playbooks/roles/install-kubectl/tasks/main.yaml
James E. Blair 94d404a535 Install kubectl on bridge
With a snap package.  Because apparently that's how that's done.

Change-Id: I0462cc062c2706509215158bca99e7a2ad58675a
2019-02-11 10:16:58 -08:00

17 lines
423 B
YAML

- name: Install snapd
package:
name: snapd
state: present
- name: Install kubectl
command: snap install kubectl --classic
# /snap/bin is often in the path, but not in a non-login shell, which
# makes it difficult to use via ansible. Add an extra symlink so we
# can always find it.
- name: Symlink snapd into /usr/local/bin
file:
src: /snap/bin/kubectl
dest: /usr/local/bin/kubectl
state: link