From d2dd201e6148fcbabbf6c0be430c062d1b769c2c Mon Sep 17 00:00:00 2001 From: shenlan Date: Mon, 29 Sep 2025 13:07:19 +0800 Subject: [PATCH] Add deployment inputs and PR triggers to IAC workflows --- ...ipeline-alicloud-landingzone-baseline.yaml | 21 ++++++++++++++++++ ...peline-infrastructure-monitor-exporter.yml | 22 ++++++++++++++----- ...pipeline-infrastructure-monitor-server.yml | 20 +++++++++++++---- 3 files changed, 53 insertions(+), 10 deletions(-) diff --git a/.github/workflows/iac-pipeline-alicloud-landingzone-baseline.yaml b/.github/workflows/iac-pipeline-alicloud-landingzone-baseline.yaml index b0d9099d..90960208 100644 --- a/.github/workflows/iac-pipeline-alicloud-landingzone-baseline.yaml +++ b/.github/workflows/iac-pipeline-alicloud-landingzone-baseline.yaml @@ -6,7 +6,28 @@ on: - 'iac_modules/pulumi/**' - 'config/alicloud/**' - '.github/workflows/iac-pipeline-alicloud-landingzone-baseline.yaml' + pull_request: + branches: [main] workflow_dispatch: + inputs: + deploy_action: + description: "Deployment action to execute" + type: choice + options: + - init + - magrate + - upgrade + - backup + - restore + - destroy + default: upgrade + deploy_dry_run: + description: "Run deployment steps in dry-run mode" + type: choice + options: + - 'true' + - 'false' + default: 'true' env: PULUMI_CI: 'true' diff --git a/.github/workflows/iac-pipeline-infrastructure-monitor-exporter.yml b/.github/workflows/iac-pipeline-infrastructure-monitor-exporter.yml index cfb15778..d313880e 100644 --- a/.github/workflows/iac-pipeline-infrastructure-monitor-exporter.yml +++ b/.github/workflows/iac-pipeline-infrastructure-monitor-exporter.yml @@ -1,17 +1,27 @@ name: Deploy Infrastructure Monitor Exporters on: + pull_request: + branches: [main] workflow_dispatch: - branches: - - main inputs: deploy_action: - description: 'Deployment action to perform' - required: false + description: "Deployment action to execute" + type: choice + options: + - init + - magrate + - upgrade + - backup + - restore + - destroy default: upgrade deploy_dry_run: - description: 'Whether to perform a dry-run' - required: false + description: "Run deployment steps in dry-run mode" + type: choice + options: + - 'true' + - 'false' default: 'true' jobs: diff --git a/.github/workflows/iac-pipeline-infrastructure-monitor-server.yml b/.github/workflows/iac-pipeline-infrastructure-monitor-server.yml index d99d4f1c..eb4185aa 100644 --- a/.github/workflows/iac-pipeline-infrastructure-monitor-server.yml +++ b/.github/workflows/iac-pipeline-infrastructure-monitor-server.yml @@ -4,13 +4,25 @@ on: workflow_dispatch: inputs: deploy_action: - description: "Action to perform (upgrade, destroy, etc.)" - required: false + description: "Deployment action to execute" + type: choice + options: + - init + - magrate + - upgrade + - backup + - restore + - destroy default: upgrade deploy_dry_run: - description: "Run Ansible in check mode" - required: false + description: "Run deployment steps in dry-run mode" + type: choice + options: + - 'true' + - 'false' default: 'true' + pull_request: + branches: [main] push: branches: - main