mirror of
https://gitea.fenix-dev.com/fenix-gitea-admin/iac-ansible-private.git
synced 2025-10-27 08:43:05 +00:00
Update roles/kube-master/tasks/main.yml
This commit is contained in:
@ -5,25 +5,25 @@
|
||||
|
||||
- name: Criar diretório .kube para o usuário ubuntu
|
||||
ansible.builtin.file:
|
||||
path: /home/ubuntu/.kube
|
||||
path: /home/fenix/.kube
|
||||
state: directory
|
||||
owner: ubuntu
|
||||
owner: fenix
|
||||
group: ubuntu
|
||||
mode: 0755
|
||||
|
||||
- name: Set up kubeconfig for user
|
||||
copy:
|
||||
src: /etc/kubernetes/admin.conf
|
||||
dest: /home/ubuntu/.kube/config
|
||||
dest: /home/fenix/.kube/config
|
||||
remote_src: yes
|
||||
owner: ubuntu
|
||||
owner: fenix
|
||||
group: ubuntu
|
||||
mode: 0644
|
||||
|
||||
- name: Install Calico CNI
|
||||
become: yes
|
||||
become_user: ubuntu
|
||||
become_user: fenix
|
||||
shell: |
|
||||
kubectl apply -f https://docs.projectcalico.org/manifests/calico.yaml
|
||||
environment:
|
||||
KUBECONFIG: /home/ubuntu/.kube/config
|
||||
KUBECONFIG: /home/fenix/.kube/config
|
||||
|
||||
Reference in New Issue
Block a user