Skip to content

Test providers RC releases #922

Test providers RC releases

Test providers RC releases #922

---
name: Test providers RC releases
on: # yamllint disable-line rule:truthy
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
inputs:
rc_testing_branch:
# If a branch is given, the workflow will use it for deployment and testing.
# If no branch is provided, the workflow will create a new rc testing branch
# for deployment and testing.
description: |
rc_testing_branch: existing testing branch
(Either rc_testing_branch or issue_url is required, and you cannot give both.)
required: false
default: ""
issue_url:
description: |
issue_url: the GitHub issue URL that tracks the status of Providers release
(Either rc_testing_branch or issue_url is required, and you cannot give both.)
required: false
base_git_rev:
description: "The base git revision to test Providers RCs"
required: false
type: string
default: "main"
jobs:
check-airflow-provider-rc-release:
uses: ./.github/workflows/reuse-wf-check-rc-release.yaml
with:
rc_testing_branch: ${{ inputs.rc_testing_branch }}
issue_url: ${{ inputs.issue_url }}
base_git_rev: ${{ inputs.base_git_rev }}
git_email: "[email protected]"
git_username: "airflow-oss-bot"
secrets:
BOT_ACCESS_TOKEN: ${{ secrets.BOT_ACCESS_TOKEN }}
deploy-rc-testing-branch-to-astro-cloud:
needs: check-airflow-provider-rc-release
if: |
always() &&
(
needs.check-airflow-provider-rc-release.outputs.rc_issue_url != '' ||
inputs.issue_url != ''
) &&
needs.check-airflow-provider-rc-release.outputs.no_provider_changed != 'true'
uses: ./.github/workflows/reuse-wf-deploy-to-astro-cloud.yaml
with:
git_rev: ${{ needs.check-airflow-provider-rc-release.outputs.rc_testing_branch }}
environment_to_deploy: "providers-integration-tests"
secrets:
docker_registry: ${{ secrets.DOCKER_REGISTRY }}
organization_id: ${{ secrets.ORGANIZATION_ID }}
deployment_id: ${{ secrets.PROVIDER_INTEGRATION_TESTS_DEPLOYMENT_ID }}
bearer_token: ${{ secrets.BEARER_TOKEN }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
wait-for-deployment-to-be-ready-and-trigger-master-dag:
needs:
[
deploy-rc-testing-branch-to-astro-cloud,
check-airflow-provider-rc-release,
]
if: |
always() &&
needs.deploy-rc-testing-branch-to-astro-cloud.result == 'success'
uses: ./.github/workflows/reuse-wf-trigger-dag.yaml
with:
git_rev: ${{ needs.check-airflow-provider-rc-release.outputs.rc_testing_branch }}
dags_to_trigger_after_deployment: "example_master_dag"
secrets:
astro_subdomain: ${{ secrets.ASTRO_SUBDOMAIN }}
deployment_id: ${{ secrets.PROVIDER_INTEGRATION_TESTS_DEPLOYMENT_ID }}
bearer_token: ${{ secrets.BEARER_TOKEN }}
organization_id: ${{ secrets.ORGANIZATION_ID }}
deploy-rc-testing-branch-to-astro-cloud-on-GCP:
needs: check-airflow-provider-rc-release
if: |
always() &&
(
needs.check-airflow-provider-rc-release.outputs.rc_issue_url != '' ||
inputs.issue_url != ''
) &&
needs.check-airflow-provider-rc-release.outputs.no_provider_changed != 'true'
uses: ./.github/workflows/reuse-wf-deploy-to-astro-cloud.yaml
with:
git_rev: ${{ needs.check-airflow-provider-rc-release.outputs.rc_testing_branch }}
environment_to_deploy: "providers-integration-tests"
secrets:
docker_registry: ${{ secrets.DOCKER_REGISTRY }}
organization_id: ${{ secrets.ORGANIZATION_ID }}
deployment_id: ${{ secrets.PROVIDER_INTEGRATION_TESTS_GCP_DEPLOYMENT_ID }}
bearer_token: ${{ secrets.BEARER_TOKEN }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
wait-for-deployment-to-be-ready-and-trigger-master-dag-on-GCP:
needs:
[
deploy-rc-testing-branch-to-astro-cloud,
check-airflow-provider-rc-release,
]
if: |
always() &&
needs.deploy-rc-testing-branch-to-astro-cloud.result == 'success'
uses: ./.github/workflows/reuse-wf-trigger-dag.yaml
with:
git_rev: ${{ needs.check-airflow-provider-rc-release.outputs.rc_testing_branch }}
dags_to_trigger_after_deployment: "example_master_dag"
secrets:
astro_subdomain: ${{ secrets.ASTRO_SUBDOMAIN }}
deployment_id: ${{ secrets.PROVIDER_INTEGRATION_TESTS_GCP_DEPLOYMENT_ID }}
organization_id: ${{ secrets.ORGANIZATION_ID }}
bearer_token: ${{ secrets.BEARER_TOKEN }}