NAME
hcloud.pl - Hetzner Cloud CLI (Perl implementation)
VERSION
version 0.101
SYNOPSIS
# List servers
hcloud.pl server
# Create a server (minimal)
hcloud.pl server create --name my-server --type cx22 --image debian-12
# Create a server (full options)
hcloud.pl server create \
--name my-server \
--type cx22 \
--image debian-12 \
--location fsn1 \
--ssh-key my-key \
--label env=prod \
--label team=ops \
--user-data-from-file cloud-init.yaml
# Create without public IPv4
hcloud.pl server create --name private-server --type cx22 --image debian-12 \
--without-ipv4 --network 12345
# Delete a server
hcloud.pl server delete 12345
# Describe a server
hcloud.pl server describe 12345
# List server types
hcloud.pl servertype
# JSON output
hcloud.pl -o json server
DESCRIPTION
Perl implementation of the Hetzner Cloud CLI tool (hcloud). This script provides a command-line interface to the Hetzner Cloud API.
To avoid conflicts with the official hcloud binary, this script is named hcloud.pl. You can create an alias if desired:
alias hcloud='perl /path/to/hcloud.pl'
OPTIONS
- -t, --token=TOKEN
-
Hetzner Cloud API token. Defaults to
HETZNER_API_TOKENenvironment variable. - -o, --output=FORMAT
-
Output format:
table(default) orjson.
COMMANDS
server
Manage servers.
server create
Create a new server. Required options: --name, --type, --image.
hcloud.pl server create --name web1 --type cx22 --image debian-12
Options:
--name Server name (required)
--type Server type, e.g., cx22, cpx11 (required)
--image Image name, e.g., debian-12 (required)
--location Location: fsn1, nbg1, hel1, ash, hil
--datacenter Datacenter, e.g., fsn1-dc14
--ssh-key SSH key name or ID (repeatable)
--label Label as key=value (repeatable)
--network Network ID to attach (repeatable)
--volume Volume ID to attach (repeatable)
--firewall Firewall ID (repeatable)
--placement-group Placement group ID or name
--user-data-from-file Path to cloud-init file
--without-ipv4 Create without public IPv4
--without-ipv6 Create without public IPv6
--primary-ipv4 Assign existing Primary IPv4
--primary-ipv6 Assign existing Primary IPv6
--automount Automount attached volumes
--no-start-after-create Don't start server after creation
server list
List all servers.
server describe <ID>
Show details for a server.
server delete <ID>
Delete a server.
sshkey
Manage SSH keys.
image
List images. Use --type to filter by type (system, snapshot, backup).
servertype
List available server types.
iso
List ISOs. Use --architecture to filter by architecture (x86, arm) and --name to look up a single ISO by its exact name.
placement-group
Manage placement groups.
network
Manage private networks.
firewall
Manage firewalls.
floating-ip
Manage floating IPs.
primary-ip
Manage primary IPs.
load-balancer
Manage load balancers.
load-balancer-type
List available load balancer types.
volume
Manage volumes.
storage-box
Manage Storage Boxes.
zone
Manage DNS zones.
record
Manage DNS records.
certificate
Manage TLS certificates.
pricing
Show the current price list.
location
List available locations.
datacenter
List available datacenters.
ENVIRONMENT
HETZNER_API_TOKEN-
Default API token if not specified via
--token.
SEE ALSO
WWW::Hetzner::CLI, WWW::Hetzner::Cloud, https://docs.hetzner.cloud/
SUPPORT
Issues
Please report bugs and feature requests on GitHub at https://github.com/Getty/p5-www-hetzner/issues.
IRC
Join #kubernetes on irc.perl.org or message Getty directly.
CONTRIBUTING
Contributions are welcome! Please fork the repository and submit a pull request.
AUTHOR
Torsten Raudssus <torsten@raudssus.de>
COPYRIGHT AND LICENSE
This software is copyright (c) 2026 by Torsten Raudssus <torsten@raudssus.de> https://raudssus.de/.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.