Skip to content

Commit

Permalink
chore: place wws under /opt/wws and keep /app in prebuilt images too
Browse files Browse the repository at this point in the history
  • Loading branch information
ereslibre committed Jul 31, 2023
1 parent be9e355 commit 99c60e9
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions image/Prebuilt.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
# GitHub actions

# Retrieve the certificates to install runtimes later on.
FROM --platform=$TARGETPLATFORM bitnami/minideb:latest AS certs
FROM --platform=$TARGETPLATFORM bitnami/minideb:latest AS sysroot
RUN mkdir -p /target/app /target/opt
RUN install_packages ca-certificates

# Build the final image
Expand All @@ -14,9 +15,10 @@ LABEL org.opencontainers.image.source=https://github.com/vmware-labs/wasm-worker
LABEL org.opencontainers.image.description="Wasm Workers Server is a blazing-fast self-contained server that routes HTTP requests to workers in your filesystem. Everything run in a WebAssembly sandbox."
LABEL org.opencontainers.image.licenses="Apache-2.0"

COPY --from=certs /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
COPY --chmod=755 ./wws-$TARGETARCH /wws
COPY --from=sysroot /target/app /app
COPY --from=sysroot /target/opt /opt
COPY --from=sysroot /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
COPY --chmod=755 ./wws-$TARGETARCH /opt/wws

ENTRYPOINT ["/wws"]
ENTRYPOINT ["/opt/wws"]
CMD ["/app/", "--host", "0.0.0.0"]

0 comments on commit 99c60e9

Please sign in to comment.