How environments work
When you rungriffin init, a default environment is created automatically. You can add more:
Variables
Variables are stored ingriffin.variables.json at the project root and are scoped per environment. The file is intended to be checked in so teams can share variable keys and values. Use variables to change values like base URLs between environments:
variable() function:
griffin apply staging, the CLI resolves variable("API_HOST") to https://api.staging.example.com.
Secrets
Secrets are also scoped per environment. See Secrets for details.Deploying to environments
Most CLI commands accept an environment argument:default environment.
Managing environments
Removing an environment locally does not delete monitors already deployed to the hub for that environment. Use
griffin apply <env> --prune to clean up remote monitors.