diff --git a/.github/workflows/amplify-deploy.yml b/.github/workflows/amplify-deploy.yml index 825d7b03a..893057770 100644 --- a/.github/workflows/amplify-deploy.yml +++ b/.github/workflows/amplify-deploy.yml @@ -9,7 +9,7 @@ on: - master jobs: - # Testing + # Testing (Runs automatically on push/PR) test: runs-on: ubuntu-latest @@ -29,17 +29,17 @@ jobs: run: npm run lint --if-present - name: Run Tests - run: npm test -- --watchAll=false # Ensures CI doesn't hang on watch mode + run: npm test -- --watchAll=false - # Deployment (Only runs if 'test' passes) + # Deployment (Waits for manual approval after 'test' passes) deploy: runs-on: ubuntu-latest needs: test - if: github.event_name == 'push' + environment: production steps: - name: Trigger webhook using curl env: WEBHOOK_URL: ${{ secrets.AMPLIFY_WEBHOOK_URL }} run: | - curl -i --fail -X POST -H "Content-Type: application/json" -d '{}' "$WEBHOOK_URL" + curl -i --fail -X POST -H "Content-Type: application/json" -d '{}' "$WEBHOOK_URL" \ No newline at end of file