Update dockerfile
Former-commit-id: 4f2bf12654ebbeb02fe727b168495cfd67b3abed Former-commit-id: 543d4994689c49e31c4344855134015ef81ebca9 [formerly cf22279f239f395e351cb9d4ffd3648e60a9880f] [formerly ff9021d9c296d72560450d9b3d72dc64e9695142 [formerly a96ad5215555a4fafe34a8cca56f86255731cf9d [formerly 5ec7f9aa22c15759fbc5aec2ba03733238a0b7d2] [formerly 5ec7f9aa22c15759fbc5aec2ba03733238a0b7d2 [formerly 5ec7f9aa22c15759fbc5aec2ba03733238a0b7d2 [formerly 4fcf744fd843ac36edd40b7b47495927773d0e6f]]]]] Former-commit-id: d6ee5bce6acd8c21dfe77ac654e12631bf9c4362 [formerly 3a08614ba9ed5fa761a6d1cdf6b3557ab4d172aa] Former-commit-id: da44f000e384c6fc71ad5c171c94b55582ca09e8 Former-commit-id: 2712e2ad0fb363e2d1544f2227e895d60125f018 Former-commit-id: 588843c91ebcdda0e5460969e61dda3c46265453 Former-commit-id: ec15288723177e1592579c9b16fddd4a5f9a8821 [formerly f641f618f4ef9c4185a6abe7405da6d2a8145326] Former-commit-id: 0f0f92ca988c92d0afe7d0b0663f06a162b4f759
This commit is contained in:
parent
aebdc71a7f
commit
0b20dda5f9
1 changed files with 10 additions and 2 deletions
12
Dockerfile
12
Dockerfile
|
@ -1,5 +1,5 @@
|
|||
FROM alpine:3.12 as builder
|
||||
MAINTAINER github@erebe.eu
|
||||
# Build Cache image
|
||||
FROM alpine:3.12 as builder-cache
|
||||
|
||||
RUN apk --no-cache add ca-certificates git ghc curl musl-dev gmp-dev zlib-dev zlib-static pcre-dev xz make upx
|
||||
RUN curl -sSL https://github.com/commercialhaskell/stack/releases/download/v2.1.3/stack-2.1.3-linux-x86_64-static.tar.gz | tar xvz && \
|
||||
|
@ -14,6 +14,11 @@ RUN rm -rf ~/.stack && \
|
|||
stack setup && \
|
||||
stack install --split-objs --ghc-options="-fPIC" --only-dependencies
|
||||
|
||||
|
||||
|
||||
# Build phase
|
||||
#FROM builder-cache as builder
|
||||
FROM ghcr.io/erebe/wstunnel:build-cache as builder
|
||||
COPY . /mnt
|
||||
|
||||
RUN echo ' ld-options: -static' >> wstunnel.cabal ; \
|
||||
|
@ -22,9 +27,12 @@ RUN echo ' ld-options: -static' >> wstunnel.cabal ; \
|
|||
|
||||
|
||||
|
||||
# Final Image
|
||||
FROM alpine:latest as runner
|
||||
MAINTAINER github@erebe.eu
|
||||
|
||||
LABEL org.opencontainers.image.source https://github.com/erebe/server
|
||||
|
||||
COPY --from=builder /root/.local/bin/wstunnel /
|
||||
RUN adduser -D abc && chmod +x /wstunnel
|
||||
|
||||
|
|
Loading…
Reference in a new issue