diff --git a/Dockerfile b/Dockerfile index cb0871e..aac92cd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,7 @@ FROM microsoft/dotnet:2-sdk ENV MONO_VERSION 5.0.1.1 +ENV DOCKER_HOST=tcp://docker:2375 RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF RUN echo "deb http://download.mono-project.com/repo/debian jessie/snapshots/$MONO_VERSION main" > /etc/apt/sources.list.d/mono-official.list @@ -18,9 +19,12 @@ COPY build.sh . COPY preload.cake . COPY setup.sh . COPY ./gitver /usr/bin +COPY ./get_versions /usr/bin RUN chmod +x build.sh RUN chmod +x setup.sh +RUN chmod +x /usr/bin/get_versions + RUN ./build.sh -s preload.cake RUN ./setup.sh @@ -28,5 +32,4 @@ WORKDIR /usr/bin RUN ln -s /build/nuget RUN ln -s /build/build.sh cake -RUN echo "alias SYNC_VERSION=\"gitver | jq '.FullSemVer' -r\"" >> ~/.bashrc -RUN echo "alias SYNC_VERSION=\"gitver | jq '.FullSemVer' -r\"" >> /etc/profile +RUN curl -fsSL get.docker.com -o get-docker.sh && sh get-docker.sh diff --git a/get_versions b/get_versions new file mode 100644 index 0000000..68d3a27 --- /dev/null +++ b/get_versions @@ -0,0 +1,12 @@ +#!/bin/sh + +export SYNC_VERSION=$(gitver | jq '.FullSemVer' -r) +export SYNC_DOCKER_VERSION=$(echo $SYNC_VERSION | sed 's/\+/./') + +echo "---------------------------------------------------------------" +echo "Sync Version is $SYNC_VERSION" +echo "Sync Docker Version is $SYNC_DOCKER_VERSION" +echo "---------------------------------------------------------------" +echo "" +echo "" +echo ""