This commit is contained in:
@@ -38,23 +38,19 @@ jobs:
|
|||||||
- name: Send success email
|
- name: Send success email
|
||||||
if: success()
|
if: success()
|
||||||
run: |
|
run: |
|
||||||
|
cat > /tmp/email.txt << 'ENDMAIL'
|
||||||
|
From: GitHub Actions
|
||||||
|
To: raghu6004@gmail.com
|
||||||
|
Subject: Deployment Successful - Portfolio
|
||||||
|
|
||||||
|
Deployment completed successfully!
|
||||||
|
ENDMAIL
|
||||||
|
|
||||||
curl --ssl-reqd \
|
curl --ssl-reqd \
|
||||||
--url "smtps://smtp.gmail.com:465" \
|
--url "smtps://smtp.gmail.com:465" \
|
||||||
--user "${{ secrets.EMAIL_USERNAME }}:${{ secrets.EMAIL_PASSWORD }}" \
|
--user "${{ secrets.EMAIL_USERNAME }}:${{ secrets.EMAIL_PASSWORD }}" \
|
||||||
--mail-from "${{ secrets.EMAIL_USERNAME }}" \
|
--mail-from "${{ secrets.EMAIL_USERNAME }}" \
|
||||||
--mail-rcpt "your-email@example.com" \
|
--mail-rcpt "raghu6004@gmail.com" \
|
||||||
--upload-file - <<'EOF'
|
--upload-file /tmp/email.txt
|
||||||
From: GitHub Actions <${{ secrets.EMAIL_USERNAME }}>
|
|
||||||
To: your-email@example.com
|
|
||||||
Subject: Deployment Successful - Portfolio
|
|
||||||
|
|
||||||
Deployment completed successfully!
|
rm /tmp/email.txt
|
||||||
|
|
||||||
Repository: ${{ github.repository }}
|
|
||||||
Branch: ${{ github.ref_name }}
|
|
||||||
Commit: ${{ github.sha }}
|
|
||||||
Workflow: ${{ github.workflow }}
|
|
||||||
Run: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
|
|
||||||
|
|
||||||
Time: $(date)
|
|
||||||
EOF
|
|
||||||
|
|||||||
Reference in New Issue
Block a user