From 221ba2f08f8e0068372e5dc4cde7a6092c842058 Mon Sep 17 00:00:00 2001 From: Marko Vukovic <8951449+anon-software@users.noreply.github.com> Date: Mon, 11 Nov 2024 12:57:18 -0800 Subject: [PATCH] Document that token is (mostly) optional now The token is still required when using Vagrant. Signed-off-by: Marko Vukovic <8951449+anon-software@users.noreply.github.com> --- Vagrantfile | 1 + inventory-sample.yml | 1 + 2 files changed, 2 insertions(+) diff --git a/Vagrantfile b/Vagrantfile index c26c6270e..4f4c7c058 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -28,6 +28,7 @@ def provision(vm, role, node_num) ansible.extra_vars = { k3s_version: "v1.28.14+k3s1", api_endpoint: "#{NETWORK_PREFIX}.100", + # Required for vagrant ansible provisioner token: "myvagrant", # Required to use the private network configured above extra_server_args: "--node-external-ip #{node_ip} --flannel-iface eth1", diff --git a/inventory-sample.yml b/inventory-sample.yml index 8c09d3fb4..e237881fd 100644 --- a/inventory-sample.yml +++ b/inventory-sample.yml @@ -19,6 +19,7 @@ k3s_cluster: # - openssl rand -base64 64 # - pwgen -s 64 1 # You can use ansible-vault to encrypt this value / keep it secret. + # Or you can omit it if not using Vagrant and let the first server automatically generate one. token: "changeme!" api_endpoint: "{{ hostvars[groups['server'][0]]['ansible_host'] | default(groups['server'][0]) }}" extra_server_args: ""