[github-actions] remove conditional job execution
@@ -68,7 +68,6 @@ jobs:
name: Deploy Apps
runs-on: [k8s, deployer, "${{ needs.pre.outputs.runner }}"]
needs: pre
- if: ${{ needs.pre.outputs.isTag == 'true' }}
container:
image: dysnix/kubectl:v1.19-gcloud
@@ -80,9 +79,11 @@ jobs:
steps:
-
+ if: ${{ needs.pre.outputs.isTag == 'true' }}
name: Create ~/.kube/config
run: mkdir -p ~/.kube && echo "$KUBECONF" | base64 -d > ~/.kube/config
-
+ if: ${{ needs.pre.outputs.isTag == 'true' }}
name: Clone helm-infra
uses: actions/checkout@v2
with:
@@ -91,6 +92,7 @@ jobs:
ref: master
token: ${{ secrets.GH_TOKEN }}
-
+ if: ${{ needs.pre.outputs.isTag == 'true' }}
name: Deploy apps
working-directory: helm-infra
run: |
@@ -100,25 +102,25 @@ jobs:
UPDATE_REPOS=y helmfile -e $HFENV repos
helmfile -e $HFENV $DEPLOY_APPS apply --args "timeout 180s"
-
+ if: success() && needs.pre.outputs.isTag == 'true'
name: Update deployment status (success)
- if: success()
uses: chrnorm/deployment-status@releases/v1
with:
token: ${{ github.token }}
state: success
deployment_id: ${{ github.event.deployment.id }}
-
+ if: failure() && needs.pre.outputs.isTag == 'true'
name: Update deployment status (failure)
- if: failure()
uses: chrnorm/deployment-status@releases/v1
with:
token: ${{ github.token }}
state: failure
deployment_id: ${{ github.event.deployment.id }}
-
+ if: failure() && needs.pre.outputs.isTag == 'true'
name: Notify to Mattermost (on failure)
uses: tferreira/matterfy@releases/v1
- if: failure()
with:
type: ${{ job.status }}
job_name: '*Deployment to "${{ github.event.deployment.environment }}" failed*'
