cool
This commit is contained in:
parent
41b92ba7b4
commit
b47655f21e
|
|
@ -13,11 +13,27 @@ ssh -MNf -o ControlMaster=yes -o ControlPersist=120 \
|
||||||
-o ControlPath="$SOCK" "$HOST"
|
-o ControlPath="$SOCK" "$HOST"
|
||||||
|
|
||||||
# 2) rsync (reuses the connection)
|
# 2) rsync (reuses the connection)
|
||||||
|
|
||||||
|
# destructive sync for /app
|
||||||
rsync -az --delete \
|
rsync -az --delete \
|
||||||
-e "ssh -o ControlPath=$SOCK" \
|
-e "ssh -o ControlPath=$SOCK" \
|
||||||
--exclude 'node_modules/' \
|
--exclude 'node_modules/' \
|
||||||
--exclude '.git/' \
|
--exclude '.git/' \
|
||||||
../ "$HOST:$DEST/"
|
../app/ "$HOST:$DEST/app/"
|
||||||
|
|
||||||
|
# additive sync for /bin and /www
|
||||||
|
rsync -az \
|
||||||
|
-e "ssh -o ControlPath=$SOCK" \
|
||||||
|
--exclude 'node_modules/' \
|
||||||
|
--exclude '.git/' \
|
||||||
|
../bin/ "$HOST:$DEST/bin/"
|
||||||
|
|
||||||
|
rsync -az \
|
||||||
|
-e "ssh -o ControlPath=$SOCK" \
|
||||||
|
--exclude 'node_modules/' \
|
||||||
|
--exclude '.git/' \
|
||||||
|
../www/ "$HOST:$DEST/www/"
|
||||||
|
|
||||||
|
|
||||||
# 3) remote deploy (reuses the connection)
|
# 3) remote deploy (reuses the connection)
|
||||||
ssh -o ControlPath="$SOCK" "$HOST" "cd $DEST && bun install --frozen-lockfile && sudo systemctl restart nose-pluto.service"
|
ssh -o ControlPath="$SOCK" "$HOST" "cd $DEST && bun install --frozen-lockfile && sudo systemctl restart nose-pluto.service"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user