GibilGibil

Environment Variables

Environment variables used by the Gibil CLI

CLI environment variables

VariableRequiredDescription
HETZNER_API_TOKENOne of these*Hetzner Cloud API token
VULTR_API_KEYOne of these*Vultr personal access token
GIBIL_API_KEYNoGibil API key for authenticated usage and metering
GIBIL_API_URLNoOverride Supabase Edge Functions URL
GIBIL_HOMENoOverride ~/.gibil (used in tests)
GITHUB_TOKENNoGitHub token for private repo access on VMs

* You need a token for at least one provider. Either env var or ~/.gibil/config.json works.

How tokens are resolved

Provider tokens (Hetzner, Vultr)

For each provider, gibil checks in order:

  1. ~/.gibil/config.json under providers.<name>.token (set via gibil init or gibil auth setup)
  2. The provider-specific env var (HETZNER_API_TOKEN, VULTR_API_KEY)
  3. .env file in current directory (auto-loaded via dotenv)

Gibil API key

  1. ~/.gibil/config.json (set via gibil auth login --key)
  2. GIBIL_API_KEY environment variable

VM environment variables

Variables defined in .gibil.yml env: section are set on the VM:

env:
  DATABASE_URL: postgres://localhost/myapp
  NODE_ENV: development

These are:

  • Exported in the cloud-init script
  • Persisted in /root/.bashrc
  • Available in all SSH sessions and gibil run commands

On this page