gibil create
Forge a Linux box on demand
The core command. Generates SSH keys, creates a server on your chosen provider (Hetzner or Vultr), attaches a cloud-init script, and waits until the box is ready to use.
Usage
gibil create [options]Description
Forges a new Gibil box. Generates SSH keys, creates a server on your chosen provider, uploads your SSH key, attaches a cloud-init script, and waits until the box is ready. Set --ttl anywhere from 15m to 30d; extend it later with gibil extend if the work runs long.
Options
| Flag | Description | Default |
|---|---|---|
--name <name> | Server name | auto-generated |
--repo <url> | GitHub repo URL to clone | — |
--ttl <duration> | Time-to-live (30m, 2h, 7d, 1y, or plain minutes) | 60 |
--fleet <count> | Create N servers in parallel | 1 |
--config <path> | Path to .gibil.yml | auto-detected |
--provider <name> | Cloud provider (hetzner or vultr) | configured default |
--size <size> | Provider-agnostic size (small, medium, large) | provider default |
--server-type <native> | Native SKU — overrides --size (e.g. cax21, vc2-4c-8gb) | auto-detected |
--location <loc> | Datacenter location (fsn1, nrt, sgp, ...) | provider default |
-e, --env <KEY=VALUE> | Environment variables (repeatable) | — |
--dry-run | Print what would be created without calling the provider API | false |
--json | Output as JSON | false |
Examples
# Basic — forge a server on the default provider
gibil create --name my-app
# With a repo — clones and runs tasks from .gibil.yml
gibil create --name my-app --repo https://github.com/you/project --ttl 30m
# Pick a specific cloud and region (e.g. Tokyo on Vultr)
gibil create --name tokyo --provider vultr --location nrt --size small --ttl 30m
# Fleet mode — 3 servers in parallel
gibil create --name fleet --fleet 3 --ttl 15
# JSON output for AI agents
gibil create --name agent-task --repo https://github.com/you/repo --json --ttl 20
# Native SKU override (escape hatch when --size doesn't fit)
gibil create --name benchmark --server-type cax31 --location fsn1What happens
- Resolves the provider from
--provideror the configured default - Reads provider-specific defaults from
~/.gibil/config.json - Generates SSH key pair →
~/.gibil/keys/<name>/id_ed25519 - Uploads public key to the chosen provider
- Generates cloud-init script (installs runtime, Docker, clones repo)
- Creates the server with cloud-init + SSH key
- Polls until server status = running
- Polls until SSH port 22 responds
- Polls until cloud-init is complete (
/root/.gibil-ready, 6 min timeout) - Saves instance metadata (including
provider) to~/.gibil/instances/<name>.json
JSON output
{
"name": "my-app",
"ip": "49.13.42.101",
"server_id": 12345678,
"status": "ready",
"ttl": 30,
"created_at": "2024-01-15T10:30:00Z"
}The CLI waits for cloud-init to complete (polls /root/.gibil-ready with a 6 minute timeout) before returning. Your server is fully provisioned when the command finishes.
Next steps
- gibil ssh — connect to your server
- gibil run — execute commands remotely
- Configuration — customize with
.gibil.yml - Fleet Mode — create multiple servers at once