update consul images

Signed-off-by: Jessica Frazelle <acidburn@docker.com>
This commit is contained in:
Jessica Frazelle 2015-07-27 23:46:07 -07:00
parent 0010cf51c2
commit 4ea09b90f1
2 changed files with 35 additions and 25 deletions

View File

@ -1,20 +1,26 @@
FROM debian:jessie
FROM alpine:latest
MAINTAINER Jessica Frazelle <jess@docker.com>
RUN apk update && apk add \
ca-certificates \
curl \
unzip \
&& curl -sSL https://circle-artifacts.com/gh/andyshinn/alpine-pkg-glibc/6/artifacts/0/home/ubuntu/alpine-pkg-glibc/packages/x86_64/glibc-2.21-r2.apk -o /tmp/glibc-2.21-r2.apk \
&& apk add --allow-untrusted /tmp/glibc-2.21-r2.apk \
&& curl -sSL https://circle-artifacts.com/gh/andyshinn/alpine-pkg-glibc/6/artifacts/0/home/ubuntu/alpine-pkg-glibc/packages/x86_64/glibc-bin-2.21-r2.apk -o /tmp/glibc-bin-2.21-r2.apk \
&& apk add --allow-untrusted /tmp/glibc-bin-2.21-r2.apk \
&& rm -rf /tmp/glibc* \
&& rm -rf /var/cache/apk/*
ENV CONSUL_VERSION 0.5.2
ADD https://jesss.s3.amazonaws.com/binaries/consul-alerts /usr/local/bin/consul-alerts
ADD https://jesss.s3.amazonaws.com/binaries/consul/${CONSUL_VERSION}/consul /usr/local/bin/consul
ADD https://jesss.s3.amazonaws.com/binaries/curl-unix-socket /usr/local/bin/curl-unix-socket
RUN apt-get update && apt-get install -y \
ca-certificates \
curl \
--no-install-recommends \
&& rm -rf /var/lib/apt/lists/* \
RUN curl -sSL https://jesss.s3.amazonaws.com/binaries/consul/${CONSUL_VERSION}/consul -o /bin/consul \
&& curl -sSL https://jesss.s3.amazonaws.com/binaries/curl-unix-socket -o /bin/curl-unix-socket \
&& curl -sSL https://jesss.s3.amazonaws.com/binaries/consul-alerts -o /bin/consul-alerts \
&& mkdir -p /etc/consul.d/ \
&& chmod +x /usr/local/bin/consul \
&& chmod +x /usr/local/bin/curl-unix-socket \
&& chmod +x /usr/local/bin/consul-alerts
&& chmod +x /bin/consul \
&& chmod +x /bin/curl-unix-socket \
&& chmod +x /bin/consul-alerts
ENTRYPOINT [ "/usr/local/bin/consul-alerts", "start" ]
ENTRYPOINT [ "/bin/consul-alerts" ]
CMD [ "start" ]

View File

@ -1,24 +1,28 @@
FROM debian:jessie
FROM alpine:latest
MAINTAINER Jessica Frazelle <jess@docker.com>
RUN apt-get update && apt-get install -y \
RUN apk update && apk add \
ca-certificates \
curl \
unzip \
--no-install-recommends \
&& rm -rf /var/lib/apt/lists/*
&& curl -sSL https://circle-artifacts.com/gh/andyshinn/alpine-pkg-glibc/6/artifacts/0/home/ubuntu/alpine-pkg-glibc/packages/x86_64/glibc-2.21-r2.apk -o /tmp/glibc-2.21-r2.apk \
&& apk add --allow-untrusted /tmp/glibc-2.21-r2.apk \
&& curl -sSL https://circle-artifacts.com/gh/andyshinn/alpine-pkg-glibc/6/artifacts/0/home/ubuntu/alpine-pkg-glibc/packages/x86_64/glibc-bin-2.21-r2.apk -o /tmp/glibc-bin-2.21-r2.apk \
&& apk add --allow-untrusted /tmp/glibc-bin-2.21-r2.apk \
&& rm -rf /tmp/glibc* \
&& rm -rf /var/cache/apk/*
ENV CONSUL_VERSION 0.5.2
ADD https://jesss.s3.amazonaws.com/binaries/consul/${CONSUL_VERSION}/consul /usr/local/bin/consul
ADD https://jesss.s3.amazonaws.com/binaries/curl-unix-socket /usr/local/bin/curl-unix-socket
# download the ui
RUN curl -sSL https://jesss.s3.amazonaws.com/binaries/consul/${CONSUL_VERSION}/ui.zip -o /tmp/ui.zip \
RUN curl -sSL https://jesss.s3.amazonaws.com/binaries/consul/${CONSUL_VERSION}/consul -o /bin/consul \
&& curl -sSL https://jesss.s3.amazonaws.com/binaries/curl-unix-socket -o /bin/curl-unix-socket \
&& curl -sSL https://jesss.s3.amazonaws.com/binaries/consul/${CONSUL_VERSION}/ui.zip -o /tmp/ui.zip \
&& unzip /tmp/ui.zip -d /usr/src/ \
&& rm -rf /tmp/ui.zip \
&& mv /usr/src/dist /usr/src/consul \
&& mkdir -p /etc/consul.d/ \
&& chmod +x /usr/local/bin/consul \
&& chmod +x /usr/local/bin/curl-unix-socket
&& chmod +x /bin/consul \
&& chmod +x /bin/curl-unix-socket \
&& /usr/glibc/usr/bin/ldconfig /lib /usr/glibc/usr/lib
ENTRYPOINT [ "/usr/local/bin/consul" ]
ENTRYPOINT [ "/bin/consul" ]