diff --git a/docker/build/Dockerfile b/docker/build/Dockerfile index a86ce1b9c..b0b2ee0c9 100644 --- a/docker/build/Dockerfile +++ b/docker/build/Dockerfile @@ -14,6 +14,7 @@ ARG ANCHOR_CLI ENV HOME="/root" ENV PATH="${HOME}/.cargo/bin:${PATH}" ENV PATH="${HOME}/.local/share/solana/install/active_release/bin:${PATH}" +ENV PATH="${HOME}/.nvm/versions/node/v16.8.0/bin:${PATH}" # Install base utilities. RUN mkdir -p /workdir && mkdir -p /tmp && \ @@ -26,6 +27,15 @@ RUN curl "https://sh.rustup.rs" -sfo rustup.sh && \ sh rustup.sh -y && \ rustup component add rustfmt clippy +# Install node / npm / yarn. +RUN curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash +ENV NVM_DIR="${HOME}/.nvm" +RUN . $NVM_DIR/nvm.sh && \ + nvm install node --latest-npm && \ + nvm use node && \ + nvm alias default node && \ + npm install -g yarn + # Install Solana tools. RUN sh -c "$(curl -sSfL https://release.solana.com/${SOLANA_CLI}/install)"