From 9c93e37114a7fe99b5fc0d776e0b8dff99cbbb75 Mon Sep 17 00:00:00 2001 From: Tianon Gravi Date: Mon, 31 Dec 2018 12:59:44 -0800 Subject: [PATCH] Add Windows 1809 support --- Dockerfile-windows.template | 2 +- Makefile | 9 ++++++-- .../hello-seattle/nanoserver-1709/Dockerfile | 2 +- amd64/hello-seattle/nanoserver-1709/hello.txt | 2 +- .../hello-seattle/nanoserver-1803/Dockerfile | 2 +- amd64/hello-seattle/nanoserver-1803/hello.txt | 2 +- .../hello-seattle/nanoserver-1809/Dockerfile | 3 +++ amd64/hello-seattle/nanoserver-1809/hello.txt | 22 +++++++++++++++++++ .../nanoserver-sac2016/Dockerfile | 2 +- .../nanoserver-sac2016/hello.txt | 2 +- amd64/hello-world/nanoserver-1709/Dockerfile | 2 +- amd64/hello-world/nanoserver-1709/hello.txt | 2 +- amd64/hello-world/nanoserver-1803/Dockerfile | 2 +- amd64/hello-world/nanoserver-1803/hello.txt | 2 +- amd64/hello-world/nanoserver-1809/Dockerfile | 3 +++ amd64/hello-world/nanoserver-1809/hello.txt | 22 +++++++++++++++++++ .../hello-world/nanoserver-sac2016/Dockerfile | 2 +- .../hello-world/nanoserver-sac2016/hello.txt | 2 +- amd64/hola-mundo/nanoserver-1709/Dockerfile | 2 +- amd64/hola-mundo/nanoserver-1709/hello.txt | 2 +- amd64/hola-mundo/nanoserver-1803/Dockerfile | 2 +- amd64/hola-mundo/nanoserver-1803/hello.txt | 2 +- amd64/hola-mundo/nanoserver-1809/Dockerfile | 3 +++ amd64/hola-mundo/nanoserver-1809/hello.txt | 22 +++++++++++++++++++ .../hola-mundo/nanoserver-sac2016/Dockerfile | 2 +- amd64/hola-mundo/nanoserver-sac2016/hello.txt | 2 +- generate-stackbrew-library.sh | 2 +- update.sh | 2 +- 28 files changed, 103 insertions(+), 23 deletions(-) create mode 100644 amd64/hello-seattle/nanoserver-1809/Dockerfile create mode 100644 amd64/hello-seattle/nanoserver-1809/hello.txt create mode 100644 amd64/hello-world/nanoserver-1809/Dockerfile create mode 100644 amd64/hello-world/nanoserver-1809/hello.txt create mode 100644 amd64/hola-mundo/nanoserver-1809/Dockerfile create mode 100644 amd64/hola-mundo/nanoserver-1809/hello.txt diff --git a/Dockerfile-windows.template b/Dockerfile-windows.template index 6526a7b..39e46b5 100644 --- a/Dockerfile-windows.template +++ b/Dockerfile-windows.template @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:XXX +FROM mcr.microsoft.com/windows/nanoserver:XXX COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/Makefile b/Makefile index bbf2eb1..bb13c25 100644 --- a/Makefile +++ b/Makefile @@ -12,12 +12,17 @@ $(C_TARGETS): hello.c $(CC) $(CFLAGS) -o '$@' -D DOCKER_IMAGE='"$(notdir $(@D))"' -D DOCKER_GREETING="\"$$(cat 'greetings/$(notdir $(@D)).txt')\"" -D DOCKER_ARCH='"$(TARGET_ARCH)"' '$<' $(STRIP) -R .comment -s '$@' @if [ '$(TARGET_ARCH)' = 'amd64' ]; then \ - for winVariant in nanoserver-sac2016 nanoserver-1709 nanoserver-1803; do \ + for winVariant in \ + nanoserver-sac2016 \ + nanoserver-1709 \ + nanoserver-1803 \ + nanoserver-1809 \ + ; do \ mkdir -p "$(@D)/$$winVariant"; \ '$@' | sed \ -e 's/[(]$(TARGET_ARCH)[)]/(windows-$(TARGET_ARCH), '"$$winVariant"')/g' \ -e 's/an Ubuntu container/a Windows Server container/g' \ - -e 's!ubuntu bash!microsoft/windowsservercore powershell!g' \ + -e 's!ubuntu bash!mcr.microsoft.com/windows/servercore powershell!g' \ -e 's![$$] docker!PS C:\\> docker!g' \ > "$(@D)/$$winVariant/hello.txt"; \ done; \ diff --git a/amd64/hello-seattle/nanoserver-1709/Dockerfile b/amd64/hello-seattle/nanoserver-1709/Dockerfile index 5ca5897..895df26 100644 --- a/amd64/hello-seattle/nanoserver-1709/Dockerfile +++ b/amd64/hello-seattle/nanoserver-1709/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:1709 +FROM mcr.microsoft.com/windows/nanoserver:1709 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-seattle/nanoserver-1709/hello.txt b/amd64/hello-seattle/nanoserver-1709/hello.txt index f946790..883cfba 100644 --- a/amd64/hello-seattle/nanoserver-1709/hello.txt +++ b/amd64/hello-seattle/nanoserver-1709/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hello-seattle/nanoserver-1803/Dockerfile b/amd64/hello-seattle/nanoserver-1803/Dockerfile index ccb9969..e336da2 100644 --- a/amd64/hello-seattle/nanoserver-1803/Dockerfile +++ b/amd64/hello-seattle/nanoserver-1803/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:1803 +FROM mcr.microsoft.com/windows/nanoserver:1803 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-seattle/nanoserver-1803/hello.txt b/amd64/hello-seattle/nanoserver-1803/hello.txt index 61cdec0..e8dc503 100644 --- a/amd64/hello-seattle/nanoserver-1803/hello.txt +++ b/amd64/hello-seattle/nanoserver-1803/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hello-seattle/nanoserver-1809/Dockerfile b/amd64/hello-seattle/nanoserver-1809/Dockerfile new file mode 100644 index 0000000..4c3525e --- /dev/null +++ b/amd64/hello-seattle/nanoserver-1809/Dockerfile @@ -0,0 +1,3 @@ +FROM mcr.microsoft.com/windows/nanoserver:1809 +COPY hello.txt C: +CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-seattle/nanoserver-1809/hello.txt b/amd64/hello-seattle/nanoserver-1809/hello.txt new file mode 100644 index 0000000..c9fd425 --- /dev/null +++ b/amd64/hello-seattle/nanoserver-1809/hello.txt @@ -0,0 +1,22 @@ + +Hello from DockerCon 2016 (Seattle)! +This message shows that your installation appears to be working correctly. + +To generate this message, Docker took the following steps: + 1. The Docker client contacted the Docker daemon. + 2. The Docker daemon pulled the "hello-seattle" image from the Docker Hub. + (windows-amd64, nanoserver-1809) + 3. The Docker daemon created a new container from that image which runs the + executable that produces the output you are currently reading. + 4. The Docker daemon streamed that output to the Docker client, which sent it + to your terminal. + +To try something more ambitious, you can run a Windows Server container with: + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell + +Share images, automate workflows, and more with a free Docker ID: + https://hub.docker.com/ + +For more examples and ideas, visit: + https://docs.docker.com/get-started/ + diff --git a/amd64/hello-seattle/nanoserver-sac2016/Dockerfile b/amd64/hello-seattle/nanoserver-sac2016/Dockerfile index 86394a4..3275f6b 100644 --- a/amd64/hello-seattle/nanoserver-sac2016/Dockerfile +++ b/amd64/hello-seattle/nanoserver-sac2016/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:sac2016 +FROM mcr.microsoft.com/windows/nanoserver:sac2016 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-seattle/nanoserver-sac2016/hello.txt b/amd64/hello-seattle/nanoserver-sac2016/hello.txt index 428ab8e..8431786 100644 --- a/amd64/hello-seattle/nanoserver-sac2016/hello.txt +++ b/amd64/hello-seattle/nanoserver-sac2016/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hello-world/nanoserver-1709/Dockerfile b/amd64/hello-world/nanoserver-1709/Dockerfile index 5ca5897..895df26 100644 --- a/amd64/hello-world/nanoserver-1709/Dockerfile +++ b/amd64/hello-world/nanoserver-1709/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:1709 +FROM mcr.microsoft.com/windows/nanoserver:1709 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-world/nanoserver-1709/hello.txt b/amd64/hello-world/nanoserver-1709/hello.txt index 1949d22..6b5006f 100644 --- a/amd64/hello-world/nanoserver-1709/hello.txt +++ b/amd64/hello-world/nanoserver-1709/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hello-world/nanoserver-1803/Dockerfile b/amd64/hello-world/nanoserver-1803/Dockerfile index ccb9969..e336da2 100644 --- a/amd64/hello-world/nanoserver-1803/Dockerfile +++ b/amd64/hello-world/nanoserver-1803/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:1803 +FROM mcr.microsoft.com/windows/nanoserver:1803 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-world/nanoserver-1803/hello.txt b/amd64/hello-world/nanoserver-1803/hello.txt index 6fee82f..f6acab6 100644 --- a/amd64/hello-world/nanoserver-1803/hello.txt +++ b/amd64/hello-world/nanoserver-1803/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hello-world/nanoserver-1809/Dockerfile b/amd64/hello-world/nanoserver-1809/Dockerfile new file mode 100644 index 0000000..4c3525e --- /dev/null +++ b/amd64/hello-world/nanoserver-1809/Dockerfile @@ -0,0 +1,3 @@ +FROM mcr.microsoft.com/windows/nanoserver:1809 +COPY hello.txt C: +CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-world/nanoserver-1809/hello.txt b/amd64/hello-world/nanoserver-1809/hello.txt new file mode 100644 index 0000000..b55b070 --- /dev/null +++ b/amd64/hello-world/nanoserver-1809/hello.txt @@ -0,0 +1,22 @@ + +Hello from Docker! +This message shows that your installation appears to be working correctly. + +To generate this message, Docker took the following steps: + 1. The Docker client contacted the Docker daemon. + 2. The Docker daemon pulled the "hello-world" image from the Docker Hub. + (windows-amd64, nanoserver-1809) + 3. The Docker daemon created a new container from that image which runs the + executable that produces the output you are currently reading. + 4. The Docker daemon streamed that output to the Docker client, which sent it + to your terminal. + +To try something more ambitious, you can run a Windows Server container with: + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell + +Share images, automate workflows, and more with a free Docker ID: + https://hub.docker.com/ + +For more examples and ideas, visit: + https://docs.docker.com/get-started/ + diff --git a/amd64/hello-world/nanoserver-sac2016/Dockerfile b/amd64/hello-world/nanoserver-sac2016/Dockerfile index 86394a4..3275f6b 100644 --- a/amd64/hello-world/nanoserver-sac2016/Dockerfile +++ b/amd64/hello-world/nanoserver-sac2016/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:sac2016 +FROM mcr.microsoft.com/windows/nanoserver:sac2016 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hello-world/nanoserver-sac2016/hello.txt b/amd64/hello-world/nanoserver-sac2016/hello.txt index bfeedf3..380c07e 100644 --- a/amd64/hello-world/nanoserver-sac2016/hello.txt +++ b/amd64/hello-world/nanoserver-sac2016/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hola-mundo/nanoserver-1709/Dockerfile b/amd64/hola-mundo/nanoserver-1709/Dockerfile index 5ca5897..895df26 100644 --- a/amd64/hola-mundo/nanoserver-1709/Dockerfile +++ b/amd64/hola-mundo/nanoserver-1709/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:1709 +FROM mcr.microsoft.com/windows/nanoserver:1709 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hola-mundo/nanoserver-1709/hello.txt b/amd64/hola-mundo/nanoserver-1709/hello.txt index a185476..f1f33c7 100644 --- a/amd64/hola-mundo/nanoserver-1709/hello.txt +++ b/amd64/hola-mundo/nanoserver-1709/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hola-mundo/nanoserver-1803/Dockerfile b/amd64/hola-mundo/nanoserver-1803/Dockerfile index ccb9969..e336da2 100644 --- a/amd64/hola-mundo/nanoserver-1803/Dockerfile +++ b/amd64/hola-mundo/nanoserver-1803/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:1803 +FROM mcr.microsoft.com/windows/nanoserver:1803 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hola-mundo/nanoserver-1803/hello.txt b/amd64/hola-mundo/nanoserver-1803/hello.txt index 63dbfcf..4926136 100644 --- a/amd64/hola-mundo/nanoserver-1803/hello.txt +++ b/amd64/hola-mundo/nanoserver-1803/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/amd64/hola-mundo/nanoserver-1809/Dockerfile b/amd64/hola-mundo/nanoserver-1809/Dockerfile new file mode 100644 index 0000000..4c3525e --- /dev/null +++ b/amd64/hola-mundo/nanoserver-1809/Dockerfile @@ -0,0 +1,3 @@ +FROM mcr.microsoft.com/windows/nanoserver:1809 +COPY hello.txt C: +CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hola-mundo/nanoserver-1809/hello.txt b/amd64/hola-mundo/nanoserver-1809/hello.txt new file mode 100644 index 0000000..4315320 --- /dev/null +++ b/amd64/hola-mundo/nanoserver-1809/hello.txt @@ -0,0 +1,22 @@ + +¡Hola de DockerCon EU 2015 (Barcelona)! +This message shows that your installation appears to be working correctly. + +To generate this message, Docker took the following steps: + 1. The Docker client contacted the Docker daemon. + 2. The Docker daemon pulled the "hola-mundo" image from the Docker Hub. + (windows-amd64, nanoserver-1809) + 3. The Docker daemon created a new container from that image which runs the + executable that produces the output you are currently reading. + 4. The Docker daemon streamed that output to the Docker client, which sent it + to your terminal. + +To try something more ambitious, you can run a Windows Server container with: + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell + +Share images, automate workflows, and more with a free Docker ID: + https://hub.docker.com/ + +For more examples and ideas, visit: + https://docs.docker.com/get-started/ + diff --git a/amd64/hola-mundo/nanoserver-sac2016/Dockerfile b/amd64/hola-mundo/nanoserver-sac2016/Dockerfile index 86394a4..3275f6b 100644 --- a/amd64/hola-mundo/nanoserver-sac2016/Dockerfile +++ b/amd64/hola-mundo/nanoserver-sac2016/Dockerfile @@ -1,3 +1,3 @@ -FROM microsoft/nanoserver:sac2016 +FROM mcr.microsoft.com/windows/nanoserver:sac2016 COPY hello.txt C: CMD ["cmd", "/C", "type C:\\hello.txt"] diff --git a/amd64/hola-mundo/nanoserver-sac2016/hello.txt b/amd64/hola-mundo/nanoserver-sac2016/hello.txt index e326472..a486506 100644 --- a/amd64/hola-mundo/nanoserver-sac2016/hello.txt +++ b/amd64/hola-mundo/nanoserver-sac2016/hello.txt @@ -12,7 +12,7 @@ To generate this message, Docker took the following steps: to your terminal. To try something more ambitious, you can run a Windows Server container with: - PS C:\> docker run -it microsoft/windowsservercore powershell + PS C:\> docker run -it mcr.microsoft.com/windows/servercore powershell Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/ diff --git a/generate-stackbrew-library.sh b/generate-stackbrew-library.sh index 864db61..6a11cd1 100755 --- a/generate-stackbrew-library.sh +++ b/generate-stackbrew-library.sh @@ -62,7 +62,7 @@ for arch in "${arches[@]}"; do EOE done -for winVariant in nanoserver-{sac2016,1709,1803}; do +for winVariant in nanoserver-{sac2016,1709,1803,1809}; do winArches=( *"/$image/$winVariant/hello.txt" ) winArches=( "${winArches[@]%"/$image/$winVariant/hello.txt"}" ) diff --git a/update.sh b/update.sh index d34f67e..961ef8b 100755 --- a/update.sh +++ b/update.sh @@ -17,7 +17,7 @@ for h in */*/nanoserver-*/Dockerfile; do nano="$(dirname "$h")" nano="$(basename "$nano")" nano="${nano#nanoserver-}" - sed -i 's!FROM .*!FROM microsoft/nanoserver:'"$nano"'!' "$h" + sed -i 's!FROM .*!FROM mcr.microsoft.com/windows/nanoserver:'"$nano"'!' "$h" done for h in amd64/*/hello; do