ruff.toml has declared `quote-style = "single"` and line-length 120 since the lint job landed, and 118 of 128 files follow it. The panel backend and the netbox configuration were written in black/prettier style instead, so a `ruff format --check` would have failed on them from the start. Bring them onto the style the repository already declares, which is what makes the check adoptable at all. Formatting only: apart from quote style the diff is multi-line expressions joined where they fit inside 120 columns. Both suites still pass afterwards (25 pytest, and ruff check is clean). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Userbot Control Panel
Локальная панель управляет userbot-инстансами напрямую через Kubernetes API.
Новые аккаунты создаются в namespace userbot; существующие forust и anna
остаются в default и принимаются под управление только через metadata labels.
Первый запуск
Скопировать общий Secret в новый namespace, не печатая его значения:
kubectl create namespace userbot --dry-run=client -o yaml | kubectl apply -f -
kubectl get secret userbot-common-secrets -n default -o json \
| jq 'del(.metadata.annotations,.metadata.creationTimestamp,.metadata.resourceVersion,.metadata.uid,.metadata.managedFields) | .metadata.namespace = "userbot"' \
| kubectl apply -f -
Затем применить манифесты:
kubectl apply -f userbot/k8s/base/panel.yaml
kubectl apply -f userbot/k8s/base/userbots.yaml
kubectl rollout status deployment/userbot-panel -n userbot
Панель доступна только через внутренний Traefik route:
https://userbot.workstation.internal.
Локальная разработка
cd userbot/panel/frontend
npm install
npm run dev
Backend использует in-cluster config, а вне кластера — текущий kubeconfig:
cd userbot/panel/backend
uv run --with-requirements requirements-dev.txt \
uvicorn app.main:app --reload --port 8080