forked from syntaxbullet/aurorabot
chore: bump version, add deployment script
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "app",
|
"name": "app",
|
||||||
"version": "1.1.3",
|
"version": "1.1.4-pre",
|
||||||
"module": "bot/index.ts",
|
"module": "bot/index.ts",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"private": true,
|
"private": true,
|
||||||
|
|||||||
32
shared/scripts/deploy-remote.sh
Executable file
32
shared/scripts/deploy-remote.sh
Executable file
@@ -0,0 +1,32 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Load environment variables
|
||||||
|
if [ -f .env ]; then
|
||||||
|
set -a
|
||||||
|
source .env
|
||||||
|
set +a
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "$VPS_HOST" ] || [ -z "$VPS_USER" ]; then
|
||||||
|
echo "Error: VPS_HOST and VPS_USER must be set in .env"
|
||||||
|
echo "Please add them to your .env file:"
|
||||||
|
echo "VPS_USER=your-username"
|
||||||
|
echo "VPS_HOST=your-ip-address"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Default remote directory to ~/Aurora if not specified
|
||||||
|
REMOTE_DIR="${VPS_PROJECT_PATH:-~/Aurora}"
|
||||||
|
|
||||||
|
echo -e "\033[1;33m🚀 Deploying to $VPS_USER@$VPS_HOST:$REMOTE_DIR...\033[0m"
|
||||||
|
|
||||||
|
# Execute commands on remote server
|
||||||
|
ssh -t "$VPS_USER@$VPS_HOST" "cd $REMOTE_DIR && \
|
||||||
|
echo '⬇️ Pulling latest changes...' && \
|
||||||
|
git pull && \
|
||||||
|
echo '🏗️ Building production containers...' && \
|
||||||
|
docker compose -f docker-compose.prod.yml build && \
|
||||||
|
echo '🚀 Starting services...' && \
|
||||||
|
docker compose -f docker-compose.prod.yml up -d && \
|
||||||
|
echo '✅ Deployment complete!'"
|
||||||
Reference in New Issue
Block a user