diff --git a/platform/defaults.go b/platform/defaults.go index 4218e4d72..16a98a2b1 100644 --- a/platform/defaults.go +++ b/platform/defaults.go @@ -56,8 +56,8 @@ const ( // via a credential helper, or via the `CNB_REGISTRY_AUTH` environment variable. See [auth.DefaultKeychain] for further information. const EnvUseDaemon = "CNB_USE_DAEMON" -// EnvInsecureRegistry configures the lifecycle to export the application to a remote "insecure" registry -const EnvInsecureRegistry = "CNB_INSECURE_REGISTRIES" +// EnvInsecureRegistries configures the lifecycle to export the application to a remote "insecure" registry +const EnvInsecureRegistries = "CNB_INSECURE_REGISTRIES" // ## Provided to handle inputs and outputs in OCI layout format diff --git a/platform/lifecycle_inputs.go b/platform/lifecycle_inputs.go index 9d00d16b5..6a650ddd8 100644 --- a/platform/lifecycle_inputs.go +++ b/platform/lifecycle_inputs.go @@ -90,7 +90,7 @@ func NewLifecycleInputs(platformAPI *api.Version) *LifecycleInputs { PlatformAPI: platformAPI, ExtendKind: envOrDefault(EnvExtendKind, DefaultExtendKind), UseDaemon: boolEnv(EnvUseDaemon), - InsecureRegistries: sliceEnv(EnvInsecureRegistry), + InsecureRegistries: sliceEnv(EnvInsecureRegistries), UseLayout: boolEnv(EnvUseLayout), // Provided by the base image diff --git a/platform/lifecycle_inputs_test.go b/platform/lifecycle_inputs_test.go index 05e66a5fa..3340e8629 100644 --- a/platform/lifecycle_inputs_test.go +++ b/platform/lifecycle_inputs_test.go @@ -97,7 +97,7 @@ func testLifecycleInputs(t *testing.T, when spec.G, it spec.S) { h.AssertNil(t, os.Setenv(platform.EnvUID, "1234")) h.AssertNil(t, os.Setenv(platform.EnvUseDaemon, "true")) h.AssertNil(t, os.Setenv(platform.EnvUseLayout, "true")) - h.AssertNil(t, os.Setenv(platform.EnvInsecureRegistry, "some-insecure-registry,another-insecure-registry, just-another-registry")) + h.AssertNil(t, os.Setenv(platform.EnvInsecureRegistries, "some-insecure-registry,another-insecure-registry, just-another-registry")) }) it.After(func() { @@ -132,7 +132,7 @@ func testLifecycleInputs(t *testing.T, when spec.G, it spec.S) { h.AssertNil(t, os.Unsetenv(platform.EnvUID)) h.AssertNil(t, os.Unsetenv(platform.EnvUseDaemon)) h.AssertNil(t, os.Unsetenv(platform.EnvUseLayout)) - h.AssertNil(t, os.Unsetenv(platform.EnvInsecureRegistry)) + h.AssertNil(t, os.Unsetenv(platform.EnvInsecureRegistries)) }) it("returns lifecycle inputs with env values fill in", func() {