mirror of
https://github.com/shadow1ng/fscan.git
synced 2026-09-25 12:41:53 +08:00
fix: SSH优化和修复
This commit is contained in:
@@ -11,7 +11,7 @@ RUN mkdir /var/run/sshd
|
||||
|
||||
# 允许root用户SSH登录并设置密码
|
||||
RUN sed -i 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/' /etc/ssh/sshd_config
|
||||
RUN echo 'root:123456' | chpasswd
|
||||
RUN echo 'root:Aa123456789' | chpasswd
|
||||
|
||||
# 开放22端口
|
||||
EXPOSE 22
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
docker build -t ubuntu-ssh .
|
||||
docker run -d -p 22:22 ubuntu-ssh
|
||||
docker run -d -p 2222:22 ubuntu-ssh
|
||||
Reference in New Issue
Block a user