30 lines
725 B
Bash
30 lines
725 B
Bash
|
|
#!/bin/bash
|
||
|
|
set -e
|
||
|
|
|
||
|
|
REMOTE="root@miniweb.kuehn.home"
|
||
|
|
REMOTE_DIR="/var/www/tracker"
|
||
|
|
SSH="ssh -p 30183"
|
||
|
|
|
||
|
|
rsync -av \
|
||
|
|
-e "$SSH" \
|
||
|
|
--exclude='.claude/' \
|
||
|
|
--exclude='.superpowers/' \
|
||
|
|
--exclude='.aider*' \
|
||
|
|
--exclude='vendor/' \
|
||
|
|
--exclude='var/' \
|
||
|
|
--exclude='docs/' \
|
||
|
|
--exclude='.env.local' \
|
||
|
|
--exclude='deploy.sh' \
|
||
|
|
--exclude='include/' \
|
||
|
|
--exclude='api.php' \
|
||
|
|
--exclude='index.php' \
|
||
|
|
/srv/http/zieltracker/ $REMOTE:$REMOTE_DIR/
|
||
|
|
|
||
|
|
# composer install auf dem Server
|
||
|
|
$SSH $REMOTE "cd $REMOTE_DIR && composer install --no-dev --no-interaction --optimize-autoloader 2>&1 | tail -5"
|
||
|
|
|
||
|
|
# Cache leeren
|
||
|
|
$SSH $REMOTE "cd $REMOTE_DIR && php bin/console cache:clear --env=prod --no-warmup 2>&1"
|
||
|
|
|
||
|
|
echo "Deploy fertig."
|