diff options
author | ubuntu <ubuntu@localhost.localdomain> | 2016-07-21 15:52:30 +0000 |
---|---|---|
committer | Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org> | 2016-07-21 17:56:12 +0100 |
commit | 7f174cdf2d926a1e31c2f354f3e2dd5f20e79605 (patch) | |
tree | c8fcae0833e1bd607728e703cd66226cb4e7ef30 /trusty-arm64-tcwg-test/Dockerfile | |
parent | f67d615d9ee93a3af0500b5c5926682e8dcad9d8 (diff) |
trusty-{arm64,armhf}-tcwg-test: New images
... for testing toolchain builds. Also import .ssh/* configuration
from /srv/docker/ssh/.
Change-Id: I44d694b1bb9b1f76cfe675d73ab83fa492eeaa2a
Diffstat (limited to 'trusty-arm64-tcwg-test/Dockerfile')
-rw-r--r-- | trusty-arm64-tcwg-test/Dockerfile | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/trusty-arm64-tcwg-test/Dockerfile b/trusty-arm64-tcwg-test/Dockerfile new file mode 100644 index 0000000..647e641 --- /dev/null +++ b/trusty-arm64-tcwg-test/Dockerfile @@ -0,0 +1,51 @@ +FROM quay.io/fathi_boudra/ubuntu:trusty-arm64 + +COPY *.list *.key /etc/apt/sources.list.d/ + +RUN echo 'deb http://ports.ubuntu.com/ubuntu-ports trusty main universe' > /etc/apt/sources.list \ + && apt-key add /etc/apt/sources.list.d/*.key \ + && apt-get update \ + && DEBIAN_FRONTEND=noninteractive apt-get dist-upgrade -y \ + && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \ + openssh-server \ + rsync \ + sudo \ + wget \ + xz-utils \ + && apt-get clean \ + && rm -rf \ + /etc/apt/sources.list.d/*.key \ + /var/lib/apt/lists/* \ + /tmp/* \ + /var/tmp/* + +RUN groupadd -g 9000 tcwg-infra \ + && useradd -m -g tcwg-infra -u 11827 tcwg-buildslave \ + && echo 'tcwg-buildslave ALL = NOPASSWD: ALL' > /etc/sudoers.d/jenkins \ + && chmod 440 /etc/sudoers.d/jenkins \ + && sed -i -e 's:^session *required *pam_loginuid.so:# session required pam_loginuid.so:' /etc/pam.d/sshd \ + && mkdir -p /var/run/sshd + +# Increase the limit for concurrent connections and for connection sharing, +# and enable root login. +RUN sed -i \ + -e "/.*MaxStartups.*/d" \ + -e "/.*MaxSesssions.*/d" \ + -e "/.*PermitRootLogin.*/d" /etc/ssh/sshd_config \ + && echo "MaxStartups 256" >> /etc/ssh/sshd_config \ + && echo "MaxSessions 256" >> /etc/ssh/sshd_config \ + && echo "PermitRootLogin without-password" >> /etc/ssh/sshd_config + +EXPOSE 22 +CMD ["/usr/sbin/sshd", "-D"] + +COPY tcwg-buildslave/.ssh /root/.ssh +COPY tcwg-buildslave/.ssh /home/tcwg-buildslave/.ssh +RUN chown -R tcwg-buildslave:tcwg-infra /home/tcwg-buildslave/.ssh/ + +# We use ssh multiplexing, which creates sockets in /tmp. Overlayfs, +# which docker is using can't host sockets, so we use a scratch mount +# for /tmp. This requires that we add --rm option to "docker run" +# invocations (e.g., mark "Remove volumes" checkbox in docker plugin) to +# cleanup host directories used for the scratch mounts. +VOLUME /tmp |