diff --git a/hack/make.ps1 b/hack/make.ps1 index e1e91e52c2..f15f8ef225 100644 --- a/hack/make.ps1 +++ b/hack/make.ps1 @@ -130,7 +130,7 @@ Function Check-InContainer() { # outside of a container where it may be out of date with master. Function Verify-GoVersion() { Try { - $goVersionDockerfile=(Get-Content ".\Dockerfile" | Select-String "ENV GO_VERSION").ToString().Split(" ")[2] + $goVersionDockerfile=(Select-String -Path ".\Dockerfile" -Pattern "^FROM golang:").ToString().Split(" ")[1].SubString(7) $goVersionInstalled=(go version).ToString().Split(" ")[2].SubString(2) } Catch [Exception] {