mirror of
https://github.com/zama-ai/tfhe-rs.git
synced 2026-01-09 14:47:56 -05:00
chore(ci): fix firefox wasm benchmarks with new aws ami
Some libs were missing to be able to run Firefox out of the box. Besides, action runner is now installed as ubuntu user since Firefox is not able to run as root.
This commit is contained in:
7
.github/workflows/aws_tfhe_fast_tests.yml
vendored
7
.github/workflows/aws_tfhe_fast_tests.yml
vendored
@@ -156,10 +156,6 @@ jobs:
|
||||
persist-credentials: 'false'
|
||||
token: ${{ secrets.FHE_ACTIONS_TOKEN }}
|
||||
|
||||
- name: Set up home
|
||||
run: |
|
||||
echo "HOME=/home/ubuntu" >> "${GITHUB_ENV}"
|
||||
|
||||
- name: Install latest stable
|
||||
uses: dtolnay/rust-toolchain@7b1c307e0dcbda6122208f10795a713336a9b35a
|
||||
with:
|
||||
@@ -198,7 +194,8 @@ jobs:
|
||||
- name: Run js on wasm API tests
|
||||
if: needs.should-run.outputs.wasm_test == 'true'
|
||||
run: |
|
||||
make test_nodejs_wasm_api_in_docker
|
||||
make install_node
|
||||
make test_nodejs_wasm_api_ci
|
||||
|
||||
- name: Gen Keys if required
|
||||
if: needs.should-run.outputs.shortint_test == 'true' ||
|
||||
|
||||
6
.github/workflows/aws_tfhe_wasm_tests.yml
vendored
6
.github/workflows/aws_tfhe_wasm_tests.yml
vendored
@@ -50,10 +50,6 @@ jobs:
|
||||
persist-credentials: 'false'
|
||||
token: ${{ secrets.FHE_ACTIONS_TOKEN }}
|
||||
|
||||
- name: Set up home
|
||||
run: |
|
||||
echo "HOME=/home/ubuntu" >> "${GITHUB_ENV}"
|
||||
|
||||
- name: Install latest stable
|
||||
uses: dtolnay/rust-toolchain@7b1c307e0dcbda6122208f10795a713336a9b35a
|
||||
with:
|
||||
@@ -71,7 +67,7 @@ jobs:
|
||||
|
||||
- name: Run js on wasm API tests
|
||||
run: |
|
||||
make test_nodejs_wasm_api_in_docker
|
||||
make test_nodejs_wasm_api_ci
|
||||
|
||||
- name: Run parallel wasm tests
|
||||
run: |
|
||||
|
||||
5
.github/workflows/benchmark_wasm_client.yml
vendored
5
.github/workflows/benchmark_wasm_client.yml
vendored
@@ -97,11 +97,6 @@ jobs:
|
||||
echo "COMMIT_HASH=$(git describe --tags --dirty)";
|
||||
} >> "${GITHUB_ENV}"
|
||||
|
||||
- name: Set up home
|
||||
# "Install rust" step require root user to have a HOME directory which is not set.
|
||||
run: |
|
||||
echo "HOME=/home/ubuntu" >> "${GITHUB_ENV}"
|
||||
|
||||
- name: Install rust
|
||||
uses: dtolnay/rust-toolchain@7b1c307e0dcbda6122208f10795a713336a9b35a
|
||||
with:
|
||||
|
||||
22
Makefile
22
Makefile
@@ -919,26 +919,16 @@ check_compile_tests_benches_gpu: install_rs_build_toolchain
|
||||
cmake .. -DCMAKE_BUILD_TYPE=Debug -DTFHE_CUDA_BACKEND_BUILD_TESTS=ON -DTFHE_CUDA_BACKEND_BUILD_BENCHMARKS=ON && \
|
||||
"$(MAKE)" -j "$(CPU_COUNT)"
|
||||
|
||||
.PHONY: build_nodejs_test_docker # Build a docker image with tools to run nodejs tests for wasm API
|
||||
build_nodejs_test_docker:
|
||||
DOCKER_BUILDKIT=1 docker build --build-arg RUST_TOOLCHAIN="$(RS_BUILD_TOOLCHAIN)" \
|
||||
-f docker/Dockerfile.wasm_tests --build-arg NODE_VERSION=$(NODE_VERSION) -t tfhe-wasm-tests .
|
||||
|
||||
.PHONY: test_nodejs_wasm_api_in_docker # Run tests for the nodejs on wasm API in a docker container
|
||||
test_nodejs_wasm_api_in_docker: build_nodejs_test_docker
|
||||
if [[ -t 1 ]]; then RUN_FLAGS="-it"; else RUN_FLAGS="-i"; fi && \
|
||||
docker run --rm "$${RUN_FLAGS}" \
|
||||
-v "$$(pwd)":/tfhe-wasm-tests/tfhe-rs \
|
||||
-v tfhe-rs-root-target-cache:/root/tfhe-rs-target \
|
||||
-v tfhe-rs-pkg-cache:/tfhe-wasm-tests/tfhe-rs/tfhe/pkg \
|
||||
-v tfhe-rs-root-cargo-registry-cache:/root/.cargo/registry \
|
||||
-v tfhe-rs-root-cache:/root/.cache \
|
||||
tfhe-wasm-tests /bin/bash -i -c 'make test_nodejs_wasm_api'
|
||||
|
||||
.PHONY: test_nodejs_wasm_api # Run tests for the nodejs on wasm API
|
||||
test_nodejs_wasm_api: build_node_js_api
|
||||
cd tfhe/js_on_wasm_tests && npm install && npm run test
|
||||
|
||||
.PHONY: test_nodejs_wasm_api_ci # Run tests for the nodejs on wasm API
|
||||
test_nodejs_wasm_api_ci: build_node_js_api
|
||||
source ~/.nvm/nvm.sh && \
|
||||
nvm install $(NODE_VERSION) && \
|
||||
nvm use $(NODE_VERSION) && \
|
||||
$(MAKE) test_nodejs_wasm_api
|
||||
|
||||
# This is an internal target, not meant to be called on its own.
|
||||
run_web_js_api_parallel: build_web_js_api_parallel setup_venv
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[backend.aws.cpu-big]
|
||||
region = "eu-west-3"
|
||||
image_id = "ami-09b5f2f71828035d4"
|
||||
image_id = "ami-0cd5012d17ae64070"
|
||||
instance_type = "m6i.32xlarge"
|
||||
|
||||
[backend.aws.cpu-big_fallback]
|
||||
@@ -10,8 +10,9 @@ instance_type = "m6i.32xlarge"
|
||||
|
||||
[backend.aws.cpu-small]
|
||||
region = "eu-west-3"
|
||||
image_id = "ami-09b5f2f71828035d4"
|
||||
image_id = "ami-0cd5012d17ae64070"
|
||||
instance_type = "m6i.4xlarge"
|
||||
user = "ubuntu"
|
||||
|
||||
[backend.aws.bench]
|
||||
region = "eu-west-1"
|
||||
|
||||
Reference in New Issue
Block a user