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,559,659
Community Members
 
Community Events
185
Community Groups

npm: command not found

Edited

Hi. I have some troubles with bitbucket pipeline. I enabled pipeline. Added yml script (see attachment).

Run build. Build was success, but now I has an error "npm: command not found"

Could you help me with it please?

yml file content:

# This is a sample build configuration for Javascript (Node.js).
# Check our guides at https://confluence.atlassian.com/x/14UWN for more examples.
# Only use spaces to indent your .yml configuration.
# -----
# You can specify a custom docker image from Docker Hub as your build environment.
image: node:6.9.4

pipelines:
  default:
    - step:
        script: # Modify the commands below to build your repository.
          - npm install

 

4 comments

I am having same issue

I had to add the the registry with the auth token in the .npmrc and .NPMRC_CONFIG. I don't know if both were required, but I did it that way and am not messing with it. 

//registry.npmjs.org/:_authToken=${NPM_TOKEN}

Explained here: https://confluence.atlassian.com/bitbucket/javascript-node-js-with-bitbucket-pipelines-873891287.html 

I went to npmjs.com and registered and account, generate the token and created a .npmrc file in the same folder as the package.json file. put the following line in that file

 

//registry.npmjs.org/:_authToken=${NPM_TOKEN}

with my own token, but the pipeline still failed with "npm not found"

 

any idea?

Did you find any solution for this?

any solution for this guys?

Comment

Log in or Sign up to comment
TAGS
AUG Leaders

Atlassian Community Events