You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
We are using pipelines to run E2E tests. When it fails, bitbucket sends email notification. We would like to receive a zipped file attached to this email. E2E tools generate reports, we would like to get these reports to see what went wrong. How to achieve this?
@Oleksandr Kyrdan hi! Could you help me please?
I have done everything as you write above, but somehow when Pipeline try to find an attachment - it shows an error.
Here is my ymlFile, can you please tell me - what I have write wrong so attachment doesn't loads.
Thank you! And Happy New Year! And Merry Christmas!)
UPDATE
Have added full path to the file and it looks like it works. However the email is not send anyway
Hi @Marek Zielonkowski ,
Thank you for your question!
It's a good case to use the email-notify pipe.
You can use $BITBUCKET_EXIT_CODE variable in the after-script section.
$BITBUCKET_EXIT_CODE - the exit code of a step, if step success value setup to 0.
script:
- <your test logic>
- pytest test/test.py --junitxml=test-reports/report.xml
- zip -r test-reports.zip test-reports
after-script:
- ALERT_TYPE="success"
- if [[ $BITBUCKET_EXIT_CODE -ne 0 ]]; then ALERT_TYPE="error" ; fi
- pipe: atlassian/email-notify:0.3.11
variables:
USERNAME: 'myemail@example.com'
PASSWORD: $PASSWORD
FROM: 'myemail@example.com'
TO: 'example@example.com'
HOST: 'smtp.gmail.com'
SUBJECT: '${ALERT_TYPE}:Bitbucket Pipe Notification for ${BITBUCKET_BRANCH}'
ATTACHMENTS: 'test-reports.zip'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.