Config file
The default config file lives at~/.infraudit/config.yaml. You can override the path on any command with --config /path/to/config.yaml.
The file is created automatically by infraudit config init or infraudit auth login with 0600 permissions so the stored token is not world-readable.
File structure
The CLI refreshes
auth.token automatically when it expires, as long as auth.refresh_token is still valid.
Managing config values
Use theconfig subcommands to read and write individual values without editing the file by hand:
Environment variables
Two environment variables override the config file without modifying it:
These are useful for one-off commands or CI/CD pipelines where you don’t want to touch the config file:
Multiple environments
If you work against more than one InfraAudit instance — for example, a local development server, a staging environment, and production — keep a separate config file per environment and point--config at the correct one:
INFRAUDIT_SERVER_URL per shell session before running commands.
Security notes
- The config file is created with
0600permissions. Do not change this. - In CI/CD pipelines, authenticate using
infraudit auth login --email "$CI_EMAIL" --password "$CI_PASSWORD"sourced from secrets rather than copying the config file into the build environment. See CI/CD usage for a complete example. - Each team member should maintain their own config file with their own credentials.