From 20aee0309398f8d82b92b9e8b05e4d536371916e Mon Sep 17 00:00:00 2001 From: quicksilver Date: Thu, 19 Dec 2019 15:31:47 +0800 Subject: [PATCH] add test enviroment images --- docker/test_env/Dockerfile | 14 ++++++++++++++ docker/test_env/docker-entrypoint.sh | 9 +++++++++ 2 files changed, 23 insertions(+) create mode 100644 docker/test_env/Dockerfile create mode 100755 docker/test_env/docker-entrypoint.sh diff --git a/docker/test_env/Dockerfile b/docker/test_env/Dockerfile new file mode 100644 index 0000000000..0699b5a642 --- /dev/null +++ b/docker/test_env/Dockerfile @@ -0,0 +1,14 @@ +FROM python:3.6.8-jessie + +RUN apt-get update && apt-get install -y --no-install-recommends wget apt-transport-https && \ + wget -qO- "https://get.helm.sh/helm-v3.0.2-linux-amd64.tar.gz" | tar --strip-components=1 -xz -C /usr/local/bin linux-amd64/helm && \ + sh -c 'echo deb https://mirrors.aliyun.com/kubernetes/apt/ kubernetes-xenial main > /etc/apt/sources.list.d/kubernetes.list' && \ + apt-get update && apt-get install -y --no-install-recommends \ + build-essential kubectl && \ + apt-get remove --purge -y + +COPY docker-entrypoint.sh /app/docker-entrypoint.sh +WORKDIR /root + +ENTRYPOINT [ "/app/docker-entrypoint.sh" ] +CMD [ "start" ] diff --git a/docker/test_env/docker-entrypoint.sh b/docker/test_env/docker-entrypoint.sh new file mode 100755 index 0000000000..af9ba0ba66 --- /dev/null +++ b/docker/test_env/docker-entrypoint.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +set -e + +if [ "$1" = 'start' ]; then + tail -f /dev/null +fi + +exec "$@" \ No newline at end of file