From 9e5eea2cd1a39252fedabc6fccf9265750949877 Mon Sep 17 00:00:00 2001 From: sirius0xdev Date: Wed, 29 Apr 2026 04:45:18 +0000 Subject: [PATCH] feat(hermes-agent): add hermes-config ConfigMap and mount to deployment - hermes-config::ConfigMap with current /opt/data/config.yaml (models incl. vLLM, agent/tool settings) - deployment.yaml: volume + subPath mountPath=/opt/data/config.yaml (overrides PVC) - kustomization.yaml: include configmap.yaml Standardizes Hermes config via K8s ConfigMap for easier management. --- .../customer1/hermes-agent/configmap.yaml | 350 ++++++++++++++++++ .../customer1/hermes-agent/deployment.yaml | 6 + .../customer1/hermes-agent/kustomization.yaml | 4 +- 3 files changed, 357 insertions(+), 3 deletions(-) create mode 100644 apps/base/customer1/hermes-agent/configmap.yaml diff --git a/apps/base/customer1/hermes-agent/configmap.yaml b/apps/base/customer1/hermes-agent/configmap.yaml new file mode 100644 index 0000000..782a7aa --- /dev/null +++ b/apps/base/customer1/hermes-agent/configmap.yaml @@ -0,0 +1,350 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: hermes-config + namespace: customer1 +data: + config.yaml: | + model: + default: grok-4-1-fast + provider: xai + base_url: https://api.x.ai/v1 + providers: {} + fallback_providers: [] + credential_pool_strategies: {} + toolsets: + - hermes-cli + agent: + max_turns: 90 + gateway_timeout: 1800 + restart_drain_timeout: 60 + api_max_retries: 3 + service_tier: '' + tool_use_enforcement: auto + gateway_timeout_warning: 900 + gateway_notify_interval: 180 + image_input_mode: auto + terminal: + backend: local + modal_mode: auto + cwd: . + timeout: 180 + env_passthrough: [] + shell_init_files: [] + auto_source_bashrc: true + docker_image: nikolaik/python-nodejs:python3.11-nodejs20 + docker_forward_env: [] + docker_env: {} + singularity_image: docker://nikolaik/python-nodejs:python3.11-nodejs20 + modal_image: nikolaik/python-nodejs:python3.11-nodejs20 + daytona_image: BACK + container_cpu: 1.0 + container_memory: 5120 + container_disk: 51200 + container_persistent: true + docker_volumes: [] + docker_mount_cwd_to_workspace: false + persistent_shell: true + browser: + inactivity_timeout: 120 + command_timeout: 30 + record_sessions: false + allow_private_urls: false + auto_local_for_private_urls: true + cdp_url: '' + dialog_policy: must_respond + dialog_timeout_s: 300 + camofox: + managed_persistence: false + checkpoints: + enabled: true + max_snapshots: 50 + auto_prune: false + retention_days: 7 + delete_orphans: true + min_interval_hours: 24 + file_read_max_chars: 100000 + tool_output: + max_bytes: 50000 + max_lines: 2000 + max_line_length: 2000 + compression: + enabled: true + threshold: 0.5 + target_ratio: 0.2 + protect_last_n: 20 + prompt_caching: + cache_ttl: 5m + bedrock: + region: '' + discovery: + enabled: true + provider_filter: [] + refresh_interval: 3600 + guardrail: + guardrail_identifier: '' + guardrail_version: '' + stream_processing_mode: async + trace: disabled + auxiliary: + vision: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 120 + extra_body: {} + download_timeout: 30 + web_extract: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 360 + extra_body: {} + compression: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 120 + extra_body: {} + session_search: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 30 + extra_body: {} + max_concurrency: 3 + skills_hub: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 30 + extra_body: {} + approval: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 30 + extra_body: {} + mcp: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 30 + extra_body: {} + title_generation: + provider: auto + model: '' + base_url: '' + api_key: '' + timeout: 30 + extra_body: {} + display: + compact: false + personality: kawaii + resume_display: full + busy_input_mode: interrupt + bell_on_complete: false + show_reasoning: false + streaming: false + final_response_markdown: strip + inline_diffs: true + show_cost: false + skin: default + user_message_preview: + first_lines: 2 + last_lines: 2 + interim_assistant_messages: true + tool_progress_command: false + tool_progress_overrides: {} + tool_preview_length: 0 + platforms: {} + tool_progress: all + dashboard: + theme: default + privacy: + redact_pii: false + tts: + provider: edge + edge: + voice: en-US-AriaNeural + elevenlabs: + voice_id: pNInz6obpgDQGcFmaJgB + model_id: eleven_multilingual_v2 + openai: + model: gpt-4o-mini-tts + voice: alloy + xai: + voice_id: eve + language: en + sample_rate: 24000 + bit_rate: 128000 + mistral: + model: voxtral-mini-tts-2603 + voice_id: c69964a6-ab8b-4f8a-9465-ec0925096ec8 + neutts: + ref_audio: '' + ref_text: '' + model: neuphonic/neutts-air-q4-gguf + device: cpu + stt: + enabled: true + provider: local + local: + model: base + language: '' + openai: + model: whisper-1 + mistral: + model: voxtral-mini-latest + voice: + record_key: ctrl+b + max_recording_seconds: 120 + auto_tts: false + beep_enabled: true + silence_threshold: 200 + silence_duration: 3.0 + human_delay: + mode: 'off' + min_ms: 800 + max_ms: 2500 + context: + engine: compressor + memory: + memory_enabled: true + user_profile_enabled: true + memory_char_limit: 2200 + user_char_limit: 1375 + provider: '' + delegation: + model: '' + provider: '' + base_url: '' + api_key: '' + inherit_mcp_toolsets: true + max_iterations: 50 + child_timeout_seconds: 600 + reasoning_effort: '' + max_concurrent_children: 3 + max_spawn_depth: 1 + orchestrator_enabled: true + subagent_auto_approve: false + prefill_messages_file: '' + skills: + external_dirs: [] + template_vars: true + inline_shell: false + inline_shell_timeout: 10 + guard_agent_created: false + honcho: {} + timezone: '' + discord: + require_mention: true + free_response_channels: '' + allowed_channels: '' + auto_thread: true + reactions: true + channel_prompts: {} + server_actions: '' + whatsapp: {} + telegram: + channel_prompts: {} + slack: + channel_prompts: {} + mattermost: + channel_prompts: {} + approvals: + mode: manual + timeout: 60 + cron_mode: deny + command_allowlist: + - script execution via -e/-c flag + - recursive delete + - delete in root path + - shell command via -c/-lc flag + quick_commands: {} + hooks: {} + hooks_auto_accept: false + personalities: {} + security: + allow_private_urls: false + redact_secrets: true + tirith_enabled: true + tirith_path: tirith + tirith_timeout: 5 + tirith_fail_open: true + website_blocklist: + enabled: false + domains: [] + shared_files: [] + cron: + wrap_response: true + max_parallel_jobs: null + code_execution: + mode: project + logging: + level: INFO + max_size_mb: 5 + backup_count: 3 + model_catalog: + enabled: true + url: https://hermes-agent.nousresearch.com/docs/api/model-catalog.json + ttl_hours: 24 + providers: {} + network: + force_ipv4: false + sessions: + auto_prune: false + retention_days: 90 + vacuum_after_prune: true + min_interval_hours: 24 + onboarding: + seen: {} + updates: + pre_update_backup: false + backup_keep: 5 + _config_version: 22 + TELEGRAM_HOME_CHANNEL: '7528130947' + session_reset: + mode: both + idle_minutes: 1440 + at_hour: 4 + models: + qwen-vllm: + provider: openai + base_url: http://openclaw-brain-service:8000/v1 + model: Youssofal/Qwen3.6-27B-Abliterated-Heretic-Uncensored-BF16 + api_key: EMPTY + rtx6000-vllm: + provider: openai + base_url: http://rtx6000-brain-service.customer1.svc.cluster.local:8000/v1 + api_key: EMPTY + model: Youssofal/Qwen3.6-27B-Abliterated-Heretic-Uncensored-BF16 + context_length: 131072 + +# ── Fallback Model ──────────────────────────────────────────────────── +# Automatic provider failover when primary is unavailable. +# Uncomment and configure to enable. Triggers on rate limits (429), +# overload (529), service errors (503), or connection failures. +# +# Supported providers: +# openrouter (OPENROUTER_API_KEY) — routes to any model +# openai-codex (OAuth — hermes auth) — OpenAI Codex +# nous (OAuth — hermes auth) — Nous Portal +# zai (ZAI_API_KEY) — Z.AI / GLM +# kimi-coding (KIMI_API_KEY) — Kimi / Moonshot +# kimi-coding-cn (KIMI_CN_API_KEY) — Kimi / Moonshot (China) +# minimax (MINIMAX_API_KEY) — MiniMax +# minimax-cn (MINIMAX_CN_API_KEY) — MiniMax (China) +# +# For custom OpenAI-compatible endpoints, add base_url and key_env. +# +# fallback_model: +# provider: openrouter +# model: anthropic/claude-sonnet-4 diff --git a/apps/base/customer1/hermes-agent/deployment.yaml b/apps/base/customer1/hermes-agent/deployment.yaml index 9fd0982..cfaa2e1 100644 --- a/apps/base/customer1/hermes-agent/deployment.yaml +++ b/apps/base/customer1/hermes-agent/deployment.yaml @@ -62,7 +62,13 @@ spec: volumeMounts: - name: hermes-data mountPath: /opt/data + - name: hermes-config + mountPath: /opt/data/config.yaml + subPath: config.yaml volumes: + - name: hermes-config + configMap: + name: hermes-config - name: hermes-data persistentVolumeClaim: claimName: hermes-agent-pvc diff --git a/apps/base/customer1/hermes-agent/kustomization.yaml b/apps/base/customer1/hermes-agent/kustomization.yaml index 41dc187..651a0fa 100644 --- a/apps/base/customer1/hermes-agent/kustomization.yaml +++ b/apps/base/customer1/hermes-agent/kustomization.yaml @@ -1,5 +1,3 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization -resources: - - deployment.yaml - - hermes-secret.yaml +resources:\n - deployment.yaml\n - hermes-secret.yaml\n - configmap.yaml