From 2b6a624c88c0347a21b18b7f38988fa488546355 Mon Sep 17 00:00:00 2001 From: Timo Stark Date: Thu, 2 Nov 2023 21:47:57 +0100 Subject: [PATCH] Wasm-wc: Dockerfile changed to pull sources from the right repository Signed-off-by: Timo Stark [ Updated for module name 'wasm-wasi-component' - Andrew ] Signed-off-by: Andrew Clayton --- ...rfile.wasmtime => Dockerfile.wasm-wasi-component} | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) rename pkg/docker/{Dockerfile.wasmtime => Dockerfile.wasm-wasi-component} (90%) diff --git a/pkg/docker/Dockerfile.wasmtime b/pkg/docker/Dockerfile.wasm-wasi-component similarity index 90% rename from pkg/docker/Dockerfile.wasmtime rename to pkg/docker/Dockerfile.wasm-wasi-component index bb34ce990..70e0a781c 100644 --- a/pkg/docker/Dockerfile.wasmtime +++ b/pkg/docker/Dockerfile.wasm-wasi-component @@ -1,7 +1,7 @@ FROM debian:bullseye-slim -LABEL org.opencontainers.image.title="Unit (wasm)" -LABEL org.opencontainers.image.description="Official build of Unit for Docker." +LABEL org.opencontainers.image.title="Unit Preview (wasm-wasi-component)" +LABEL org.opencontainers.image.description="Official preview build of Unit for Docker." LABEL org.opencontainers.image.url="https://unit.nginx.org" LABEL org.opencontainers.image.source="https://github.com/nginx/unit" LABEL org.opencontainers.image.documentation="https://unit.nginx.org/installation/#docker-images" @@ -15,7 +15,7 @@ RUN set -ex \ && mkdir -p /usr/lib/unit/modules /usr/lib/unit/debug-modules \ && mkdir -p /usr/src/unit \ && cd /usr/src/unit \ - && git clone https://github.com/alexcrichton/unit --branch wasmtime \ + && git clone https://github.com/ac000/unit --branch wasm-cm \ && cd unit \ && NCPU="$(getconf _NPROCESSORS_ONLN)" \ && DEB_HOST_MULTIARCH="$(dpkg-architecture -q DEB_HOST_MULTIARCH)" \ @@ -66,9 +66,9 @@ RUN set -ex \ && rustc --version \ && ./configure $CONFIGURE_ARGS_MODULES --cc-opt="$CC_OPT" --modulesdir=/usr/lib/unit/modules \ && make build/src/nxt_unit.o \ - && cargo build --release --manifest-path wasmtime/Cargo.toml \ - && install -pm755 wasmtime/target/release/libnxt_wasmtime.so /usr/lib/unit/modules/wasmtime.unit.so \ - && rm -rf wasmtime/target \ + && cargo build --release --manifest-path src/wasm-wasi-component/Cargo.toml \ + && install -pm755 src/wasm-wasi-component/target/release/libnxt_wasmtime.so /usr/lib/unit/modules/wasm_wasi_component.unit.so \ + && rm -rf src/wasm-wasi-component/target \ && rm -rf /usr/src/unit \ && for f in /usr/sbin/unitd /usr/lib/unit/modules/*.unit.so; do \ ldd $f | awk '/=>/{print $(NF-1)}' | while read n; do dpkg-query -S $n; done | sed 's/^\([^:]\+\):.*$/\1/' | sort | uniq >> /requirements.apt; \