blob: 706f94a4599338ff3123cbc4b2f88a132374fe2a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
|
FROM quay.io/fathi_boudra/ubuntu:trusty-armhf
COPY *.list *.key /etc/apt/sources.list.d/
COPY tcwg-buildslave/.ssh /etc/skel/.ssh
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 devscripts \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
alien \
autoconf \
autogen \
automake \
bc \
bison \
build-essential \
ccache \
ccrypt \
byacc \
debhelper \
dejagnu \
dh-autoreconf \
dh-translations \
distro-info-data \
emacs \
fakeroot \
flex \
gawk \
gdb \
gdbserver \
git \
libexpat1-dev \
liblzma-dev \
libncurses5-dev \
libpython2.7-dev \
libreadline-dev \
libssl-dev \
libtool \
make \
net-tools \
netcat \
openjdk-7-jdk \
openssh-server \
python-dev \
qemu-user \
rsync \
sudo \
texinfo \
texlive-fonts-recommended \
texlive-latex-recommended \
time \
vim \
wget \
xz-utils \
zlib1g-dev \
&& apt-get clean \
&& rm -rf \
/etc/apt/sources.list.d/*.key \
/var/lib/apt/lists/* \
/tmp/* \
/var/tmp/*
RUN chmod 0700 /etc/skel/.ssh \
&& groupadd -g 9000 tcwg-infra \
&& useradd -m -g tcwg-infra -u 11827 tcwg-buildslave \
&& rm -rf /etc/skel/.ssh \
&& echo 'tcwg-buildslave ALL = NOPASSWD: ALL' > /etc/sudoers.d/jenkins \
&& chmod 440 /etc/sudoers.d/jenkins \
&& install -D -p -m0755 /usr/share/doc/git/contrib/workdir/git-new-workdir /usr/local/bin/git-new-workdir \
&& sed -i -e 's:^session *required *pam_loginuid.so:# session required pam_loginuid.so:' /etc/pam.d/sshd \
&& mkdir -p /var/run/sshd
# Unfortunately, VOLUME doesn't support bind-mounts for portability reasons.
# Therefore, the bind-mounts for the following paths are configured in
# the ci.linaro.org's docker plugin.
# Sources caches (read-only):
# /home/tcwg-buildslave/snapshots-ref:/home/tcwg-buildslave/snapshots-ref:ro
# Workspace (read-write):
# /home/tcwg-buildslave/workspace:/home/tcwg-buildslave/workspace:rw
# 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
EXPOSE 22
CMD ["linux32", "/usr/sbin/sshd", "-D"]
|