概览
web app on linux: azure 提供的一种原生linux操作系统SSH: 为了网络服务安全的一种网络加密协议,多用来确保远程登录系统的安全 https://zh.wikipedia.org/wiki/Secure_ShellDocker image: 支持SSH后,可以访问azuer上运行状态的image, 类似于docker exec -it imagename bash 访问地址:https:// yoursitename.scm.azurewebsites.net /webssh/host
Docker Image Code
Dockerfile
RUN apt-get update \
&& apt-get install -y --no-install-recommends openssh-server \
&& echo
"root:Docker!" | chpasswd
...
COPY sshd_config /etc/ssh/
...
EXPOSE
2222
sshd_config
Port 2222
ListenAddress
0.0.0.0
LoginGraceTime
180
X11Forwarding
yes
Ciphers aes128-cbc,3des-cbc,aes256-cbc
MACs hmac-sha1,hmac-sha1-
96
StrictModes
yes
SyslogFacility DAEMON
PrintMotd
no
IgnoreRhosts
no
RhostsRSAAuthentication
yes
RSAAuthentication
no
PasswordAuthentication
yes
PermitEmptyPasswords
no
PermitRootLogin
yes
start ssh service (e.g.entrypoint.sh)
service ssh
start
URL
Source Code: https://github.com/Song2017/Microsoft/tree/devapm/docker-library/apache-php-mysqlDocument: https://docs.microsoft.com/en-us/azure/app-service-web/app-service-linux-ssh-support