Termix について
termix-mcpは、セルフホスト型Termix向けのMCPサーバーで、エージェントからホスト、スニペット、ダッシュボード、メトリクス、監査記録を参照・操作できます。厳選されたツールセットに加え、読み取り専用モード、ツール制御、出力内の秘密情報のマスキングを備えています。
主な機能
- 01ホストとコマンドスニペットを管理
- 02ダッシュボード、メトリクス、監査記録を表示
- 03ツールセットと許可リストでツールを制御
- 04読み取り専用モードで書き込み操作を非表示・禁止
- 05出力内の秘密情報をマスキング
活用シーン
- 01登録済みホストとそのメトリクスを確認
- 02Termixに保存したコマンドスニペットを実行
- 03監査アクティビティとシステム状態を確認
- 04エージェントの操作を読み取り専用に制限
MCP 対応
ホスト、スニペット、ダッシュボード、メトリクス、監査機能をMCPクライアント向けのツールとして提供し、ファイルやコンテナなどのツールセットも選択できます。stdioまたはHTTP接続に対応し、読み取り専用モードとツールアクセス制御を備えています。
設定
ローカルサーバーの設定はどのクライアントでも共通です。コピーしてクライアントの MCP 設定ファイルに貼り付けてください。
uvx termix-mcpTERMIX_URLBase URL of the Termix instanceTERMIX_API_KEYシークレットTermix API key (tmx_...)TERMIX_MCP_TOOLSETSdefault, all, or a comma-separated list (hosts,snippets,files,...)TERMIX_MCP_READ_ONLYHide and block every write toolローカルサーバーにはマシン上の実行環境(Node.js 18 以上など)が必要です。設定ファイルの場所はクライアントごとに異なります。
ツール
ローカルサーバーのツールはマシン上で起動して初めて取得できます。メンテナーはまだツール一覧を提供していません。
詳細
termix-mcp
セルフホスト可能な SSH/RDP/VNC マネージャーである Termix 用の MCP サーバーです。エージェント(Claude Desktop、Claude Code、Cursor、VS Code など)から、termix-sdk を基盤として、Termix のホスト、スニペット、ダッシュボード、メトリクス、監査証跡の一覧表示や操作を行えます。
Termix API を 1 対 1 でラップしたものではありません。厳選したツールセットで、デフォルトで安全です(シークレットは扱わず、SSH セッションを永続化せず、明示的なツールセット以外では破壊的なツールを使用しません)。
インストール
uvx termix-mcp
代替方法:pip install termix-mcp または ghcr.io/sujirodev/termix-mcp イメージを使用します。
Termix API キー(tmx_...)が必要です。エージェントが実行する操作に必要な最小限の RBAC 権限を設定してください。詳細は SECURITY.md を参照してください。
クライアントで設定する
Claude Desktop/Claude Code(claude_desktop_config.json または .mcp.json):
{
"mcpServers": {
"termix": {
"command": "uvx",
"args": ["termix-mcp"],
"env": {
"TERMIX_URL": "https://termix.example.com",
"TERMIX_API_KEY": "tmx_xxxxxxxxxxxxxxxxxxxxxxxx"
}
}
}
}
Cursor/VS Code:各自の MCP 設定ファイルで同じ形式を使用します。
MCP Registry 経由でインストールする
termix-mcp は公式の MCP Registry に io.github.sujirodev/termix-mcp という名前で公開されています。PyPI(uvx)パッケージと OCI(Docker)イメージの両方が登録されています。詳細は server.json を参照してください。
レジストリベースの検出に対応しているクライアントなら、上記の JSON 設定を手動で記述する代わりに、レジストリから直接検索してインストールできます。
curl -s "https://registry.modelcontextprotocol.io/v0/servers?search=io.github.sujirodev/termix-mcp"
その後、クライアント独自の「レジストリから追加」手順に従い、io.github.sujirodev/termix-mcp を検索してください。TERMIX_URL と TERMIX_API_KEY は引き続き自分で設定する必要があります。レジストリのエントリーには認証情報が含まれていません。
「こう頼む」と「実行されること」
| あなたの依頼 | ツールの動作 |
|---|---|
| 「登録済みのホストを教えて」 | termix_list_hosts |
| 「ホスト X のメトリクスを表示して」 | termix_get_host_metrics |
| 「ホスト X でスニペット Y を実行して」 | termix_run_snippet(読み取り専用モードではブロックされます) |
| 「このサーバー用に新しいホストを作成して」 | termix_create_host(読み取り専用モードではブロックされます) |
| 「今週どんな監査アクティビティがあった?」 | termix_list_audit_events |
環境変数
| 変数 | デフォルト | 説明 |
|---|---|---|
TERMIX_URL | required | Termix のベース URL |
TERMIX_API_KEY | required | tmx_... API キー(JWT/TOTP はサポートされていません) |
TERMIX_SERVICE_URLS | empty | プロキシを使用しないインストール向けの JSON {"database": "http://..."} |
TERMIX_VERIFY_SSL | true | TLS 証明書を検証します |
TERMIX_TIMEOUT | 30 | リクエストごとのタイムアウト(秒) |
TERMIX_MAX_RETRIES | 2 | SDK に渡されます |
TERMIX_MCP_READ_ONLY | false | 書き込みツールを非表示にし、ブロックします |
TERMIX_MCP_TOOLSETS | default | default、all、または hosts,snippets,files のようなリスト |
TERMIX_MCP_ENABLED_TOOLS | empty | ツール名による許可リスト |
TERMIX_MCP_DISABLED_TOOLS | empty | ツール名による拒否リスト |
TERMIX_MCP_REDACT_SECRETS | true | すべての出力でシークレットをマスクします |
TERMIX_MCP_MAX_ITEMS | 50 | 一覧表示のデフォルト項目数上限 |
TERMIX_MCP_TRANSPORT | stdio | stdio または http |
TERMIX_MCP_HTTP_HOST / _PORT | 127.0.0.1 / 8765 | HTTP トランスポートのバインド先 |
TERMIX_MCP_HTTP_PATH | generated and logged | HTTP エンドポイントのシークレットパス |
TERMIX_MCP_LOG_LEVEL | INFO | ログレベル(stdio では stderr、http では stdout) |
ツールセット
デフォルトで有効:hosts、snippets、dashboard、metrics、system、audit。
オプトイン(TERMIX_MCP_TOOLSETS=hosts,files,docker,...):credentials、files、docker、tunnels、alerts、automations、users。
無効かつ明示的(all には決して含まれません):admin、dangerous。
TERMIX_MCP_READ_ONLY=true にすると、どのツールセットでも読み取り専用ではないすべてのツールが非表示になり、ブロックされます。
ツール
ツールの全一覧(scripts/generate_tool_docs.py によって生成)
| Tool | Toolset | Read-only | Destructive | Flags |
|---|---|:---:|:---:|---|
| `termix_get_audit_forwarding` | admin | yes | no | admin |
| `termix_get_branding` | admin | yes | no | admin |
| `termix_get_encryption_status` | admin | yes | no | admin |
| `termix_get_host_defaults` | admin | yes | no | admin |
| `termix_get_termix_id_status` | admin | yes | no | admin |
| `termix_list_sso_providers` | admin | yes | no | admin |
| `termix_update_branding` | admin | no | no | admin |
| `termix_acknowledge_alert_firing` | alerts | no | no | - |
| `termix_create_alert_rule` | alerts | no | no | - |
| `termix_delete_alert_rule` | alerts | no | yes | - |
| `termix_list_alert_rules` | alerts | yes | no | - |
| `termix_get_session_log` | audit | yes | no | - |
| `termix_list_audit_events` | audit | yes | no | - |
| `termix_list_session_logs` | audit | yes | no | - |
| `termix_get_automation` | automations | yes | no | - |
| `termix_list_automations` | automations | yes | no | - |
| `termix_list_fleets` | automations | yes | no | - |
| `termix_run_automation` | automations | no | no | data-access |
| `termix_create_credential` | credentials | no | no | - |
| `termix_delete_credential` | credentials | no | yes | - |
| `termix_get_credential` | credentials | yes | no | - |
| `termix_list_credentials` | credentials | yes | no | - |
| `termix_reveal_credential` | credentials | yes | no | data-access |
| `termix_update_credential` | credentials | no | no | - |
| `termix_get_dashboard_summary` | dashboard | yes | no | - |
| `termix_get_homepage` | dashboard | yes | no | - |
| `termix_list_open_tabs` | dashboard | yes | no | - |
| `termix_list_workspaces` | dashboard | yes | no | - |
| `termix_get_container` | docker | yes | no | data-access |
| `termix_get_container_logs` | docker | yes | no | data-access |
| `termix_get_container_stats` | docker | yes | no | data-access |
| `termix_list_containers` | docker | yes | no | data-access |
| `termix_restart_container` | docker | no | no | data-access |
| `termix_start_container` | docker | no | no | data-access |
| `termix_stop_container` | docker | no | no | data-access |
| `termix_create_folder` | files | no | no | data-access |
| `termix_delete_file` | files | no | yes | data-access |
| `termix_list_files` | files | yes | no | data-access |
| `termix_move_file` | files | no | no | data-access |
| `termix_read_file` | files | yes | no | data-access |
| `termix_rename_file` | files | no | no | data-access |
| `termix_write_file` | files | no | no | data-access |
| `termix_create_host` | hosts | no | no | - |
| `termix_delete_host` | hosts | no | yes | - |
| `termix_disable_host_autostart` | hosts | no | no | - |
| `termix_enable_host_autostart` | hosts | no | no | - |
| `termix_get_host` | hosts | yes | no | - |
| `termix_get_network_topology` | hosts | yes | no | - |
| `termix_list_host_folders` | hosts | yes | no | - |
| `termix_list_host_tags` | hosts | yes | no | - |
| `termix_list_hosts` | hosts | yes | no | - |
| `termix_update_host` | hosts | no | no | - |
| `termix_get_host_metrics` | metrics | yes | no | - |
| `termix_get_host_status` | metrics | yes | no | - |
| `termix_get_metrics_history` | metrics | yes | no | - |
| `termix_get_proxmox_stats` | metrics | yes | no | - |
| `termix_list_active_alerts` | metrics | yes | no | - |
| `termix_list_host_statuses` | metrics | yes | no | - |
| `termix_create_snippet` | snippets | no | no | - |
| `termix_delete_snippet` | snippets | no | yes | - |
| `termix_get_snippet` | snippets | yes | no | - |
| `termix_list_snippets` | snippets | yes | no | - |
| `termix_run_snippet` | snippets | no | no | - |
| `termix_update_snippet` | snippets | no | no | - |
| `termix_get_preferences` | system | yes | no | - |
| `termix_get_system_info` | system | yes | no | - |
| `termix_list_api_keys` | system | yes | no | - |
| `termix_create_tunnel` | tunnels | no | no | data-access |
| `termix_delete_tunnel` | tunnels | no | no | data-access |
| `termix_get_tunnel` | tunnels | yes | no | - |
| `termix_list_tunnel_presets` | tunnels | yes | no | - |
| `termix_list_tunnels` | tunnels | yes | no | - |
| `termix_assign_role` | users | no | no | admin |
| `termix_get_user` | users | yes | no | admin |
| `termix_list_credential_access` | users | yes | no | admin |
| `termix_list_folder_access` | users | yes | no | admin |
| `termix_list_roles` | users | yes | no | admin |
| `termix_list_users` | users | yes | no | admin |
合計:78 個のツールです。
貢献
CONTRIBUTING.md を参照してください。
セキュリティ
脅威モデルについては、SECURITY.md を参照してください。
ライセンス
コメント
AI アプリケーションが外部のツールやデータソースに統一的な方法で接続するためのオープンなプロトコルです。クライアントはモデルとの対話を担い、MCP サーバーはツール・リソース・プロンプトテンプレートを提供します。標準メッセージでやり取りするため、1 つのサーバーを複数のクライアントで再利用できます。