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,554,229
Community Members
 
Community Events
184
Community Groups

Pipelines seems to execute nvm use after every step

I noticed the following message after every step in my pipeline:

N/A: version "v18" is not yet installed

 Which seemed strange because I am not using nvm use in any step of my pipeline. But the message seems to be from nvm.

You can reproduce this by creating an empty repository with only a .nvmrc file and a very simple bitbucket-pipelines.yml like this.

.nvmrc

18

bitbucket-pipelines.yml

pipelines:
default:
- step:
name: Test
script:
- exit 0

Without any other code the pipeline logs the nvm message two times!

Why? Is there any documentation that states any nvm integration into Bitbucket Pipelines?

1 answer

0 votes
Patrik S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Apr 11, 2023

Hello @timspiekerkoetter ,

Thank you for reaching out to Atlassian Community!

The atlassian/default-image:1, that is the image use by default if you don't specify any in your YML file, does come with nvm, but pipelines itself does not specify a node version.

Since you have a .nvmrc file in the repository, nvm will try to use the node version specified in that file, which in your example was v18. As the atlassian/default-image:1 does not come with Node 18, nvm is throwing the error that this particular version was not found. 

For further details on what is included in each version of atlassian/default-image you can refer to Pipelines - Default build environment.

In order to get rid of that error, you can use a different docker image in your step that either does not use nvm or that contains the node version that you are specifying in the .nvmrc file, as in the example below : 

pipelines:
default:
- step:
name: Using image that contains node 18
image: node:18.0.0
script:
- exit 0
- step:
name: Using image that does not use nvm
image: ubuntu:latest
script:
- exit 0

Hope that helps! Let me know in case you have any questions.

Thank you, @timspiekerkoetter !

Patrik S

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events