update monitor
This commit is contained in:
21
deploy.sh
Normal file
21
deploy.sh
Normal file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Configuration
|
||||
APP_DIR="/home/asf/testarena_backend"
|
||||
|
||||
echo "Starting deployment in $APP_DIR..."
|
||||
|
||||
cd $APP_DIR || { echo "Directory $APP_DIR not found"; exit 1; }
|
||||
|
||||
# Pull latest changes (assuming it's a git repo)
|
||||
if [ -d ".git" ]; then
|
||||
echo "Pulling latest changes from git..."
|
||||
git pull origin main || git pull origin master
|
||||
fi
|
||||
|
||||
# Build and restart containers
|
||||
echo "Building and restarting Docker containers..."
|
||||
docker-compose down
|
||||
docker-compose up --build -d
|
||||
|
||||
echo "Deployment completed successfully."
|
||||
14
restart_services.sh
Normal file
14
restart_services.sh
Normal file
@@ -0,0 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Configuration
|
||||
APP_DIR="/home/asf/testarena_backend"
|
||||
|
||||
echo "Restarting services in $APP_DIR..."
|
||||
|
||||
cd $APP_DIR || { echo "Directory $APP_DIR not found"; exit 1; }
|
||||
|
||||
# Restart containers without rebuilding
|
||||
echo "Restarting Docker containers..."
|
||||
docker-compose restart
|
||||
|
||||
echo "Services restarted successfully."
|
||||
Reference in New Issue
Block a user