mirror of
https://github.com/oauth2-proxy/oauth2-proxy.git
synced 2024-11-28 09:08:44 +02:00
fix Docker user on arm
Use simple USER directive. Using `addgroup` in final `arm` image when building on amd64 doesn't work. I must have made a mistake during cross build verification. Alternative is to use qemu-static but it's not worth it for this.
This commit is contained in:
parent
93b7d31332
commit
308bcc06a4
@ -2,6 +2,7 @@
|
||||
|
||||
## Changes since v3.2.0
|
||||
|
||||
- [#142](https://github.com/pusher/oauth2_proxy/pull/142) ARM Docker USER fix (@kskewes)
|
||||
- [#52](https://github.com/pusher/oauth2_proxy/pull/52) Logging Improvements (@MisterWil)
|
||||
- Implement flags to configure file logging
|
||||
- `-logging-filename` Defines the filename to log to
|
||||
|
@ -25,7 +25,6 @@ COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certifi
|
||||
COPY --from=builder /go/src/github.com/pusher/oauth2_proxy/oauth2_proxy /bin/oauth2_proxy
|
||||
COPY --from=builder /go/src/github.com/pusher/oauth2_proxy/jwt_signing_key.pem /etc/ssl/private/jwt_signing_key.pem
|
||||
|
||||
RUN addgroup -S -g 2000 oauth2proxy && adduser -S -u 2000 oauth2proxy -G oauth2proxy
|
||||
USER oauth2proxy
|
||||
USER 2000:2000
|
||||
|
||||
ENTRYPOINT ["/bin/oauth2_proxy"]
|
||||
|
@ -1,4 +1,4 @@
|
||||
FROM golang:1.11-stretch AS builder
|
||||
FROM golang:1.12-stretch AS builder
|
||||
|
||||
# Download tools
|
||||
RUN wget -O $GOPATH/bin/dep https://github.com/golang/dep/releases/download/v0.5.0/dep-linux-amd64
|
||||
@ -25,7 +25,6 @@ COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certifi
|
||||
COPY --from=builder /go/src/github.com/pusher/oauth2_proxy/oauth2_proxy /bin/oauth2_proxy
|
||||
COPY --from=builder /go/src/github.com/pusher/oauth2_proxy/jwt_signing_key.pem /etc/ssl/private/jwt_signing_key.pem
|
||||
|
||||
RUN addgroup -S -g 2000 oauth2proxy && adduser -S -u 2000 oauth2proxy -G oauth2proxy
|
||||
USER oauth2proxy
|
||||
USER 2000:2000
|
||||
|
||||
ENTRYPOINT ["/bin/oauth2_proxy"]
|
||||
|
@ -1,4 +1,4 @@
|
||||
FROM golang:1.11-stretch AS builder
|
||||
FROM golang:1.12-stretch AS builder
|
||||
|
||||
# Download tools
|
||||
RUN wget -O $GOPATH/bin/dep https://github.com/golang/dep/releases/download/v0.5.0/dep-linux-amd64
|
||||
@ -25,7 +25,6 @@ COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certifi
|
||||
COPY --from=builder /go/src/github.com/pusher/oauth2_proxy/oauth2_proxy /bin/oauth2_proxy
|
||||
COPY --from=builder /go/src/github.com/pusher/oauth2_proxy/jwt_signing_key.pem /etc/ssl/private/jwt_signing_key.pem
|
||||
|
||||
RUN addgroup -S -g 2000 oauth2proxy && adduser -S -u 2000 oauth2proxy -G oauth2proxy
|
||||
USER oauth2proxy
|
||||
USER 2000:2000
|
||||
|
||||
ENTRYPOINT ["/bin/oauth2_proxy"]
|
||||
|
Loading…
Reference in New Issue
Block a user