From 35b28feb9cecab2816bd93e45603c83aa3807b63 Mon Sep 17 00:00:00 2001 From: bip production <119274726+bipproduction@users.noreply.github.com> Date: Fri, 21 Feb 2025 11:03:44 +0800 Subject: [PATCH] Create send-mail.yml --- .github/workflows/send-mail.yml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/send-mail.yml diff --git a/.github/workflows/send-mail.yml b/.github/workflows/send-mail.yml new file mode 100644 index 00000000..c90dfadf --- /dev/null +++ b/.github/workflows/send-mail.yml @@ -0,0 +1,33 @@ +name: CI/CD Pipeline with Email Notification + +on: + push: + branches: + - main + pull_request: + branches: + - main + +jobs: + send-email: + runs-on: ubuntu-latest + + steps: + # Send email notification + - name: Send email notification + uses: dawidd6/action-send-mail@v3 + with: + server_address: smtp.gmail.com + server_port: 587 + username: ${{ secrets.GMAIL_USERNAME }} + password: ${{ secrets.GMAIL_APP_PASSWORD }} + subject: "GitHub Actions Deployment Log" + body: | + The deployment process has completed successfully. + Please find the details below: + + Repository: ${{ github.repository }} + Branch: ${{ github.ref }} + Commit: ${{ github.sha }} + to: your-email@example.com + from: your-email@gmail.com