Skip to content

Commit

Permalink
Change ordering for better layer caching
Browse files Browse the repository at this point in the history
  • Loading branch information
klementng committed Jul 21, 2023
1 parent ecbc33b commit 8ff27e9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
FROM alpine:latest as build

WORKDIR /sslh
COPY . /sslh

RUN apk add gcc libconfig-dev make musl-dev pcre2-dev perl

COPY . /sslh
RUN make sslh-select && strip sslh-select

FROM alpine:latest

COPY --from=build "/sslh/sslh-select" "/usr/local/bin/sslh"

RUN apk --no-cache add libconfig pcre2 iptables ip6tables libcap

RUN adduser sslh --shell /bin/sh --disabled-password

COPY --from=build "/sslh/sslh-select" "/usr/local/bin/sslh"
RUN setcap cap_net_bind_service,cap_net_raw+ep /usr/local/bin/sslh

COPY "./container-entrypoint.sh" "/init"
Expand Down

0 comments on commit 8ff27e9

Please sign in to comment.