debian-stretch-titan: update deps on change
After the initial clone of osmo-ttcn3-hacks and deps, let docker download deps/Makefile to invalidate the cache if the file changed. Run "git pull" and "make deps" afterwards, but only if the Makefile is different. The "if" saves time in the initial build of the image, it avoids the "git fetch" on every dependency repository during "make deps". Related: OS#5017 Change-Id: I56673312cfb23375d67900016aaac1931f677275
This commit is contained in:
parent
61fed0ad39
commit
73d23109b1
|
@ -52,6 +52,12 @@ RUN DPKG_ARCH="$(dpkg --print-architecture)" && export $DPKG_ARCH && \
|
||||||
RUN git config --global user.email docker@dock.er && \
|
RUN git config --global user.email docker@dock.er && \
|
||||||
git config --global user.name "Dock Er"
|
git config --global user.name "Dock Er"
|
||||||
|
|
||||||
# clone osmo-ttcn3-hacks and deps
|
# clone osmo-ttcn3-hacks and deps, invalidate cache if deps change (OS#5017)
|
||||||
RUN git clone git://git.osmocom.org/osmo-ttcn3-hacks.git && \
|
RUN git clone git://git.osmocom.org/osmo-ttcn3-hacks.git && \
|
||||||
make -C /osmo-ttcn3-hacks deps
|
make -C /osmo-ttcn3-hacks deps
|
||||||
|
ADD https://git.osmocom.org/osmo-ttcn3-hacks/plain/deps/Makefile /tmp/deps-Makefile
|
||||||
|
RUN if ! diff -q /tmp/deps-Makefile /osmo-ttcn3-hacks/deps/Makefile; then \
|
||||||
|
cd /osmo-ttcn3-hacks && \
|
||||||
|
git pull && \
|
||||||
|
make deps; \
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in New Issue