From 38b6c37ebb1afa1b18cdd5fc64b54decfbb6a857 Mon Sep 17 00:00:00 2001 From: Nick Gerace Date: Thu, 18 Feb 2021 11:34:52 -0500 Subject: [PATCH] Fix indent for windows tolerations --- windows-helm/templates/windows.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/windows-helm/templates/windows.yaml b/windows-helm/templates/windows.yaml index 5f62af3..f257b41 100644 --- a/windows-helm/templates/windows.yaml +++ b/windows-helm/templates/windows.yaml @@ -31,16 +31,16 @@ spec: app: win-webserver name: win-webserver spec: - containers: + containers: - name: windowswebserver image: "mcr.microsoft.com/windows/servercore:{{ .Values.image.tag }}" command: - powershell.exe - -command - "<#code used from https://gist.github.com/19WAS85/5424431#> ; $$listener = New-Object System.Net.HttpListener ; $$listener.Prefixes.Add('http://*:80/') ; $$listener.Start() ; $$callerCounts = @{} ; Write-Host('Listening at http://*:80/') ; while ($$listener.IsListening) { ;$$context = $$listener.GetContext() ;$$requestUrl = $$context.Request.Url ;$$clientIP = $$context.Request.RemoteEndPoint.Address ;$$response = $$context.Response ;Write-Host '' ;Write-Host('> {0}' -f $$requestUrl) ; ;$$count = 1 ;$$k=$$callerCounts.Get_Item($$clientIP) ;if ($$k -ne $$null) { $$count += $$k } ;$$callerCounts.Set_Item($$clientIP, $$count) ;$$ip=(Get-NetAdapter | Get-NetIpAddress); $$header='

Windows Container Web Server

' ;$$callerCountsString='' ;$$callerCounts.Keys | % { $$callerCountsString+='

IP {0} callerCount {1} ' -f $$ip[1].IPAddress,$$callerCounts.Item($$_) } ;$$footer='' ;$$content='{0}{1}{2}' -f $$header,$$callerCountsString,$$footer ;Write-Output $$content ;$$buffer = [System.Text.Encoding]::UTF8.GetBytes($$content) ;$$response.ContentLength64 = $$buffer.Length ;$$response.OutputStream.Write($$buffer, 0, $$buffer.Length) ;$$response.Close() ;$$responseStatus = $$response.StatusCode ;Write-Host('< {0}' -f $$responseStatus) } ; " - nodeSelector: - kubernetes.io/os: windows - tolerations: + nodeSelector: + kubernetes.io/os: windows + tolerations: - key: cattle.io/os operator: "Equal" value: "windows"