From 5ce048feeb2f42a96e0540741085a23e3a9e32f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jens=20Winter-H=C3=BCbenthal?= Date: Thu, 4 Jan 2024 08:48:13 +0100 Subject: [PATCH] add environment input to workflow_dispatch --- .github/workflows/pumps.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pumps.yml b/.github/workflows/pumps.yml index 73098eb81..aef3c74b6 100644 --- a/.github/workflows/pumps.yml +++ b/.github/workflows/pumps.yml @@ -2,6 +2,15 @@ name: Update Pumps in Supabase Storage on: workflow_dispatch: + inputs: + environment: + type: choice + description: Environment + required: true + options: + - 'production' + - 'development' + default: 'production' repository_dispatch: # This action can be triggered via Github API webook (see https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#repository_dispatch) types: [pumps_cron] @@ -13,10 +22,12 @@ defaults: jobs: collect_pumps: - environment: "${{ github.event.client_payload.environment }}" + environment: "${{ github.event.client_payload.environment }} || ${{ github.event.inputs.environment }}" runs-on: ubuntu-latest name: A job to aggregate pumps data from open street maps and push to GDK Supabase steps: + - name: Print environment + run: echo "${{ github.event.client_payload.environment }} || ${{ github.event.inputs.environment }}" - name: Get the source uses: actions/checkout@v4 - name: build the harvester