diff --git a/spin.yaml b/spin.yaml new file mode 100644 index 00000000000..0c9f76e6acd --- /dev/null +++ b/spin.yaml @@ -0,0 +1,52 @@ +package: + name: spin + version: 1.4.1 + epoch: 0 + description: "Spin is the open source developer tool for building and running serverless applications powered by WebAssembly." + copyright: + - license: Apache-2.0 + dependencies: + runtime: + - git + +environment: + contents: + packages: + - wolfi-base + - busybox + - ca-certificates-bundle + - build-base + - rustup + - cmake + - openssl-dev + - bash + +pipeline: + - uses: git-checkout + with: + repository: https://github.com/fermyon/spin + tag: v${{package.version}} + expected-commit: e0bd9115fa51399e106681ac1c9ed1afbad1baaa + + - name: Configure and build + runs: | + # This build requires the stable version of rust, managed by rustup, because it requires a few other toolchains too. + rustup install stable + rustup target add wasm32-wasi + rustup target add wasm32-unknown-unknown + + # This is a bit of a hack, but it's the easiest way to get the right version of rustc and cargo in the path. + export PATH="$HOME/.rustup/toolchains/stable-${{host.triplet.rust}}/bin:$PATH" + + cargo build --release + + mkdir -p ${{targets.destdir}}/usr/bin/ + mv target/release/spin ${{targets.destdir}}/usr/bin/ + + - uses: strip + +update: + enabled: true + github: + identifier: fermyon/spin + strip-prefix: v