diff --git a/examples/Dockerfile b/examples/Dockerfile index 8288eb0..b07dd27 100644 --- a/examples/Dockerfile +++ b/examples/Dockerfile @@ -1,10 +1,18 @@ -FROM alpine:3.17.0 +FROM alpine:3.17.0 as builder + +RUN apk add --no-cache upx +ADD ./bin/Purr-musl /app/Purr-musl + +RUN upx /app/Purr-musl -o /app/Purr-musl-upx + +FROM scratch WORKDIR /app ADD ./views /app/views ADD ./src /app/src -ADD ./bin/Purr-musl /app/Purr-musl + +COPY --from=builder /app/Purr-musl-upx /app/Purr EXPOSE 3000 -ENTRYPOINT ["/app/Purr-musl"] +ENTRYPOINT ["/app/Purr"]