-
Notifications
You must be signed in to change notification settings - Fork 138
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Moving the binary compilation as part of Docker we will be able to leverage the multi architecture support Docker has to provide images that can run on different architecture such as x64_86, ARM. Signed-off-by: Gianluca Arbezzano <[email protected]>
- Loading branch information
Gianluca Arbezzano
committed
Oct 27, 2020
1 parent
9e7d539
commit f959df8
Showing
5 changed files
with
25 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
deploy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
FROM alpine:3.11 | ||
|
||
CMD sleep infinity | ||
FROM golang:1.15-alpine | ||
RUN apk add --no-cache --update --upgrade ca-certificates make git | ||
COPY . /usr/myapp | ||
WORKDIR /usr/myapp | ||
RUN make cli | ||
|
||
FROM alpine:3.11 | ||
ENTRYPOINT ["/usr/bin/tink-cli"] | ||
RUN apk add --no-cache --update --upgrade ca-certificates | ||
|
||
COPY tink-cli /bin/tink | ||
COPY sample.tmpl /tmp | ||
COPY --from=0 /usr/myapp/cmd/tink-cli/tink-cli /usr/bin/tink-cli |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,14 @@ | ||
FROM alpine:3.11 | ||
FROM golang:1.15-alpine | ||
RUN apk add --no-cache --update --upgrade ca-certificates make git | ||
COPY . /usr/myapp | ||
WORKDIR /usr/myapp | ||
RUN make server | ||
|
||
ENTRYPOINT ["tink-server"] | ||
FROM alpine:3.11 | ||
ENTRYPOINT ["/usr/bin/tink-server"] | ||
EXPOSE 42113 | ||
EXPOSE 42114 | ||
|
||
RUN apk add --update ca-certificates && \ | ||
apk add --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing cfssl | ||
|
||
COPY tink-server /bin/ | ||
COPY --from=0 /usr/myapp/cmd/tink-server/tink-server /usr/bin/tink-server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
FROM alpine:3.11 | ||
|
||
ENTRYPOINT [ "/tink-worker" ] | ||
FROM golang:1.15-alpine | ||
RUN apk add --no-cache --update --upgrade ca-certificates make git | ||
COPY . /usr/myapp | ||
WORKDIR /usr/myapp | ||
RUN make worker | ||
|
||
FROM alpine:3.11 | ||
ENTRYPOINT [ "/usr/bin/tink-worker" ] | ||
RUN apk add --no-cache --update --upgrade ca-certificates | ||
|
||
COPY tink-worker /tink-worker | ||
COPY --from=0 /usr/myapp/cmd/tink-worker/tink-worker /usr/bin/tink-worker |