Windows Container On Azure
Note:Microsoft Azure does not support Hyper-V containers. To complete Hyper-V Container exercises, you need an on-prem container host.
使用Portal创建WS2016 Core with Containers TP4,步骤不赘述。
虚拟机创建完成后,使用PowerShell命令进入PowerShell session
验证Windows Server Core OS镜像已经安装,使用Get-Container Image命令
配置防火墙规则
if (!(Get-NetFirewallRule | where {$_.Name -eq"TCP80"})) { New-NetFirewallRule -Name "TCP80" -DisplayName "HTTP on TCP/80" -Protocol tcp -LocalPort 80 -Action Allow -Enabled True }
配置IIS主页
Enter-PSSession -ContainerName IIS -RunAsAdministrator
del C:\inetpub\wwwroot\iisstart.htm
" Windows Server Container On Azure!" > C:\inetpub\wwwroot\index.html