Skip to content

Deploy mdragon/1930-use-action-workflow-environment to Metabase dev #15

Deploy mdragon/1930-use-action-workflow-environment to Metabase dev

Deploy mdragon/1930-use-action-workflow-environment to Metabase dev #15

Workflow file for this run

name: Deploy Metabase
run-name: Deploy ${{ github.ref_name }} to Metabase ${{ inputs.environment || (github.event_name == 'release' && 'prod') || 'nonprod'}}
on:
workflow_dispatch:
inputs:
environment:
description: "target environment"
required: true
default: "dev"
type: choice
options:
- dev
- staging
- prod
image-tag:
description: "Metabase enterprise image tag to deploy"
required: true
type: string
jobs:
deploy:
name: Deploy
uses: ./.github/workflows/deploy-metabase.yml
strategy:
max-parallel: 1
fail-fast: false
matrix:
envs: ${{ inputs.environment != null && fromJSON(format('["{0}"]', inputs.environment)) || github.event_name == 'release' && fromJSON('["prod"]') || github.ref_name == 'main' && fromJSON('["dev", "staging"]') || fromJSON('["dev"]') }}
with:
version: ${{ inputs.image-tag }}
environment: ${{ matrix.envs }}
send-slack-notification:
if: failure()
needs: [deploy]
uses: ./.github/workflows/send-slack-notification.yml
secrets: inherit