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,551,907
Community Members
 
Community Events
184
Community Groups

Managing multiple node versions

I'm trying to figure out how to manage multiple node versions for a variety of different projects for our Bamboo server.

 

I can't seem to figure out how to include multiple versions of node from 0.10 to 5.0.0 in bamboo and have projects build from differing versions of node while managing the node_modules folder.

 

What is the best way to handle installing/handling multiple node versions and builds?

 

Thank you

2 answers

@Joseph Kim  how did you resolved the issue?? I used NVM. Just installed in my server and and when running bamboo task. It doesn't recognize nvm  or node as commands.

But when only node.js is installed , bamboo recognizes node command. 

Can you help me with that please... 

0 votes
nriley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Dec 02, 2015

NVM is a useful tool, depending on the complexity of the environment you are trying to test with:

https://github.com/creationix/nvm

This would allow you to declare a specific version of node via the command-line, and subsequently execute the corresponding code with whatever node_modules folder you needed.

I would suggest caching the request to the NVM script (from the link above) so you could control how this was being executed in your own environment (rather than relying on a 3rd party source).

nriley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Dec 02, 2015

To further develop this answer: If you were looking to do something which ran multiple versions of node on the same agent, you could bypass the node path and directly access the place that nvm stores the node binary and global node_modules. For each version of node, the path is switched accordingly. A question: Are you trying to run multiple versions of node in tandem with each other on the same agent? If so...why? Would a docker-ized solution work better for this kind of situation?

We'll try out the NVM solution just to try it out. We're trying to stay away from having to set up dockers. We have use cases across multiple versions of node and RHELS

how do you switch the node versions using the Bamboo Node.js Plugin?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events