blob: 505a7b8553b2528612d204f633e5901c8f0aa6cf [file] [log] [blame]
Leonardo Sandoval98d25902020-05-24 19:50:27 -07001FROM ${OS}:${OS_VER} as FVP
2
3ENV DEBIAN_FRONTEND=noninteractive
4ENV PKG_DEPS="\
5 bc \
6 ca-certificates \
7 curl \
8 libatomic1 \
9 libdbus-1-3 \
10 openssh-server \
11 telnet \
12 xterm \
13"
14
15RUN set -e ;\
16 apt update -q=2 ;\
17 apt full-upgrade -q=2 --yes ;\
18 apt install -q=2 --yes --no-install-recommends ${PKG_DEPS} ;\
19 # Cleanup
20 apt clean ;\
21 rm -rf /var/lib/apt/lists/* /tmp/*
22
23FROM FVP
24
25WORKDIR ${MODEL_DIR}
26
27COPY setup-sshd /usr/sbin/setup-sshd
Paul Sokolovsky30619ea2022-12-01 17:13:15 +030028COPY stdout-flush-wrapper.sh /usr/bin/stdout-flush-wrapper.sh
Paul Sokolovsky69bdd3b2023-04-04 12:26:30 +030029COPY stdout-flush-wrapper-debug.sh /usr/bin/stdout-flush-wrapper-debug.sh
Leonardo Sandoval98d25902020-05-24 19:50:27 -070030
31# Add the FVP model tarball
32# NOTE: some tarballs contain an installer script others don't, so it may be the case
33# that the ADD instruction do install the model under /opt/model
Paul Sokolovskyb5cc7742022-11-16 22:08:00 +030034ADD ${TARBALL} .
Leonardo Sandoval98d25902020-05-24 19:50:27 -070035
36# Install packages and model
37RUN ${MODEL_DIR}/${MODEL}.sh \
38 --i-agree-to-the-contained-eula \
39 --verbose \
40 --destination ${MODEL_DIR}/${MODEL} && rm -f ${MODEL_DIR}/${MODEL}.sh || true
41
42EXPOSE 22
43ENTRYPOINT ["/usr/sbin/setup-sshd"]