From 70d895a3a0fa38d86bcba3c8760348602486a3e0 Mon Sep 17 00:00:00 2001 From: Paolo Date: Fri, 25 Nov 2022 16:09:04 +0000 Subject: [PATCH] feat: allow to pass mailprovider as a workflow input --- .github/workflows/cron-storage-limits.yaml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/cron-storage-limits.yaml b/.github/workflows/cron-storage-limits.yaml index 3ad382387b..e845e01caf 100644 --- a/.github/workflows/cron-storage-limits.yaml +++ b/.github/workflows/cron-storage-limits.yaml @@ -7,6 +7,13 @@ on: # Including 'workflow_dispatch' here allows the job to be triggered manually, # as well as on the schedule. workflow_dispatch: + inputs: + email_provider: + type: choice + description: The mail provider used to send emails to users. Use 'dummy' if you want only to log emails to the console. If not specified the default mail provider is used in prod and the dummy one is used in staging. + options: + - mailchimp + - dummy jobs: send-notifications: @@ -42,6 +49,6 @@ jobs: PROD_PG_REST_URL: ${{ secrets.PROD_PG_REST_URL }} STAGING_PG_REST_URL: ${{ secrets.STAGING_PG_REST_URL }} MAILCHIMP_API_KEY: ${{ secrets.MAILCHIMP_API_KEY }} - EMAIL_PROVIDER: ${{ (matrix.env == 'staging' && 'dummy') || '' }} # use dummy provider in staging, while using the default provider in prod. + EMAIL_PROVIDER: ${{ github.event.inputs.env || ((matrix.env == 'staging' && 'dummy') || '') }} # use dummy provider in staging, while using the default provider in prod. run: npm run start:storage -w packages/cron