Allow to pass project from external directory
This patch allows to pass directory with source code of projects to conteiner during build. This is useful when it is not possible to clone project in anonymous mode. Change-Id: Id157ad614b790a87d8c8910a438a29887f9fc46e
This commit is contained in:
@@ -32,6 +32,7 @@ ARG NOVNC_REF=${NOVNC_REF:-v1.0.0}
|
||||
ARG SPICE_REPO=${SPICE_REPO:-https://gitlab.freedesktop.org/spice/spice-html5.git}
|
||||
ARG SPICE_REF=${SPICE_REF:-spice-html5-0.1.6}
|
||||
|
||||
ADD data /tmp/
|
||||
COPY scripts /opt/loci/scripts
|
||||
ADD bindep.txt pydep.txt $EXTRA_BINDEP $EXTRA_PYDEP /opt/loci/
|
||||
|
||||
|
||||
2
data/.gitignore
vendored
Normal file
2
data/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
*
|
||||
!.gitignore
|
||||
@@ -2,8 +2,10 @@
|
||||
|
||||
set -eux
|
||||
|
||||
git clone ${PROJECT_REPO} /tmp/${PROJECT}
|
||||
pushd /tmp/${PROJECT}
|
||||
git fetch ${PROJECT_REPO} ${PROJECT_REF}
|
||||
git checkout FETCH_HEAD
|
||||
popd
|
||||
if [[ ! -d /tmp/${PROJECT} ]]; then
|
||||
git clone ${PROJECT_REPO} /tmp/${PROJECT}
|
||||
pushd /tmp/${PROJECT}
|
||||
git fetch ${PROJECT_REPO} ${PROJECT_REF}
|
||||
git checkout FETCH_HEAD
|
||||
popd
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user