+ use ssh key from host machine in workspace container

This commit is contained in:
2025-06-11 20:47:53 +03:00
parent 94fe970cd3
commit 92cefd6fcd
3 changed files with 25 additions and 0 deletions

View File

@ -126,9 +126,32 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
;fi
###########################################################################
# ssh:
###########################################################################
USER root
ARG INSTALL_SSH=false
ENV INSTALL_SSH ${INSTALL_SSH}
RUN if [ ${INSTALL_SSH} = true ]; then \
rm -f /etc/service/sshd/down \
;fi
USER laradock
RUN if [ ${INSTALL_SSH} = true ]; then \
mkdir -p ~/.ssh \
&& ln -s /run/secrets/user_ssh_key ~/.ssh/id_rsa \
&& ln -s /run/secrets/user_known_hosts ~/.ssh/known_hosts \
;fi
###########################################################################
# APT
###########################################################################
USER root
# once please
RUN apt update -qq