Skip to content
This repository has been archived by the owner on Mar 19, 2019. It is now read-only.

Commit

Permalink
Allow to specify repo and branch
Browse files Browse the repository at this point in the history
  • Loading branch information
mnordsletten committed Sep 17, 2018
1 parent 0f1c26d commit 62b9d95
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,13 @@ RUN USER=docker && \
RUN echo "LANG=C.UTF-8" > /etc/default/locale

# TAG can be specified when building with --build-arg TAG=..., this is redeclared in the source-build stage
ARG TAG=v0.12.0-rc.3
ENV TAG=$TAG
ARG BRANCH=dev
ARG REPO=hioa-cs
ENV BRANCH=$BRANCH
ENV REPO=$REPO

LABEL dockerfile.version=1 \
includeos.version=$TAG
includeos.version=$BRANCH
WORKDIR /service

#########################
Expand All @@ -45,14 +48,14 @@ RUN apt-get update && apt-get -y install \
&& rm -rf /var/lib/apt/lists/*

# Triggers new build if there are changes to head
ADD https://api.github.com/repos/hioa-cs/IncludeOS/git/refs/heads/dev version.json
#ADD https://api.github.com/repos/$REPO/IncludeOS/git/refs/heads/$BRANCH version.json

RUN echo "cloning $TAG"
RUN echo "cloning $BRANCH"

RUN cd ~ && pwd && \
git clone https://github.com/hioa-cs/IncludeOS.git && \
git clone https://github.com/$REPO/IncludeOS.git && \
cd IncludeOS && \
git checkout $TAG && \
git checkout $BRANCH && \
git submodule update --init --recursive && \
git fetch --tags

Expand Down

0 comments on commit 62b9d95

Please sign in to comment.