-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathTaskfile.yml
More file actions
100 lines (81 loc) · 3.07 KB
/
Taskfile.yml
File metadata and controls
100 lines (81 loc) · 3.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
version: "3"
vars:
PY: poetry run python
tasks:
default:
desc: Справка по командам
cmds:
- task --list
install:
desc: Установить зависимости Poetry
cmds:
- poetry install
init:
desc: Интерактивный мастер первичной настройки и deploy
cmds:
- poetry install
- "{{.PY}} -m xiaomi_router init {{.CLI_ARGS}}"
render:
desc: Локальный рендер шаблонов в build/rendered
cmds:
- "{{.PY}} -m xiaomi_router render {{.CLI_ARGS}}"
render-live:
desc: Рендер с определением USB по SSH
cmds:
- "{{.PY}} -m xiaomi_router render --discover-usb {{.CLI_ARGS}}"
deploy:
desc: Полный деплой на роутер (бэкап, upload, compose, smoke)
cmds:
- "{{.PY}} -m xiaomi_router deploy {{.CLI_ARGS}}"
smoke:
desc: Проверки работоспособности по SSH
cmds:
- "{{.PY}} -m xiaomi_router smoke {{.CLI_ARGS}}"
sync-pull:
desc: Скачать конфиги со стека на роутере
cmds:
- "{{.PY}} -m xiaomi_router sync-pull {{.CLI_ARGS}}"
sync-push:
desc: Залить build/rendered и запустить docker compose up
cmds:
- "{{.PY}} -m xiaomi_router sync-push {{.CLI_ARGS}}"
add-mihomo-proxy:
desc: "Добавить/обновить прокси в mihomo.proxies. Пример: task add-mihomo-proxy -- 'ss://...'"
cmds:
- "{{.PY}} -m xiaomi_router add-mihomo-proxy {{.CLI_ARGS}}"
vless-link:
desc: Напечатать VLESS (Reality) ссылку для клиента
cmds:
- "{{.PY}} -m xiaomi_router vless-link {{.CLI_ARGS}}"
vless-server-setup:
desc: Сгенерировать ключи и клиентов для Xray REALITY
cmds:
- "{{.PY}} -m xiaomi_router vless-server-setup {{.CLI_ARGS}}"
bootstrap-ssh:
desc: xmir-patcher connect + install_ssh, если SSH недоступен
cmds:
- task: xmir-deps
- "{{.PY}} -m xiaomi_router bootstrap-ssh {{.CLI_ARGS}}"
xmir-deps:
internal: true
cmds:
- |
test -f third_party/xmir-patcher/requirements.txt || \
{ echo "Инициализируйте submodule: git submodule update --init third_party/xmir-patcher"; exit 1; }
- poetry run pip install -q -r third_party/xmir-patcher/requirements.txt
diagnose:
desc: Диагностика Docker / USB на роутере
cmds:
- "{{.PY}} -m xiaomi_router diagnose {{.CLI_ARGS}}"
setup-shell-env:
desc: Настроить shell env на USB и автоподхват в SSH
cmds:
- "{{.PY}} -m xiaomi_router setup-shell-env {{.CLI_ARGS}}"
setup-entware:
desc: Установить Entware и сохранить wrapper штатного opkg
cmds:
- "{{.PY}} -m xiaomi_router setup-entware {{.CLI_ARGS}}"
setup-compose:
desc: Установить docker compose plugin на USB
cmds:
- "{{.PY}} -m xiaomi_router setup-compose {{.CLI_ARGS}}"