builder/remotecontext: use lowercase for error

Errors should not be capitalized. This error was marked as
"being compatible" with the old error, However, looking at
the original error that was in place before d1faf3df27,
I noticed that the error was lowercase before, so it should
be ok to change it back to be lowercase.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2020-08-07 20:51:23 +02:00
parent c997a4995d
commit afd9a6c2b2
No known key found for this signature in database
GPG key ID: 76698F39D527CE8C
2 changed files with 2 additions and 2 deletions

View file

@ -50,7 +50,7 @@ func TestDockerfileOutsideTheBuildContext(t *testing.T) {
contextDir, cleanup := createTestTempDir(t, "", "builder-dockerfile-test")
defer cleanup()
expectedError := "Forbidden path outside the build context: ../../Dockerfile ()"
expectedError := "path outside the build context: ../../Dockerfile ()"
if runtime.GOOS == "windows" {
expectedError = "failed to resolve scoped path ../../Dockerfile ()"
}

View file

@ -185,7 +185,7 @@ func FullPath(remote builder.Source, path string) (string, error) {
if runtime.GOOS == "windows" {
return "", fmt.Errorf("failed to resolve scoped path %s (%s): %s. Possible cause is a forbidden path outside the build context", path, fullPath, err)
}
return "", fmt.Errorf("Forbidden path outside the build context: %s (%s)", path, fullPath) // backwards compat with old error
return "", fmt.Errorf("forbidden path outside the build context: %s (%s)", path, fullPath) // backwards compat with old error
}
return fullPath, nil
}