Create join-workers.yml

This commit is contained in:
BuildVirtual 2021-07-12 12:02:08 +01:00 committed by GitHub
parent c410f299d7
commit f8eaab3588
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -0,0 +1,16 @@
- hosts: workers
become: yes
gather_facts: yes
tasks:
- name: Copy join command from Ansiblehost to the worker nodes.
become: yes
copy:
src: /tmp/kubernetes_join_command
dest: /tmp/kubernetes_join_command
mode: 0777
- name: Join the Worker nodes to the cluster.
become: yes
command: sh /tmp/kubernetes_join_command
register: joined_or_not