forked from Abdulbari/sgeUpdated
Update sgeupdated pipeline v23+++
This commit is contained in:
@@ -15,9 +15,6 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Deploy over SSH
|
||||
uses: appleboy/ssh-action@v1.0.3
|
||||
with:
|
||||
@@ -45,22 +42,22 @@ jobs:
|
||||
FRONTEND_CHANGED=false
|
||||
|
||||
# Check if backend folder changed
|
||||
if echo "$CHANGED_FILES" | grep -q "^sge-backend/"; then
|
||||
if echo "$CHANGED_FILES" | grep -q "^sgeUpdated/sge-backend/"; then
|
||||
BACKEND_CHANGED=true
|
||||
fi
|
||||
|
||||
# Check if frontend folder changed
|
||||
if echo "$CHANGED_FILES" | grep -q "^sge-frontend/"; then
|
||||
if echo "$CHANGED_FILES" | grep -q "^sgeUpdated/sge-frontend/"; then
|
||||
FRONTEND_CHANGED=true
|
||||
fi
|
||||
|
||||
# Backend section (currently commented out)
|
||||
# if [ "$BACKEND_CHANGED" = true ]; then
|
||||
# echo "⚡ Backend changes detected."
|
||||
# cd sge-backend
|
||||
# cd sgeUpdated/sge-backend
|
||||
# echo "Running Maven build..."
|
||||
# /opt/apache-maven-3.9.11/bin/mvn clean install -DskipTests
|
||||
# cd ../.. # back to /home/ubuntu/Bgreen
|
||||
# cd ../..
|
||||
# echo "Rebuilding backend Docker container..."
|
||||
# docker compose up -d --build bgreen-backend
|
||||
# else
|
||||
@@ -70,11 +67,11 @@ jobs:
|
||||
# Frontend section
|
||||
if [ "$FRONTEND_CHANGED" = true ]; then
|
||||
echo "⚡ Frontend changes detected."
|
||||
cd sge-frontend
|
||||
cd sgeUpdated/sge-frontend
|
||||
echo "Running npm build..."
|
||||
# npm install
|
||||
# npm run build
|
||||
cd ../.. # back to /home/ubuntu/Bgreen
|
||||
cd ../..
|
||||
echo "Rebuilding frontend Docker container..."
|
||||
docker compose up -d --build bgreen-frontend
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user