|
FROM debian:11 |
|
|
|
RUN apt update |
|
RUN apt install -y cmake make gcc g++ git curl sudo openssh-server |
|
RUN curl -sL https://deb.nodesource.com/setup_18.x | sudo -E bash - |
|
RUN apt install -y nodejs |
|
RUN npm i -g yarn |
|
RUN yarn global add wetty |
|
|
|
RUN echo 'root:root' | chpasswd |
|
|
|
RUN useradd -u 1000 xd |
|
|
|
|
|
RUN echo 'xd:xd' | chpasswd |
|
|
|
|
|
RUN ssh-keygen -A |
|
RUN sed -ri 's/^#?PermitRootLogin\s+.*/PermitRootLogin yes/' /etc/ssh/sshd_config |
|
RUN sed -ri 's/UsePAM yes/#UsePAM yes/g' /etc/ssh/sshd_config |
|
RUN mkdir /root/.ssh |
|
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* |
|
|
|
EXPOSE 7860 |
|
|
|
CMD /usr/sbin/sshd -D & wetty -p 7860 --allow-remote-hosts && tail -f /dev/null |
|
|