You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Ansible-roles/kubernetes/tasks/k8s_deploy.yml

29 lines
622 B
YAML

- name: Add Google-Cloud key
apt_key:
url: https://packages.cloud.google.com/apt/doc/apt-key.gpg
state: present
- name: Add Kubernetes Repository
apt_repository:
repo: "deb https://apt.kubernetes.io/ kubernetes-xenial main"
state: present
filename: kubernetes
update_cache: yes
- name: Install kubernetes-tools
package:
name:
- kubeadm
- kubelet
- kubectl
state: latest
- name: Hold upgrades for kubernetes-tools
dpkg_selections:
name: "{{ item }}"
selection: hold
loop:
- kubeadm
- kubelet
- kubectl