Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding V8 engine to webassembly container in order to run trimming tests #409

Merged
merged 1 commit into from
Feb 17, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/ubuntu/18.04/webassembly/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,13 @@ RUN git clone https://github.com/emscripten-core/emsdk.git ${EMSDK_PATH} \
&& ./emsdk install ${EMSCRIPTEN_VERSION}-upstream \
&& ./emsdk activate ${EMSCRIPTEN_VERSION}-upstream \
&& chmod -R 777 ${EMSDK_PATH}

# Install V8 Engine to be able to execute Trimming Tests
RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - \
&& apt install -y nodejs \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Installing nodejs shouldn't be necessary. It's already installed in the base image at

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True but for v8 engine we will need npm 10+ which will only be available after the previouse curl command. After running that, the apt install nodejs will install the new npm which will be able to install the v8 engine. With the nodejs that is preinstalled in the container we can't install v8.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@joperezr we don't need to install v8 from npm/jsvu, for the helix queue we just download the binary from blob storage: https://dev.azure.com/dnceng/internal/_git/dotnet-helix-machines?path=%2Fartifacts%2Flinux-v8-engine%2Flinux-v8-engine.sh&_a=contents&version=GBmaster

&& npm install jsvu -g \
&& export PATH="${HOME}/.jsvu:${PATH}" \
&& jsvu --os=linux64 --engines=javascriptcore,spidermonkey,v8 \
&& rm -rf /var/lib/apt/lists/*

ENV PATH="/root/.jsvu:${PATH}"