mirror of https://github.com/docker/docker-py.git
25 lines
660 B
Plaintext
25 lines
660 B
Plaintext
ARG API_VERSION=1.39
|
|
ARG ENGINE_VERSION=19.03.12
|
|
|
|
FROM docker:${ENGINE_VERSION}-dind
|
|
|
|
RUN apk add --no-cache \
|
|
openssh
|
|
|
|
# Add the keys and set permissions
|
|
RUN ssh-keygen -A
|
|
|
|
# copy the test SSH config
|
|
# Add the keys and set permissions
|
|
RUN ssh-keygen -t rsa -N '' -f /root/.ssh/id_rsa
|
|
RUN cat /root/.ssh/id_rsa.pub > /root/.ssh/authorized_keys
|
|
RUN chmod 600 /root/.ssh/authorized_keys
|
|
|
|
RUN echo "IgnoreUserKnownHosts yes" >> /etc/ssh/sshd_config && \
|
|
echo "PubkeyAuthentication yes" >> /etc/ssh/sshd_config && \
|
|
echo "PermitRootLogin yes" >> /etc/ssh/sshd_config
|
|
|
|
RUN echo "root:root" | chpasswd
|
|
RUN ln -s /usr/local/bin/docker /usr/bin/docker
|
|
EXPOSE 22
|