Skip to content

Commit 18282b4

Browse files
0yi0hydai
authored andcommitted
ci: deprecate runner ubuntu-20.04
* pytorch.yml Signed-off-by: Yi Huang <[email protected]>
1 parent ee8276c commit 18282b4

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

.github/workflows/pytorch.yml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,26 +23,30 @@ on:
2323
jobs:
2424
build:
2525

26-
runs-on: ubuntu-20.04
26+
runs-on: ubuntu-latest
27+
container:
28+
image: ubuntu:20.04
2729

2830
steps:
2931
- uses: actions/checkout@v3
3032

3133
- name: Install apt-get packages
3234
run: |
33-
echo RESET grub-efi/install_devices | sudo debconf-communicate grub-pc
34-
sudo ACCEPT_EULA=Y apt-get update
35-
sudo ACCEPT_EULA=Y apt-get upgrade
36-
sudo apt-get install wget git curl software-properties-common build-essential
35+
ACCEPT_EULA=Y apt-get update
36+
ACCEPT_EULA=Y apt-get upgrade -y
37+
apt-get install -y wget git curl software-properties-common build-essential unzip
38+
env:
39+
DEBIAN_FRONTEND: noninteractive
3740

3841
- name: Install Rust target for wasm
39-
run: |
40-
rustup target add wasm32-wasip1
42+
uses: dtolnay/rust-toolchain@stable
43+
with:
44+
target: wasm32-wasip1
4145

4246
- name: Install WasmEdge + WASI-NN + PyTorch
4347
run: |
4448
VERSION=0.13.4
45-
curl -sSf https://raw.githubusercontent.com/WasmEdge/WasmEdge/master/utils/install.sh | sudo bash -s -- -v $VERSION --plugins wasi_nn-pytorch -p /usr/local
49+
curl -sSf https://raw.githubusercontent.com/WasmEdge/WasmEdge/master/utils/install.sh | bash -s -- -v $VERSION --plugins wasi_nn-pytorch -p /usr/local
4650
export PYTORCH_VERSION="1.8.2"
4751
# For the Ubuntu 20.04 or above, use the libtorch with cxx11 abi.
4852
export PYTORCH_ABI="libtorch-cxx11-abi"

0 commit comments

Comments
 (0)