Files
desa-darmasaba/.github/workflows/send-mail.yml
2025-02-21 11:03:44 +08:00

34 lines
873 B
YAML

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