Skip to content

Commit

Permalink
fix: change prioritization of the insecure flag check to ensure it wo…
Browse files Browse the repository at this point in the history
…rks with mixed secure/insecure registries
  • Loading branch information
orpiske authored and astefanutti committed Mar 17, 2021
1 parent 6f76ebd commit ba57db3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/trait/builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,9 @@ func (t *builderTrait) buildahTask(e *Environment) (*v1.ImageTask, error) {
})
}
mountRegistrySecret(e.Platform.Status.Build.Registry.Secret, secret, &volumes, &volumeMounts, &env)
} else if e.Platform.Status.Build.Registry.Insecure {
}

if e.Platform.Status.Build.Registry.Insecure {
bud = append(bud[:2], append([]string{"--tls-verify=false"}, bud[2:]...)...)
push = append(push[:2], append([]string{"--tls-verify=false"}, push[2:]...)...)
}
Expand Down

0 comments on commit ba57db3

Please sign in to comment.