Alex R
5 years ago
committed by
Alex
3 changed files with 23 additions and 12 deletions
@ -1,16 +1,19 @@ |
|||||||
FROM golang:1.13-alpine3.10 AS build-env |
FROM golang:1.13-alpine3.10 AS build-env |
||||||
|
|
||||||
|
#Build deps |
||||||
|
RUN apk --no-cache add build-base git |
||||||
|
|
||||||
#Setup |
#Setup |
||||||
COPY . /src/gitea-group-sync |
COPY . /src/gitea-group-sync |
||||||
WORKDIR /src/gitea-group-sync |
WORKDIR /src/gitea-group-sync |
||||||
|
|
||||||
#Build deps |
|
||||||
RUN apk --no-cache add build-base git |
|
||||||
|
|
||||||
RUN go get gopkg.in/ldap.v3 && go get gopkg.in/robfig/cron.v3 && go build |
RUN go get gopkg.in/ldap.v3 && go get gopkg.in/robfig/cron.v3 && go build |
||||||
|
|
||||||
|
# Final |
||||||
FROM alpine:3.10 |
FROM alpine:3.10 |
||||||
|
|
||||||
COPY --from=build-env /src/gitea-group-sync/gitea-group-sync /app/gitea-group-sync/gitea-group-sync |
COPY --from=build-env /src/gitea-group-sync/gitea-group-sync /app/gitea-group-sync/gitea-group-sync |
||||||
|
|
||||||
RUN ln -s /app/gitea-group-sync/gitea-group-sync /usr/local/bin/gitea-group-sync |
RUN ln -s /app/gitea-group-sync/gitea-group-sync /usr/local/bin/gitea-group-sync |
||||||
|
|
||||||
ENTRYPOINT ["/usr/local/bin/gitea-group-sync"] |
ENTRYPOINT ["/usr/local/bin/gitea-group-sync"] |
||||||
|
Loading…
Reference in new issue