Configuration Files Details
Configuration files are used to simplify MANYOYO command-line operations and avoid repetitive parameter input. Uses JSON5 format, supporting comments and better readability.
Configuration File Types
MANYOYO supports two types of configuration files:
1. Global Configuration
File Path: ~/.manyoyo/manyoyo.json
Features:
- Automatically loaded (when running any manyoyo command)
- Suitable for setting default images, common environment variables, etc.
- Lowest priority
Example:
{
"imageName": "localhost/xcanwin/manyoyo",
"imageVersion": "1.8.0-full"
}2. Run Configuration
Location:
- Global configuration file:
~/.manyoyo/manyoyo.json - Run configuration:
runs.<name>in~/.manyoyo/manyoyo.json(using-r <name>)
Features:
- Needs to be explicitly loaded (using
-rparameter) - Suitable for setting configurations for specific projects or tools
- Higher priority than global configuration
Example:
{
"envFile": ["/abs/path/anthropic_claudecode.env"],
"shellSuffix": "-c",
"yolo": "c"
}Configuration Options Details
Refer to config.example.json to view all configurable items. Below are detailed explanations:
Container Basic Configuration
containerName
- Type: String
- Default:
my-{MMDD-HHMM}(auto-generated) - Description: Container name, used to identify and manage containers
- Example:
{
"containerName": "my-dev"
}hostPath
- Type: String
- Default: Current working directory
- Description: Host working directory, will be mounted into the container
- Example:
{
"hostPath": "/Users/username/projects/myproject"
}containerPath
- Type: String
- Default: Same as hostPath
- Description: Working directory inside the container
- Example:
{
"containerPath": "/workspace/myproject"
}imageName
- Type: String
- Default:
localhost/xcanwin/manyoyo - Description: Image name (without version tag)
- Example:
{
"imageName": "localhost/myuser/manyoyo"
}imageVersion
- Type: String
- Default: None
- Description: Image version tag
- Format:
<version>-<variant> - Example:
{
"imageVersion": "1.8.0-full" // full version includes all tools
}Available variants:
full- Complete version (recommended)common- Common tools version- Custom - Build using
--iba TOOL=xxx
containerMode
- Type: String
- Values:
common,dind,sock - Default:
common - Description: Container nesting mode
- Example:
{
"containerMode": "dind" // Docker-in-Docker mode
}Mode descriptions:
common- Normal mode, no container nesting capabilitydind- Docker-in-Docker mode, secure nested containerssock- Mount Docker Socket mode (dangerous, can access everything on host)
serverUser
- Type: String
- Default:
admin - Description: Web login username (
servemode) - Environment Variable:
MANYOYO_SERVER_USER - Example:
{
"serverUser": "admin"
}serverPass
- Type: String
- Default: Auto-generated random password when unset
- Description: Web login password (
servemode) - Environment Variable:
MANYOYO_SERVER_PASS - Example:
{
"serverPass": "change-this-password"
}Environment Variable Configuration
envFile
- Type: String array
- Merge Method: Accumulation merge
- Description: Environment file list, loaded in order (absolute paths only)
- Example:
{
"envFile": [
"/abs/path/anthropic_claudecode.env",
"/abs/path/secrets.env"
]
}env
- Type: Object (map)
- Merge Method: Merge by key (later source overrides earlier source)
- Description: Directly specify environment variables
- Example:
{
"env": {
"DEBUG": "true",
"LOG_LEVEL": "info"
}
}Mount Volume Configuration
volumes
- Type: String array
- Merge Method: Accumulation merge
- Description: Additional mount volumes
- Format:
host_path:container_path[:options] - Example:
{
"volumes": [
"/Users/pc_user/.codex/auth.json:/root/.codex/auth.json",
"/tmp/cache:/workspace/cache:ro" // Read-only mount
]
}ports
- Type: String array
- Merge Method: Accumulation merge
- Description: Additional port mappings (passed through as
--publish) - Format: Mapping string supported by Docker/Podman
--publish - Example:
{
"ports": [
"8080:80",
"127.0.0.1:8443:443"
]
}Service Configuration
plugins.playwright
- Type: Object
- Description: Playwright plugin settings used by
manyoyo playwright/manyoyo plugin playwright - Example:
{
"plugins": {
"playwright": {
"runtime": "mixed", // mixed | container | host
"enabledScenes": ["cont-headless", "cont-headed", "host-headless", "host-headed"],
"mcpDefaultHost": "host.docker.internal",
"vncPasswordEnvKey": "VNC_PASSWORD",
"extensionProdversion": "132.0.0.0",
"ports": {
"contHeadless": 8931,
"contHeaded": 8932,
"hostHeadless": 8933,
"hostHeaded": 8934,
"contHeadedNoVnc": 6080
}
}
}
}runs.<name>.plugins.playwright can override global plugins.playwright for per-profile behavior.
manyoyo playwright ext-downloaddownloads extensions into~/.manyoyo/plugin/playwright/extensions/(temp files are auto-cleaned).manyoyo playwright up <scene> --ext-path <path> --ext-name <name>appends extension directories for any scene (both options can be repeated and are converted to Playwright extension launch args).
Command Configuration
shellPrefix
- Type: String
- Description: Command prefix, usually used to set temporary environment variables
- Example:
{
"shellPrefix": "DEBUG=1"
}shell
- Type: String
- Description: Main command to execute
- Example:
{
"shell": "claude"
}shellSuffix
- Type: String
- Description: Command suffix appended after
shell(e.g.,-c,resume --last) - Priority: Can be overridden by command-line
--ssor-- ...(-- ...has highest priority) - Example:
{
"shell": "codex",
"shellSuffix": "resume --last"
}yolo
- Type: String
- Values:
c,gm,cx,oc(or full namesclaude,gemini,codex,opencode) - Description: YOLO mode shortcut, skips permission confirmation
- Example:
{
"yolo": "c" // Equivalent to claude --dangerously-skip-permissions
}Other Configuration
quiet
- Type: String array
- Values:
tip,cmd,full - Description: Silent display options
- Example:
{
"quiet": ["tip", "cmd"] // Don't display tips and commands
}imageBuildArgs
- Type: String array
- Merge Method: Accumulation merge
- Description: Image build arguments, passed to Dockerfile
- Format:
KEY=VALUE - Example:
{
"imageBuildArgs": [
"TOOL=common",
"GIT_SSL_NO_VERIFY=true"
]
}Configuration Path Rules
Run Configuration Path Resolution
# Read from runs in manyoyo.json
manyoyo run -r claude
# Loads: runs.claude in ~/.manyoyo/manyoyo.jsonGlobal Configuration
Global configuration is always loaded from a fixed location:
~/.manyoyo/manyoyo.jsonConfiguration Merge Rules
Refer to Configuration System Overview for detailed merge rules.
Brief description:
Override Parameters
Takes the value from the highest priority:
Command-line arguments > runs.<name> > Global configuration > Default valuesFor serverUser / serverPass, the priority is:
Command-line arguments > runs.<name> > Global configuration > Environment variables > Default valuesMerge Parameters
Accumulated merge in order:
Global configuration + runs.<name> + Command-line argumentsComplete Configuration Examples
Example: Global Configuration
// ~/.manyoyo/manyoyo.json
{
// Use custom image
"imageName": "localhost/xcanwin/manyoyo",
"imageVersion": "1.8.0-full",
// Global environment variables
"env": {
"TZ": "Asia/Shanghai",
"LANG": "en_US.UTF-8"
},
// Default silent tips
"quiet": ["tip"]
}Example: Claude Code Run Configuration
// ~/.manyoyo/manyoyo.json (fragment)
{
// Load Claude environment variables
"envFile": ["/abs/path/anthropic_claudecode.env"],
// Use YOLO mode
"yolo": "c",
// Additional mount SSH configuration
"volumes": [
"~/.ssh:/root/.ssh:ro"
]
}Example: Codex Run Configuration
// ~/.manyoyo/manyoyo.json (fragment)
{
// Load Codex environment variables
"envFile": ["/abs/path/openai_[gpt]_codex.env"],
// Mount authentication file
"volumes": [
"/Users/pc_user/.codex/auth.json:/root/.codex/auth.json"
],
// Use YOLO mode
"yolo": "cx"
}Example: Docker-in-Docker Configuration
// ~/.manyoyo/manyoyo.json (fragment)
{
// Use Docker-in-Docker mode
"containerMode": "dind",
// Container name
"containerName": "my-dind",
// Additional mount Docker configuration
"volumes": [
"~/.docker:/root/.docker:ro"
]
}Example: Project-Specific Configuration
// ./myproject/.manyoyo.json
{
// Project container name
"containerName": "my-myproject",
// Project environment variables
"env": {
"PROJECT_NAME": "myproject",
"NODE_ENV": "development"
},
// Use project local environment file
"envFile": ["/abs/path/local.env"]
}Debugging Configuration
View Final Configuration
# Display merged results from all configuration sources
manyoyo config show
# Display merged results for specific run configuration
manyoyo config show -r claude
# Display command to be executed
manyoyo config command -r claudeCommon Configuration Issues
Configuration Not Taking Effect
Symptom: After modifying configuration file, parameters are not taking effect
Solutions:
- Check configuration file format (must be valid JSON5)
- Confirm file path is correct
- Use
config showto view final configuration - Note that override parameters only take the highest priority value
# Verify runs.claude structure
cat ~/.manyoyo/manyoyo.json | jq '.runs.claude'
# View final configuration
manyoyo config show -r claudeConfiguration Conflicts
Symptom: Multiple configuration sources set the same parameter, uncertain which one takes effect
Solutions:
- Understand priority rules (override vs merge)
- Use
config showto view final value - Remove conflicting items from lower priority configurations if necessary
Environment Variables Not Loaded
Symptom: envFile specified in configuration file, but environment variables not taking effect
Solutions:
- Confirm environment file path is correct
- Check environment file format
- Use
config showto view loaded environment file list - Run
envcommand in container to verify
# View environment files in configuration
manyoyo config show -r claude | grep envFile
# Verify environment variables in container
manyoyo run -r claude -x env | grep ANTHROPICBest Practices
1. Layered Configuration
# Global configuration: Set common options
~/.manyoyo/manyoyo.json
# Run configuration: Set tool-specific options (runs in manyoyo.json)
~/.manyoyo/manyoyo.json (runs.claude / runs.codex)
# Project configuration: Set project-specific options
./project/.manyoyo.json2. Use Comments
{
// Production environment configuration
"imageVersion": "1.8.0-full",
// Can temporarily switch during development
// "imageVersion": "1.8.0-common",
"envFile": [
"/abs/path/anthropic_base.env", // Base configuration
"/abs/path/anthropic_secrets.env" // Sensitive information
]
}3. Version Control
# Commit to version control
.manyoyo.json # Project configuration
config.example.json # Configuration example
# Exclude sensitive information
.gitignore:
*.env
secrets.json4. Configuration Templates
Create configuration templates for team use:
# Edit runs configuration
vim ~/.manyoyo/manyoyo.jsonRelated Documentation
- Configuration System Overview - Understand configuration priority mechanism
- Environment Variables Details - Learn how to configure environment variables
- Configuration Examples - View more practical examples
- Web Server Auth and Security - Auth behavior and security baseline for
serve