Hetzner Provider

Hetzner Cloud and Robot API integration, setup, and available resources.

Hetzner Provider

Overview

The Hetzner provider integrates with both the Hetzner Cloud API (for cloud instances) and the Hetzner Robot API (for dedicated servers). This dual integration gives you access to affordable cloud instances for development and testing alongside dedicated hardware for production workloads.

Setup

1. Generate API Token

  1. Log in to the Hetzner Cloud Console
  2. Select your project
  3. Navigate to Security > API Tokens
  4. Generate a new token with Read & Write permissions

2. Robot API Credentials (Optional)

For dedicated server management:

  1. Log in to Hetzner Robot
  2. Navigate to Settings > Webservice and app settings
  3. Generate API credentials

3. Configure AgentMetal

export HETZNER_API_TOKEN=hcloud_xxx
export HETZNER_ROBOT_USER=user        # optional
export HETZNER_ROBOT_PASSWORD=pass     # optional

Or in the configuration file:

providers:
  hetzner:
    enabled: true
    api_token: "hcloud_xxx"
    robot_user: "user"
    robot_password: "pass"

Available Server Types

Cloud Instances

TypevCPUsRAMDiskPrice/mo
cx1112 GB20 GB~3.29 EUR
cx2124 GB40 GB~5.83 EUR
cx3128 GB80 GB~10.49 EUR
cx41416 GB160 GB~17.49 EUR
cx51832 GB240 GB~29.99 EUR
### Dedicated Servers (via Robot)

Dedicated server availability varies. Use the provider API to list current offerings.

Locations

IDNameCountry
fsn1FalkensteinGermany
nbg1NurembergGermany
hel1HelsinkiFinland
## Features

Rescue Mode

Hetzner supports booting servers into rescue mode for recovery:

# The instance agent uses rescue mode during healing
agentmetal instance get inst-abc123  # Check if rescue is available

Floating IPs

Floating IPs can be assigned to any server in the same location:

# Managed automatically by the load balancer and DNS agents

Can also be managed via the provider API

curl -H "$AUTH" $API/v1/providers/hetzner/floating-ips

Volumes

Block storage volumes can be attached to cloud instances for additional storage beyond the root disk.

Limitations

  • Cloud instances are virtual, not bare-metal (use Robot for dedicated hardware)
  • Robot API provisioning takes longer than Cloud API (hours vs. minutes)
  • Locations limited to Germany and Finland