diff --git a/.github/workflows/podcast-api-pr.yml b/.github/workflows/podcast-api-pr.yml index 840de7d..03d90fa 100644 --- a/.github/workflows/podcast-api-pr.yml +++ b/.github/workflows/podcast-api-pr.yml @@ -23,6 +23,8 @@ jobs: build-pr: if: ${{ github.event_name == 'pull_request'}} + environment: + name: staging runs-on: ubuntu-latest steps: @@ -38,6 +40,8 @@ jobs: run: docker build -f ./src/Services/Podcasts/Podcast.Ingestion.Worker/Dockerfile -t ${{ env.ACR_NAME }}.azurecr.io/podcastingestionworker:${{ github.sha }} . build-and-push: + environment: + name: staging runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 @@ -79,8 +83,7 @@ jobs: deploy: needs: build-and-push environment: - name: prod - if: ${{ github.ref == 'refs/heads/main' && (github.event_name == 'push' || github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch') }} + name: staging runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/podcast-hub-pr.yml b/.github/workflows/podcast-hub-pr.yml index 082bc03..7d6b04b 100644 --- a/.github/workflows/podcast-hub-pr.yml +++ b/.github/workflows/podcast-hub-pr.yml @@ -20,6 +20,7 @@ env: jobs: build: + if: ${{ github.event_name == 'pull_request'}} runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 @@ -44,7 +45,7 @@ jobs: deploy: needs: build environment: - name: prod + name: staging runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/podcast-web-pr.yml b/.github/workflows/podcast-web-pr.yml index c2cc70f..21d9322 100644 --- a/.github/workflows/podcast-web-pr.yml +++ b/.github/workflows/podcast-web-pr.yml @@ -15,6 +15,7 @@ env: jobs: build: + if: ${{ github.event_name == 'pull_request'}} environment: name: staging runs-on: ubuntu-latest