config
Manages profiles. A profile holds one environment's API address, session and defaults, kept in ~/.octri/config.json. On its own, octri config prints the current profile with any stored secrets shown as <stored>.
Values resolve in this order: a flag, then an environment variable, then the profile. See global flags for the variables.
octri config [list | set <key> <value> | use <profile> | path]octri config list
Prints the current profile's settings and the file they're kept in. Tokens and API keys show as <stored>, never their values. --profile <name> prints another profile.
octri config set <key> <value>
Changes one setting in the current profile. Sessions can't be set by hand: sign in for those.
Arguments
<key>stringrequiredThe setting to change.
| Value | Meaning |
|---|---|
apiUrl | The API address. Takes local, a host or a full URL |
defaultProject | The project commands act on when you don't pass --project |
defaultLanguages | Comma-separated languages for sdk build and lab run when you don't pass --lang |
apiKey | An API key to authenticate with instead of a session, for CI |
<value>stringrequiredThe new value. Everything after the key is the value.
octri config use <profile>
Switches to another profile, creating it if it doesn't exist. Later commands use it until you switch again.
Arguments
<profile>stringrequiredThe profile's name, such as prod or local.
Flags
--api-url <url>stringSets the profile's API address. local is short for http://localhost:3001.
octri config path
Prints where the config file is. OCTRI_CONFIG_DIR moves it.
Examples
Show the current profile
octri configProfile default
apiUrl https://api.octri.dev/api/v1
accessToken <stored>
refreshToken <stored>
email dana.reyes@acmesoftware.io
orgId 6acd4f5218c2528b59327448
defaultProject 6acd4f5218c2528b5932744f
defaultLanguages go, typescript, python
~/.octri/config.jsonSet default languages
octri config set defaultLanguages go,typescript,python✔ defaultLanguages = go,typescript,pythonKeep a local stack beside production
octri config use local --api-url local
octri auth login
octri config use defaultRelated
octri auth profiles: List the profiles on this machine and which one is in use.octri auth login: Sign in to Octri and store the session in your profile.- Global flags: Flags and environment variables every command takes.