#!/bin/bash set -e DEPLOY_DIR="/opt/homepage" REPO="git@bitbucket.org:zlalani/homepage.git" echo "=== Homepage Deploy ===" if [ ! -d "$DEPLOY_DIR/.git" ]; then echo "Cloning repository..." git clone "$REPO" "$DEPLOY_DIR" cd "$DEPLOY_DIR" else echo "Pulling latest changes..." cd "$DEPLOY_DIR" git pull origin dev fi mkdir -p config echo "Building and starting container..." docker compose build --no-cache docker compose up -d echo "Waiting for healthcheck..." sleep 15 docker compose ps echo "" echo "Done. Homepage available at https://optical-dev.oliver.solutions/homepage"