Skip to content

Environment variables

Server (tyr-server)

VariableDefaultRequiredDescription
DATABASE_URLyesPostgreSQL connection URL
TYR_WEB_DIR/usr/share/tyr/webnoPath to built Svelte UI static files
TYR_REST_NO_TLSfalsenoServe REST in plaintext (behind a terminating proxy)
TYR_REST_BIND0.0.0.0:7701noREST bind address
TYR_GRPC_BIND0.0.0.0:7700nogRPC bind address
TYR_DATA_DIR/var/lib/tyrnoWhere CA key and state live
TYR_BOOTSTRAP_ENROLLMENT_TOKENnoPre-seed an enrollment token (used by the quickstart compose)
RUST_LOGinfonoLog level (error / warn / info / debug / trace)

Agent (tyrd)

VariableDefaultRequiredDescription
TYR_SERVERyes*gRPC URL (http://…:7700 or https://…:7700). Can also be --server.
TYR_AGENT_NAMEhostnamenoHuman label. Can also be --name.
TYR_ENROLLMENT_TOKENyes (first boot)Bootstrap token
RUST_LOGinfonoLog level

*Required if not provided via --server.

CLI (tyr)

VariableDefaultDescription
TYR_SERVERhttps://localhost:7701Default REST endpoint

CLI auth token is stored at ~/.config/tyr/token — not environment-driven.

Docker Compose

The shipped docker-compose.yml uses these. Override by editing the file or passing -e:

Terminal window
docker compose run --rm -e RUST_LOG=debug tyr-server

Precedence summary

CLI flag > config file > environment variable > default.

The only exception is TYR_BOOTSTRAP_ENROLLMENT_TOKEN on the server — there’s no CLI flag or config file equivalent; it’s env-only.