These are chat archives for creationix/nvm

11th
Dec 2017
Sam Korn
@sako0938
Dec 11 2017 17:06
Anyone know how to select an architecture with NVM? Using a service that cross compiles and wraps up a raspberry pi docker images, and the builder cannot find latest binaries for armv8, so it tries to compile which takes forever. I want to choose armv6

@charginghawk I am using this currently in my dockerfile:<code> ENV NVM_DIR /root/.nvm
ENV NODE_VERSION 8

#7

RUN curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.6/install.sh | bash \
&& source $NVM_DIR/nvm.sh \
&& nvm install $NODE_VERSION \
&& nvm alias default $NODE_VERSION \
&& nvm use default \
&& npm install http-server </code>

Jordan Harband
@ljharb
Dec 11 2017 19:43
@sako0938 there's no "select an architecture"; if nvm won't install on your arch, and there's no node compiler flags that can make it do so, then your arch isn't supported by node
Sam Korn
@sako0938
Dec 11 2017 19:45
My architecture is supported, ended up just not using nvm and including the lts binary for my architecture within my repo. My problem is related to having a different system building the image than actually running it.
Jordan Harband
@ljharb
Dec 11 2017 20:47
ah. yeah that's just always going to cause problems
your build machine should always be identical to your production machine, for tons of reasons