cli: mbs update now also refreshes /usr/local/bin/mbs itself after pulling
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
parent
bfc2fd7b4c
commit
320742bd63
1 changed files with 6 additions and 1 deletions
7
mbs
7
mbs
|
|
@ -81,8 +81,13 @@ cmd_update() {
|
|||
venv/bin/pip install --quiet -r requirements.txt
|
||||
return 1
|
||||
fi
|
||||
echo "обновляю сам CLI..."
|
||||
cp "$APP_DIR/mbs" /usr/local/bin/mbs
|
||||
chmod +x /usr/local/bin/mbs
|
||||
|
||||
echo "перезапускаю..."
|
||||
systemctl restart mbs-bot mbs-api
|
||||
systemctl restart mbs-bot mbs-api xray
|
||||
systemctl reload nginx 2>/dev/null || true
|
||||
sleep 2
|
||||
if systemctl is-active --quiet mbs-bot && systemctl is-active --quiet mbs-api; then
|
||||
echo "обновлено: $before -> $(git rev-parse --short HEAD)"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue