Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,467,417
Community Members
 
Community Events
177
Community Groups

Bitbucket Pipeline does not trigger on push

Edited

I have the following Bitbucket Pipeline in place.
But whenever I push to the master branch it does not trigger the pipeline.

I need to manually trigger the pipeline, and if I do so it works fine. But I want to make sure on every commit it triggers the pipeline automatically.

Content of bitbucket-pipelines.yml
Note: The code below is valid & have checked it here


image: node:16

pipelines:
branches:
default:
- step:
name: Build & Deploy to netlify
caches:
- node
script:
- npm install
- npm run lint
- npm run build-prod
- apt-get update
- apt-get install zip
- ls -a
- cd out
- zip -r build.zip *
- zip -sf build.zip
- curl --location --request POST "URL" --header "Content-Type:application/zip" --header "Authorization:Bearer Token" --data-binary "@build.zip"





Bitbucket-Pipelines-Validator.png
I've pipelines enabled as well, you can check that here:
front-end-Settings-—-Bitbucket.png
Also here are the request logs for the PUSH trigger of bitbucket.
 front-end-—-Bitbucket.png

3 answers

1 accepted

0 votes
Answer accepted

UPDATE:

Sometimes pipelines trigger with delay, so be patient with that and see after a few minutes, and in case of active bitbucket incidents, you can wait for it to get fixed.

- Pipeline started triggering automatically the day after.

That was strange and I also tried creating a new repository, but it didn't work there as well.

1 vote
Pramodh M Community Leader Jan 28, 2022

Hi @Lav Shah 

Welcome to the Community!!

Go ahead and try this starter template

#  Template NodeJS build
#  This template allows you to validate your NodeJS code.
#  The workflow allows running tests and code linting on the default branch.

image: node:16
pipelines:
  default:
    - parallel:
        - step:
            name: Build and Test
            caches:
              - node
            script:
              - npm install
              - npm test
        - step:
            name: Code linting
            script:
              - npm install eslint
              - npx eslint .
            caches:
              - node

Thanks,
Pramodh

Have you tried changing default to master?

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events