Publish #9
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Publish" | |
on: | |
workflow_dispatch: | |
inputs: | |
deploy-to: | |
description: "Choose whether to deploy to test or prod" | |
type: environment | |
default: "prod" | |
branch: | |
description: "Choose the branch to release from" | |
type: string | |
default: "main" | |
pypi-internal: | |
description: "Publish Internally" | |
type: boolean | |
default: true | |
pypi-public: | |
description: "Publish to PyPI" | |
type: boolean | |
default: false | |
# don't attempt to release the same target in parallel | |
concurrency: | |
group: ${{ github.workflow }}-${{ inputs.deploy-to }} | |
cancel-in-progress: true | |
jobs: | |
unit-tests: | |
uses: ./.github/workflows/unit-tests.yml | |
with: | |
branch: ${{ inputs.branch }} | |
integration-tests: | |
uses: ./.github/workflows/integration-tests.yml | |
with: | |
branch: ${{ inputs.branch }} | |
repository: ${{ github.repository }} | |
secrets: inherit | |
publish-internal: | |
if: ${{ inputs.pypi-internal == 'true' }} | |
needs: [unit-tests, integration-tests] | |
uses: ./.github/workflows/publish-internal.yml | |
with: | |
deploy-to: ${{ inputs.deploy-to }} | |
branch: ${{ inputs.branch }} | |
publish-pypi: | |
if: ${{ inputs.pypi-public == 'true' }} | |
needs: [unit-tests, integration-tests] | |
uses: ./.github/workflows/publish-pypi.yml | |
with: | |
deploy-to: ${{ inputs.deploy-to }} | |
branch: ${{ inputs.branch }} | |
publish-pypi-dbt-athena-community: | |
if: ${{ inputs.pypi-public == 'true' }} | |
# dbt-athena-community is hard pinned to dbt-athena to ensure they are the same | |
# this means we need to finish publishing dbt-athena before starting to build dbt-athena-community | |
needs: publish-pypi | |
uses: ./.github/workflows/publish-pypi.yml | |
with: | |
package: "dbt-athena-community" | |
deploy-to: ${{ inputs.deploy-to }} | |
branch: ${{ inputs.branch }} |