コンテンツにスキップ

ディレクトリ構造

OpsAnt コードリポジトリの主要なディレクトリ構成。

opsant/
├── frontend/            # Vue 3 前端
│   ├── src/
│   │   ├── views/       # 页面组件
│   │   ├── components/  # 通用组件
│   │   ├── layouts/     # 布局(ConsoleLayout 等)
│   │   ├── api/         # API 封装
│   │   ├── locales/     # 多语言(7 语言)
│   │   ├── stores/      # Pinia 状态
│   │   ├── router/      # 路由
│   │   └── styles/      # 全局样式
│   └── ...
├── opsant/              # Django 后端
│   ├── views/           # API 视图(hosts/monitor/ai/permission 等)
│   ├── models.py        # 数据模型
│   ├── urls.py          # API 路由
│   └── migrations/      # 数据库迁移
├── proxy/               # 兼容 OpsAny Proxy 的旧模块(SaltStack/Ansible API)
├── opsmini-server/      # OpsMini Server(Go 子项目)
├── install/             # 安装脚本与配置模板
├── docker/              # Dockerfile
├── static/opsant/       # 前端构建产物(SPA)
├── templates/opsant/    # SPA 入口 HTML
└── opsant-docs/         # 本文档站点

重要な説明

  • opsant/ と proxy/ は併存する2つのモジュールセットです:
  • opsant/ は新プラットフォーム(独立製品)の API とモデルです
  • proxy/ は OpsAny 旧ルートと互換性のあるモジュールで、OPSANT_ENABLED スイッチによって分離されています
  • frontend/src/locales/ はフロントエンド多言語の単一の真実の源です
  • docs/zh/ は本ドキュメントのソース言語(単一の真実の源)であり、その他の言語はスクリプトによる機械翻訳です