-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Add missing PATH. - Bring into sync with other arches.
- Loading branch information
Showing
1 changed file
with
10 additions
and
5 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 |
---|---|---|
@@ -1,17 +1,22 @@ | ||
FROM amd64/alpine:3.7 | ||
FROM alpine:3.6 as base | ||
MAINTAINER Shaun Crampton <[email protected]> | ||
|
||
# Since our binary isn't designed to run as PID 1, run it via the tini init daemon. | ||
RUN apk add --update tini | ||
ENTRYPOINT ["/sbin/tini", "--"] | ||
|
||
ADD typha.cfg /etc/calico/typha.cfg | ||
FROM scratch | ||
COPY --from=base /sbin/tini /sbin/tini | ||
COPY --from=base /lib/ld-musl-x86_64.so.1 /lib/ld-musl-x86_64.so.1 | ||
COPY --from=base /lib/libc.musl-x86_64.so.1 /lib/libc.musl-x86_64.so.1 | ||
|
||
# Put out binary in /code rather than directly in /usr/bin. This allows the downstream builds | ||
# Put our binary in /code rather than directly in /usr/bin. This allows the downstream builds | ||
# to more easily extract the build artefacts from the container. | ||
RUN mkdir /code | ||
ADD bin/calico-typha-amd64 /code/calico-typha | ||
ADD typha.cfg /etc/calico/typha.cfg | ||
|
||
WORKDIR /code | ||
ENV PATH="$PATH:/code" | ||
|
||
# Run Typha by default | ||
ENTRYPOINT ["/sbin/tini", "--"] | ||
CMD ["calico-typha"] |