Strix automatically saves your environment variables to a configuration file atDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/usestrix/strix/llms.txt
Use this file to discover all available pages before exploring further.
~/.strix/cli-config.json. This allows you to configure Strix once and have your settings persist across runs.
Location
The default configuration file is located at:--config flag:
File Format
The configuration file uses JSON format and stores environment variables in anenv object:
How It Works
Automatic Saving
When you run Strix with environment variables set, they are automatically saved to the config file:Automatic Loading
On subsequent runs, Strix automatically loads saved configuration:- Strix reads
~/.strix/cli-config.json - Applies saved variables if they’re not already set in the environment
- Uses environment variables if they’re set (they take precedence)
Configuration Priority
Strix uses this priority order for configuration:- Environment variables - Highest priority
- Custom config file (via
--config) - Overrides default config - Default config file (
~/.strix/cli-config.json) - Lowest priority
Managing Configuration
View Current Configuration
To see your saved configuration, read the file:jq for pretty printing:
Update Configuration
You can update configuration in two ways:Method 1: Set Environment Variables
Set new environment variables and run Strix. They will be automatically saved:Method 2: Edit Config File Directly
Edit~/.strix/cli-config.json manually:
Clear Configuration
To remove a specific variable, set it to an empty string:STRIX_LLM from the saved configuration.
To clear all configuration, delete the file:
Validate Configuration
Strix validates the configuration file on startup. If the file is corrupted or invalid, Strix will:- Log a warning
- Ignore the invalid configuration
- Use environment variables or defaults
Security Considerations
File Permissions
The config file is automatically created with restricted permissions (0600 on Unix-like systems):
Storing Secrets
While the config file is convenient, consider these alternatives for sensitive data:- Environment variables - Don’t persist to disk
- Secret management tools - Use tools like 1Password, AWS Secrets Manager
- CI/CD secrets - Use GitHub Secrets, GitLab CI/CD variables
Avoid Committing Config Files
Never commit your config file to version control:Custom Config Files
Using Custom Locations
You can use a custom config file location with the--config flag:
- Project-specific configurations
- Team-shared configurations (without secrets)
- CI/CD environments
Template Example
Create a team config template without secrets:Tracked Variables
Strix automatically tracks and saves these environment variables:LLM Configuration
STRIX_LLMLLM_API_KEYLLM_API_BASEOPENAI_API_BASELITELLM_BASE_URLOLLAMA_API_BASESTRIX_REASONING_EFFORTSTRIX_LLM_MAX_RETRIESSTRIX_MEMORY_COMPRESSOR_TIMEOUTLLM_TIMEOUT
Tool Configuration
PERPLEXITY_API_KEYSTRIX_DISABLE_BROWSER
Runtime Configuration
STRIX_IMAGESTRIX_RUNTIME_BACKENDSTRIX_SANDBOX_EXECUTION_TIMEOUTSTRIX_SANDBOX_CONNECT_TIMEOUT
Telemetry
STRIX_TELEMETRY
DOCKER_HOST is not tracked in the config file. It should be set as an environment variable if needed.Special Behaviors
LLM Config Re-validation
LLM-related variables (STRIX_LLM, LLM_API_KEY, etc.) are re-validated on each run:
- If you change these variables in your environment, Strix uses the new values
- The saved configuration is updated with the new values
- This ensures your LLM config is always up to date
Custom Config Override
When using--config, Strix:
- Does not automatically save changes to the custom config file
- Uses the custom config file as read-only
- Still respects environment variables (they take precedence)
Troubleshooting
Config Not Loading
If your saved config isn’t being used:- Check file permissions:
ls -la ~/.strix/cli-config.json - Validate JSON syntax:
jq . ~/.strix/cli-config.json - Ensure environment variables aren’t overriding saved values
- Check for typos in variable names