minimal doc

This commit is contained in:
Stefan Le Breton 2024-11-19 22:12:57 +01:00
parent e1128fd67c
commit 0b020e6045
2 changed files with 47 additions and 0 deletions

View file

@ -1,5 +1,7 @@
# Setup talos cluster # Setup talos cluster
This will not be perfect, it's for my own use and for learning :)
## Requirements ## Requirements
* Hetzner customer :) * Hetzner customer :)
* Domain at Hetzner, not needed, can be removed/adapted * Domain at Hetzner, not needed, can be removed/adapted
@ -7,3 +9,27 @@
* tofu (Should work with terraform too) * tofu (Should work with terraform too)
* I use direnv to setup all the needed configuration variables * 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

21
test.tfvars.sample Normal file
View file

@ -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.<clustername>.<subdomain>.<zone>
# if subdomain is empty
# cpXX.<clustername>.<zone>
# used for reverse and forward dns
subdomain = "tf"
dns_zone = "somedomain.de"