mirror of
https://github.com/DeBrosOfficial/orama.git
synced 2026-05-01 05:04:13 +00:00
- add deploy.sh for rsync-based remote deployment - add SEO/Open Graph/Twitter meta tags and og-image - ignore remote.conf and update pnpm build deps
24 lines
515 B
Bash
Executable File
24 lines
515 B
Bash
Executable File
#!/bin/bash
|
|
set -e
|
|
|
|
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
CONF="$SCRIPT_DIR/remote.conf"
|
|
|
|
if [ ! -f "$CONF" ]; then
|
|
echo "Error: remote.conf not found. Create it with REMOTE_USER, REMOTE_HOST, REMOTE_PASS, REMOTE_PATH."
|
|
exit 1
|
|
fi
|
|
|
|
source "$CONF"
|
|
|
|
echo "Building website..."
|
|
cd "$SCRIPT_DIR"
|
|
pnpm build
|
|
|
|
echo "Deploying to $REMOTE_USER@$REMOTE_HOST:$REMOTE_PATH..."
|
|
sshpass -p "$REMOTE_PASS" rsync -avz --delete \
|
|
dist/ \
|
|
"$REMOTE_USER@$REMOTE_HOST:$REMOTE_PATH/"
|
|
|
|
echo "Done. Live at https://$DOMAIN"
|