mirror of
https://gitlab.durp.info/durfy/runbooks/ansible.git
synced 2026-05-09 16:51:40 -05:00
add k3s
This commit is contained in:
parent
dff9d8f725
commit
7619911e35
17 changed files with 2339 additions and 0 deletions
12
ansible/roles/k3s/master/defaults/main.yml
Normal file
12
ansible/roles/k3s/master/defaults/main.yml
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
---
|
||||
ansible_user: root
|
||||
server_init_args: >-
|
||||
{% if groups['master'] | length > 1 %}
|
||||
{% if ansible_hostname == hostvars[groups['master'][0]]['ansible_hostname'] %}
|
||||
--cluster-init
|
||||
{% else %}
|
||||
--server https://{{ hostvars[groups['master'][0]].k3s_node_ip }}:6443
|
||||
{% endif %}
|
||||
--token {{ k3s_token }}
|
||||
{% endif %}
|
||||
{{ extra_server_args | default('') }}
|
||||
Loading…
Add table
Add a link
Reference in a new issue