Prototype KubeClaw is a learning project exploring what a secure, scalable Kubernetes environment for AI agents looks like. It is not production ready and not beta. Expect breaking changes and unreviewed assumptions. Read the project status.

Variables Reference

Every OpenTofu input variable with its type, default, and effect.

All configurable inputs for the OpenTofu infrastructure. Set these in terraform.tfvars.

Required Variables

VariableTypeDescription
hcloud_tokenstringHetzner Cloud API Token (sensitive)

Cluster Configuration

VariableTypeDefaultDescription
cluster_namestring"k8s-cluster"Name prefix for all resources
locationstring"fsn1"Hetzner Cloud location (fsn1, nbg1, hel1, ash, hil)

Network Configuration

VariableTypeDefaultDescription
network_ip_rangestring"10.0.0.0/8"IP range for the private network
subnet_ip_rangestring"10.0.0.0/24"IP range for the subnet
network_zonestring"eu-central"Network zone (eu-central, us-east, us-west)
enable_public_ipv6booltrueEnable public IPv6 for replica control nodes and worker nodes. The master always has public IPv6 (required for cloudflared). Setting to false air-gaps replicas and workers.

Server Configuration

VariableTypeDefaultDescription
server_imagestring"debian-13"Server image to use
master_control_node_typestring"cx23"Server type for the master control node (runs cloudflared)
control_node_typeslist(object({type, count}))[]Server types and counts for replica control nodes
worker_node_typeslist(object({type, count}))[]Server types and counts for worker nodes

The cost-optimized x86 line is cx23, cx33, cx43, and cx53; the Arm equivalents are cax11 through cax41. See Cost Estimate for specifications, current prices, and the constraints on the Arm line.

Node type examples

# Master-only (default)
master_control_node_type = "cx23"
control_node_types = []
worker_node_types  = []

# 3 control nodes + 2 workers
control_node_types = [
  { type = "cx23", count = 2 },
]
worker_node_types = [
  { type = "cx23", count = 2 },
]

# Mixed worker types
worker_node_types = [
  { type = "cx23", count = 2 },
  { type = "cx33", count = 1 },
]

Authentication

VariableTypeDefaultDescription
root_passwordstring"ChangeMe123!"Root password for emergency Web-Console access (sensitive)
admin_userstring"kubernetes-admin"Admin user name for SSH access
keyboard_layoutstring"de"Keyboard layout for cloud-init

SSH Keys

If left empty, new keys will be auto-generated and stored in the OpenTofu state. When using custom keys, manage private keys yourself.

VariableTypeDefaultDescription
control_node_public_keystring""Public SSH key for control nodes. Leave empty to auto-generate.
worker_node_public_keystring""Public SSH key for worker nodes. Leave empty to auto-generate.
admin_node_public_keystring""Public SSH key for admin node. Leave empty to auto-generate.
ssh_key_prefixstring""Prefix for SSH key filenames. Defaults to cluster_name if empty.

Cloudflare Configuration

VariableTypeDefaultDescription
cloudflare_tunnel_domainstring""Domain for Cloudflare Tunnel SSH access (e.g., console.example.org)
cloudflare_tunnel_tokenstring""Cloudflare Tunnel token for automatic setup on master node (sensitive). Leave empty for manual setup.

Admin Node

VariableTypeDefaultDescription
enable_admin_nodebooltrueEnable a temporary admin node with public IPv6 for initial SSH access. Disable after Cloudflare Tunnel is configured.
admin_node_typestring"cx23"Server type for admin node

NAT64/DNS64

VariableTypeDefaultDescription
enable_nat64booltrueEnable NAT64/DNS64 for IPv4 reachability on IPv6-only nodes
dns64_resolverslist(string)["2a01:4f8:c2c:123f::1", "2a01:4f9:c010:3f02::1", "2a00:1098:2b::1"]DNS64 resolver addresses (nat64.net: Nuremberg, Helsinki, Amsterdam)

Kubernetes

VariableTypeDefaultDescription
enable_k8s_prereqsbooltrueInstall Kubernetes prerequisites (container runtime, kubeadm, kubelet, kubectl) via cloud-init
kubernetes_versionstring"1.32"Kubernetes minor version for the pkgs.k8s.io apt source
container_runtimestring"containerd"Container runtime for Kubernetes nodes: "containerd" or "cri-o"