| # === Get Nodejs pinned LTS version via NVM |
| RUN curl --silent -o- https://raw.githubusercontent.com/creationix/nvm/v0.35.3/install.sh | bash |
| && nvm alias default lts/* \ |
| ENV NODE_PATH $NVM_DIR/v$NODE_VERSION/lib/node_modules |
| ENV PATH $NVM_DIR/versions/node/v$NODE_VERSION/bin:$PATH |
| # === Install depot_tools |
| RUN git clone https://cobalt.googlesource.com/depot_tools /depot_tools |
| # === Configure common env vars |
| ENV PATH="${PATH}:/depot_tools:/root/fake_goma" \ |
| NINJA_STATUS="[%f/%t %c/sec] " \ |
| CCACHE_DIR=/root/ccache \ |
| # == Set up gclient and fake Goma with ccache |
| COPY ./files/fake_goma /root/fake_goma |
| RUN cd /tmp && gclient verify || true \ |
| && chmod +x /root/fake_goma/gomacc /root/fake_goma/goma_ctl.py \ |
| CMD ["/usr/bin/python","--version"] |