Files
security-alert-center/docs/workspace-three-repos.md
T

3.3 KiB

Multi-root workspace: три репозитория

Как работать в одном multi-root workspace над ssh-monitor, RDP-login-monitor и security-alert-center одновременно (VS Code или совместимый редактор).


1. Расположение репозиториев (пример)

Имя в workspace Путь (пример Windows) Remote
ssh-monitor D:\Soft\Git\ssh-monitor git.kalinamall.ru
rdp-monitor D:\Soft\Git\RDP-login-monitor git.kalinamall.ru
security-alert-center D:\Soft\Git\security-alert-center git.kalinamall.ru

Пути подставьте свои.


2. Файл workspace

Создайте security-monitors.code-workspace:

{
  "folders": [
    {
      "path": "D:/Soft/Git/ssh-monitor",
      "name": "ssh-monitor"
    },
    {
      "path": "D:/Soft/Git/RDP-login-monitor",
      "name": "rdp-monitor"
    },
    {
      "path": "D:/Soft/Git/security-alert-center",
      "name": "security-alert-center"
    }
  ],
  "settings": {
    "files.eol": "\n"
  }
}

Открыть: File → Open Workspace from File.


3. Порядок работ по фазам

Фаза Где править
0 — ТЗ security-alert-center/docs/
1 — MVP SAC security-alert-center/backend, frontend
2 — UseSAC ssh-monitor, RDP-login-monitor + мелкие правки SAC при необходимости

4. Соглашения

  • Контракт событий: security-alert-center/docs/event-schema-v1.jsonединственный источник истины.
  • Изменение схемы → обновить ТЗ + версию schema_version + оба агента.
  • Коммиты в три репо раздельные; связь через теги/версии в README (см. roadmap.md).

4.1. Git: только git.kalinamall.ru

Единственный рабочий remote для commit/push — kalinamall (git.kalinamall.ru).
GitHub (origin) в этом workspace не используем: не push, не pull, не PR.

После каждой завершённой фичи (или логического блока работы):

git add …
git commit -m "…"
git fetch kalinamall
git push kalinamall main

Upstream ветки main:

git config branch.main.remote kalinamall
git config branch.main.merge refs/heads/main
git config remote.pushDefault kalinamall

Если git push --force-with-lease пишет stale info — сначала git fetch kalinamall, затем push снова.


5. Remote kalinamall (первичная настройка)

git remote add kalinamall https://git.kalinamall.ru/PapaTramp/<repo>.git
git push -u kalinamall main

Репозитории:

Проект URL
security-alert-center https://git.kalinamall.ru/PapaTramp/security-alert-center.git
ssh-monitor https://git.kalinamall.ru/PapaTramp/ssh-monitor.git
RDP-login-monitor https://git.kalinamall.ru/PapaTramp/RDP-login-monitor.git

См. также