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
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
Hello @Vadym Polietaiev !
And thanks for reaching out to Atlassian Community!
It's definitely possible to use stages in custom-triggered branches to have multi-step deployments.
From your example YML file, I see you are also leveraging YML anchors to define the steps, so let me share with you an example using a custom-triggered pipeline containing a normal step, and a deployment stage using step anchors :
- step: &deploy
- echo "Deploying"
- step: &restart-services
name: Restart services
- echo "Restarting services"
name: Build and test
- echo "Building and testing"
name: Deploy to test environment
- step: *deploy
- step: *restart-services
You can find additional examples of using stages in our official documentation below :
Also, while creating/editing your YML file, if you would like to validate if the syntax is correct before pushing it to the repository, I recommend using the Bitbucket Pipelines validator tool, so if there is any syntax error in the YML file you can catch it beforehand.
Hope that helps! Let me know in case you have any questions.
Thank you, @Vadym Polietaiev !