diff --git a/.github/actions/send-email/dist/index.js b/.github/actions/send-email/dist/index.js index 22a6566c3f..d1817b6db8 100644 --- a/.github/actions/send-email/dist/index.js +++ b/.github/actions/send-email/dist/index.js @@ -276,7 +276,14 @@ function sendEmail(config) { }); return mg.messages - .create(domain, config) + .create(config.domain, { + from: config.from, + to: config.to, + cc: config.cc, + subject: config.subject, + text: config.text, + html: config.html, + }) .then((resp) => { core.setOutput('response', resp.message); return; diff --git a/.github/actions/send-email/index.js b/.github/actions/send-email/index.js index c898a55d8d..38be9f04fc 100644 --- a/.github/actions/send-email/index.js +++ b/.github/actions/send-email/index.js @@ -56,7 +56,14 @@ function sendEmail(config) { }); return mg.messages - .create(domain, config) + .create(config.domain, { + from: config.from, + to: config.to, + cc: config.cc, + subject: config.subject, + text: config.text, + html: config.html, + }) .then((resp) => { core.setOutput('response', resp.message); return; diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 6dd267cc3b..3f440bcc1f 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -16,8 +16,11 @@ name: Nightly Builds on: # Runs every day at 06:00 AM (PT) and 08:00 PM (PT) / 04:00 AM (UTC) and 02:00 PM (UTC) + # or on 'firebase_build' repository dispatch event. schedule: - cron: "0 4,14 * * *" + repository_dispatch: + types: [firebase_build] jobs: nightly: @@ -75,11 +78,11 @@ jobs: domain: ${{ secrets.OSS_BOT_MAILGUN_DOMAIN }} from: 'GitHub ' to: ${{ secrets.FIREBASE_ADMIN_GITHUB_EMAIL }} - subject: '[${{github.repository}}] Nightly build failed!' + subject: 'Nightly build ${{github.run_id}} of ${{github.repository}} failed!' html: > - Nightly workflow failed on: ${{github.repository}} + Nightly workflow ${{github.run_id}} failed on: ${{github.repository}}

Navigate to the - failed workflow. + failed workflow. continue-on-error: true - name: Send email on cancelled @@ -90,9 +93,9 @@ jobs: domain: ${{ secrets.OSS_BOT_MAILGUN_DOMAIN }} from: 'GitHub ' to: ${{ secrets.FIREBASE_ADMIN_GITHUB_EMAIL }} - subject: '[${{github.repository}}] Nightly build got cancelled!' + subject: 'Nightly build ${{github.run_id}} of ${{github.repository}} cancelled!' html: > - Nightly workflow cancelled on: ${{github.repository}} + Nightly workflow ${{github.run_id}} cancelled on: ${{github.repository}}

Navigate to the - cancelled workflow. + cancelled workflow. continue-on-error: true