aboutsummaryrefslogtreecommitdiff
path: root/lava/dispatcher/staging
diff options
context:
space:
mode:
authorSenthil Kumaran S <senthil.kumaran@linaro.org>2018-04-27 15:45:24 +0530
committerSenthil Kumaran S <senthil.kumaran@linaro.org>2018-05-29 19:24:16 +0530
commit3c5bd48e7520449c6a1f2322e3252f1a5768614a (patch)
treeb4bcea81e935973e42e83d71b2a7de1bde012125 /lava/dispatcher/staging
parent8abda302b34d21071ad8be1e6e36b86294fb71dd (diff)
downloaddockerfiles-3c5bd48e7520449c6a1f2322e3252f1a5768614a.tar.gz
lava-dispatcher: Docker images for both production and staging.
* Re-organize the build.sh script in order to build for both production and staging repo based docker images by accepting options. * Add Dockerfile for building from staging-repo that will build on a daily basis with the latest lava-dispatcher packages made from master git branch. * Use a single entrypoint.sh file shared between both these supported builds. * Install lava-common which is required after single code base changes. * Use python3 to start lava-slave and remove timeout option. Change-Id: I23b0afce1e2ae68ee67929e48922ae7bea3ad909
Diffstat (limited to 'lava/dispatcher/staging')
-rw-r--r--lava/dispatcher/staging/stretch-amd64/Dockerfile46
1 files changed, 46 insertions, 0 deletions
diff --git a/lava/dispatcher/staging/stretch-amd64/Dockerfile b/lava/dispatcher/staging/stretch-amd64/Dockerfile
new file mode 100644
index 00000000..f3108f3a
--- /dev/null
+++ b/lava/dispatcher/staging/stretch-amd64/Dockerfile
@@ -0,0 +1,46 @@
+FROM debian:stretch
+
+# Docker image for LAVA dispatcher with master branch, built daily.
+
+LABEL maintainer="senthil.kumaran@linaro.org"
+
+# Install the required dependencies
+RUN echo 'locales locales/locales_to_be_generated multiselect C.UTF-8 UTF-8, en_US.UTF-8 UTF-8 ' | debconf-set-selections && \
+ echo 'locales locales/default_environment_locale select en_US.UTF-8' | debconf-set-selections && \
+ export DEBIAN_FRONTEND=noninteractive && \
+ apt-get update && \
+ apt-get -y upgrade && \
+ apt-get -y install ntp git tftpd-hpa openbsd-inetd ser2net qemu-kvm \
+ qemu-system-x86 qemu-system-arm qemu-user-static libguestfs-tools \
+ nfs-kernel-server rpcbind u-boot-tools unzip xz-utils debootstrap \
+ bridge-utils dfu-util img2simg emacs-nox vim gnupg2 sed expect grep wget \
+ openssh-server
+
+# Add LAVA stretch-backports production repo
+RUN wget -qO - http://images.validation.linaro.org/production-repo/production-repo.key.asc | apt-key add - && \
+ echo "deb http://images.validation.linaro.org/production-repo stretch-backports main" >/etc/apt/sources.list.d/linaro.list
+
+RUN echo 'locales locales/locales_to_be_generated multiselect C.UTF-8 UTF-8, en_US.UTF-8 UTF-8 ' | debconf-set-selections && \
+ echo 'locales locales/default_environment_locale select en_US.UTF-8' | debconf-set-selections && \
+ export DEBIAN_FRONTEND=noninteractive && \
+ apt-get update && \
+ apt-get -y upgrade && \
+ apt-get -y -t stretch-backports install lava-common lava-dispatcher \
+ lava-lxc-mocker && \
+ apt-get clean && \
+ rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
+
+# Expose services ports
+EXPOSE 22
+
+# Set entrypoint script
+COPY ./entrypoint.sh /entrypoint.sh
+ENTRYPOINT [ "/entrypoint.sh" ]
+
+# Following is a sample docker run command to use this image
+#
+# sudo docker run -v /boot:/boot -v /lib/modules:/lib/modules \
+# -v /var/run/docker.sock:/var/run/docker.sock -itd -e HOSTNAME='worker-1' \
+# -e MASTER='tcp://192.168.1.2:5556' -e SOCKET_ADDR='tcp://192.168.1.2:5555' \
+# -e LOG_LEVEL='DEBUG' -p 2222:22 --privileged \
+# --name ld-2017.12 stylesen/lava-dispatcher:2017.12