From 0b020e6045160b9e0090f1cc2ed57e4d99da2b0f Mon Sep 17 00:00:00 2001 From: Stefan Le Breton Date: Tue, 19 Nov 2024 22:12:57 +0100 Subject: [PATCH] minimal doc --- README.md | 26 ++++++++++++++++++++++++++ test.tfvars.sample | 21 +++++++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 test.tfvars.sample diff --git a/README.md b/README.md index 744320c..17b3c85 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Setup talos cluster +This will not be perfect, it's for my own use and for learning :) + ## Requirements * Hetzner customer :) * Domain at Hetzner, not needed, can be removed/adapted @@ -7,3 +9,27 @@ * tofu (Should work with terraform too) * I use direnv to setup all the needed configuration variables +## Config + +### Required environment variables: + +``` +# to use hcloud command in shell, optional +export HCLOUD_TOKEN=.... +# for provider setup +export TF_VAR_hcloud_token=$HCLOUD_TOKEN + +# provider setup +export HETZNER_DNS_API_TOKEN=... + +# not needed, but useful when used with direnv in .envrc file +# tofu output -raw kubeconfig >kubeconfig; tofu output -raw talosconfig >talosconfig +export KUBECONFIG=kubeconfig +export TALOSCONFIG=talosconfig + +``` + +### Input Parameter + +see test.tfvars.sample + diff --git a/test.tfvars.sample b/test.tfvars.sample new file mode 100644 index 0000000..0969294 --- /dev/null +++ b/test.tfvars.sample @@ -0,0 +1,21 @@ + +hcloud_datacenter = "nbg1-dc3" +hcloud_network_zone = "eu-central" +hcloud_server_type_cp = "cx22" +hcloud_server_type_wk = "cx22" + +talos_version = "v1.8.3" +talos_cluster_name = "talos-test" +talos_num_cp = 1 +talos_num_wk = 3 + +# DNS + +# naming of nodes: +# I use dnscontrol, to ignore automatically generated entries, I ignore this subdomain in dnscontrol +# cpXX... +# if subdomain is empty +# cpXX.. +# used for reverse and forward dns +subdomain = "tf" +dns_zone = "somedomain.de"