From 860a7683acd119802117e6e3ca3cd7df16fec35d Mon Sep 17 00:00:00 2001 From: Paddy Foran Date: Thu, 19 Feb 2015 19:34:40 -0500 Subject: [PATCH] Enable shell expansion. We're changing from scratch to busybox as a base image, after discussion in #543. This gives us some free shell expansion. I also added a step at the end of dist.sh that would take care of tagging the image as the "latest" build, as long as there's not a hyphen in the version number (so our "latest" build will never be an alpha or beta, as I assume we want stability by default). --- Dockerfile | 4 +++- dist.sh | 5 +++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 0b4286190..138c60d96 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,8 @@ -FROM scratch +FROM busybox ADD dist/docker/bin/ / +EXPOSE 4150 4151 4160 4161 4170 4171 + VOLUME /data VOLUME /etc/ssl/certs diff --git a/dist.sh b/dist.sh index c120b53bd..480dbd099 100755 --- a/dist.sh +++ b/dist.sh @@ -49,3 +49,8 @@ for os in linux darwin; do done docker build -t nsqio/nsq:v$version . +if [[ ! $version == *"-"* ]] +then + echo "Tagging nsqio/nsq:v${version} as the latest release."; + docker tag -f nsqio/nsq:v$version nsqio/nsq:latest +fi