summaryrefslogtreecommitdiffstats
path: root/lava-master
diff options
context:
space:
mode:
Diffstat (limited to 'lava-master')
-rw-r--r--lava-master/Dockerfile11
-rwxr-xr-xlava-master/scripts/setup.sh4
2 files changed, 10 insertions, 5 deletions
diff --git a/lava-master/Dockerfile b/lava-master/Dockerfile
index 5d2a119..f8ed805 100644
--- a/lava-master/Dockerfile
+++ b/lava-master/Dockerfile
@@ -1,4 +1,4 @@
-FROM baylibre/lava-master-base:2018.11-1_bpo9_1
+FROM baylibre/lava-master-base:2019.03_stretch
COPY backup /root/backup/
@@ -20,11 +20,12 @@ COPY scripts/setup.sh /
COPY settings.conf /etc/lava-server/
-COPY device-types-patch/ /root/device-types-patch/
-RUN cd /etc/lava-server/dispatcher-config/device-types/ && for patch in $(ls /root/device-types-patch/*patch) ; do sed -i 's,lava_scheduler_app/tests/device-types/,,' $patch && patch < $patch || exit $?; done
-
COPY lava-patch/ /root/lava-patch
-RUN cd /usr/lib/python3/dist-packages && for patch in $(ls /root/lava-patch/*patch) ; do patch -p1 < $patch || exit $?;done
+RUN cd /usr/lib/python3/dist-packages && for patch in $(ls /root/lava-patch/*patch| sort) ; do echo $patch && patch -p1 < $patch || exit $?;done
+RUN rsync -avr /usr/lib/python3/dist-packages/lava_scheduler_app/tests/device-types/ /etc/lava-server/dispatcher-config/device-types/
+
+COPY device-types-patch/ /root/device-types-patch/
+RUN cd /etc/lava-server/dispatcher-config/device-types/ && for patch in $(ls /root/device-types-patch/*patch) ; do sed -i 's,lava_scheduler_app/tests/device-types/,,' $patch && echo $patch && patch < $patch || exit $?; done
COPY zmq_auth/ /etc/lava-dispatcher/certificates.d/
diff --git a/lava-master/scripts/setup.sh b/lava-master/scripts/setup.sh
index c22a06f..489dd51 100755
--- a/lava-master/scripts/setup.sh
+++ b/lava-master/scripts/setup.sh
@@ -151,6 +151,10 @@ mkdir -p /root/.lavadocker/
if [ -e /root/device-types ];then
for i in $(ls /root/device-types/*jinja2)
do
+ if [ -e /etc/lava-server/dispatcher-config/device-types/$(basename $i) ];then
+ echo "WARNING: overwriting device-type $i"
+ diff -u "/etc/lava-server/dispatcher-config/device-types/$(basename $i)" $i
+ fi
cp $i /etc/lava-server/dispatcher-config/device-types/
devicetype=$(basename $i |sed 's,.jinja2,,')
lava-server manage device-types list | grep -q "[[:space:]]$devicetype[[:space:]]"