Skip to content

Commit

Permalink
fix: remove diff check (#110)
Browse files Browse the repository at this point in the history
always build and deploy binary for every merge to main
  • Loading branch information
talentedmrjones authored Sep 4, 2024
1 parent 3871013 commit aecb40e
Showing 1 changed file with 2 additions and 26 deletions.
28 changes: 2 additions & 26 deletions .github/workflows/orchestration-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,32 +7,10 @@ on:
types:
- closed

jobs:
diff:
if: ${{ github.event.pull_request.merged }}
name: Check for Changes
runs-on: ubuntu-latest
outputs:
backend: ${{ steps.backend.outputs.backend }}
infrastructure: ${{ steps.infrastructure.outputs.infrastructure }}
steps:
- name: Check out repo
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Check for changes in backend/
id: backend
run: echo "backend=$(git --no-pager diff --name-only origin/main backend/ | grep ".go\|.sum\|Dockerfile" | head -n 1)" >> $GITHUB_OUTPUT

- name: Check for changes in infrastructure/
id: infrastructure
run: echo "infrastructure=$(git --no-pager diff --name-only origin/main infrastructure/ | grep ".tf\|.tfvars" | head -n 1)" >> $GITHUB_OUTPUT

jobs:
backend:
if: ${{ github.event.pull_request.merged }}
name: Backend
needs: diff
if: contains(needs.diff.outputs.backend, 'backend/')
uses: ./.github/workflows/backend.yml
with:
environment: PROD
Expand All @@ -42,9 +20,7 @@ jobs:
infrastructure:
name: Infrastructure
needs:
- diff
- backend
if: contains(needs.diff.outputs.infrastructure, 'infrastructure/') || !cancelled()
uses: ./.github/workflows/infrastructure.yml
with:
environment: PROD
Expand Down

0 comments on commit aecb40e

Please sign in to comment.