Update deploy script
Deploy Frontend / build-and-deploy (push) Has been cancelled
Details
Deploy Frontend / build-and-deploy (push) Has been cancelled
Details
This commit is contained in:
parent
f10e69f964
commit
fc64f3a51f
|
|
@ -6,7 +6,8 @@ on:
|
|||
|
||||
env:
|
||||
REPO_DIR: "/workspace/ruspet_admin_frontend"
|
||||
REPO_URL: "https://72.56.235.246.nip.io/gitea/romanskijdev/admin_ruspet.git"
|
||||
# Обновлен URL и добавлена авторизация
|
||||
REPO_URL: "https://${{ github.actor }}:${{ github.token }}@git.ruspet-preforma.ru/romanskijdev/admin_ruspet.git"
|
||||
BUILD_DIR: "/var/www/admin.ruspet.tw1.ru"
|
||||
|
||||
jobs:
|
||||
|
|
@ -33,6 +34,8 @@ jobs:
|
|||
if [ -d "$REPO_DIR/.git" ]; then
|
||||
echo "📦 Updating existing repo..."
|
||||
cd "$REPO_DIR"
|
||||
# Принудительно задаем новый URL на случай, если папка уже существует со старым
|
||||
git remote set-url origin "$REPO_URL"
|
||||
git fetch origin
|
||||
git reset --hard origin/main
|
||||
else
|
||||
|
|
@ -98,7 +101,7 @@ jobs:
|
|||
|
||||
if [ "${{ job.status }}" == "success" ]; then
|
||||
echo "✅ Frontend deployment completed!"
|
||||
echo "🌐 Available at: https://admin.ruspet.tw1.ru"
|
||||
echo "🌐 Available at: https://panel.ruspet-preforma.ru"
|
||||
else
|
||||
echo "❌ Frontend deployment failed!"
|
||||
fi
|
||||
Loading…
Reference in New Issue