From 00db936ce5c1c87578db02494a0dde4e97c1a478 Mon Sep 17 00:00:00 2001 From: Michael Friis Date: Thu, 16 Mar 2017 10:29:10 -0700 Subject: [PATCH] add Dockerfile for building windows image --- stable/windows/Dockerfile | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 stable/windows/Dockerfile diff --git a/stable/windows/Dockerfile b/stable/windows/Dockerfile new file mode 100644 index 00000000..4019c40e --- /dev/null +++ b/stable/windows/Dockerfile @@ -0,0 +1,16 @@ +FROM microsoft/windowsservercore + +SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] + +ENV NGINX_VERSION 1.10.3 +RUN Invoke-WebRequest -Uri https://nginx.org/download/nginx-$Env:NGINX_VERSION.zip -OutFile nginx.zip ; \ + Expand-Archive nginx.zip -DestinationPath $Env:ProgramFiles ; \ + Remove-Item -Force nginx.zip ; \ + Move-Item $Env:ProgramFiles\nginx-* $Env:ProgramFiles\nginx + +RUN setx /M PATH $($Env:PATH + ';' + $Env:ProgramFiles + '\nginx') + +EXPOSE 80 443 +WORKDIR "C:\Program Files\nginx" +CMD Start-Process -NoNewWindow -FilePath nginx.exe ; \ + Add-Content logs\access.log 'nginx started...' ; Get-Content -Wait logs\access.log