Need help on deploy. #71
-
Hi, Thanks Xan for your work. Let me buy you coffees . I have tried to create the k3s cluster however seems failing since yesterday. Need ur advise the playbook. Im sorry i still quite new to ansible. I have deployed 2 KVM(bionic) for controlplane and 4 kvm(bionic) for worker with 1 loadbalance (npm-stream to both control node k3s-master1 and k3s-master2) and 1 LXC running docker-compose with postgress database. The ansible-control machine where i play my playbook seems done but have error. RUNNING HANDLER [kvm-k3s-deploy : restart k3s] *************************************************************************************************************************************************************** When I log in to k3s-master1 (one of my controlplane) user@k3s-master1: here is the detials of my /etc/rancher/k3s/config.yaml cluster-cidr: 192.168.0.16/26 My-playbook.yml
My-Inventory.yml k3s_cluster: k3s_workers: I belive that my variable is for playbook is wrong. Please help me with the inventory that I have. I have plan to have 2 control plane (taint-mode) with 4 worker node. Thanks in advance. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 11 replies
-
Hi @nnps255 Sorry for the delayed response, I've been a touch busy/unwell. Do you want to give this a try? I've not tested it but I've re-worked your config in a way that I believe should work.
|
Beta Was this translation helpful? Give feedback.
-
Hey Thanks Xan, I definitely will try this.. I am busy with glusterfs.. just done some deployment. I will let you know the outcome. Btw thank you very very much for your reply.. Feel exited to try it soon! |
Beta Was this translation helpful? Give feedback.
Hi @nnps255
Sorry for the delayed response, I've been a touch busy/unwell.
Do you want to give this a try? I've not tested it but I've re-worked your config in a way that I believe should work.
inventory.yml
I've put all the config in here as it is convenient for sharing in GitHub discussions. You can start to separate config out of inventory if you need, either via putting it in playbooks or making use of group_vars/ or host_vars/ - see https://docs.ansible.com/ansible/latest/user_guide/playbooks_variables.html#define-variables-in-inventory for more details.