Skip to content

Instantly share code, notes, and snippets.

View simonwo's full-sized avatar

Simon Worthington simonwo

View GitHub Profile
@simonwo
simonwo / rust-wasm32-wasi-compile.sh
Last active November 3, 2022 09:29
Compile Rust to WASM with WASI
#!/bin/sh
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs -o rustup.sh
sh rustup.sh -y
export PATH=~/.cargo/bin:$PATH
rustup target install wasm32-wasi
apt-get install -y build-essential libc6-dev clang-8 gcc-multilib
cd /code
CC_wasm32_wasi=clang-8 cargo build --target wasm32-wasi --release
@simonwo
simonwo / spec.yml
Created January 24, 2023 23:38
Bacalhau job spec with Inline storage
Spec:
Engine: Docker
Verifier: Noop
Publisher: Estuary
Docker:
Image: "jsacex/easyocr"
Entrypoint: ["easyocr", "-l", "ch_sim", "en", "-f", "./inputs/chinese.jpg", "--detail=1", "--gpu=True"]
Inputs:
- StorageSource: IPFS
Path: "/root/.EasyOCR/model/zh_sim_g2.pth"