Sign inSign up

keidock/rust-sshd

By keidock

•Updated over 4 years ago

Image
0

64

keidock/rust-sshd repository overview

⁠This is the officially distributed rust image with rust-lldb and sshd added.

⁠dockerfile
FROM rust

RUN apt update && \
    apt install -y rust-lldb && \
    apt install -y openssh-server && \
    apt install -y supervisor

# supervisor settings
ADD supervisord.conf /etc/supervisor/conf.d/

# sshd settings
RUN mkdir /var/run/sshd
ARG ROOT_PASSWORD
RUN echo root:${ROOT_PASSWORD} | chpasswd

RUN sed -i 's/#\?PermitRootLogin prohibit-password/PermitRootLogin yes/' /etc/ssh/sshd_config
RUN sed 's@session\s*required\s*pam_loginuid.so@session optional pam_loginuid.so@g' -i /etc/pam.d/sshd
RUN ssh-keygen -A

ENV NOTVISIBLE "in users profile"
RUN echo "export VISIBLE=now" >> /etc/profile

#EXPOSE 22

CMD ["/usr/bin/supervisord"]
⁠supervisord.conf
[supervisord]
nodaemon=true

[program:sshd]
command=/usr/sbin/sshd -D
⁠build.sh
#!/bin/sh
ver=v0.1-rust1.62.0
sudo docker build --tag "rust-sshd:$ver" --build-arg ROOT_PASSWORD=rustroot .

Tag summary

Content type

Image

Digest

Size

596.3 MB

Last updated

over 4 years ago

docker pull keidock/rust-sshd:v0.1-rust1.62.0