*: support insecure registries
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
This commit is contained in:
parent
8441dca284
commit
8b53fabcbd
6 changed files with 129 additions and 38 deletions
|
@ -95,6 +95,10 @@ pause_command = "{{ .PauseCommand }}"
|
|||
# unspecified so that the default system-wide policy will be used.
|
||||
signature_policy = "{{ .SignaturePolicyPath }}"
|
||||
|
||||
# insecure_registries is used to skip TLS verification when pulling images.
|
||||
insecure_registries = [
|
||||
{{ range $opt := .InsecureRegistries }}{{ printf "\t%q,\n" $opt }}{{ end }}]
|
||||
|
||||
# The "crio.network" table contains settings pertaining to the
|
||||
# management of CNI plugins.
|
||||
[crio.network]
|
||||
|
|
|
@ -62,6 +62,9 @@ func mergeConfig(config *server.Config, ctx *cli.Context) error {
|
|||
if ctx.GlobalIsSet("storage-opt") {
|
||||
config.StorageOptions = ctx.GlobalStringSlice("storage-opt")
|
||||
}
|
||||
if ctx.GlobalIsSet("insecure-registry") {
|
||||
config.InsecureRegistries = ctx.GlobalStringSlice("insecure-registries")
|
||||
}
|
||||
if ctx.GlobalIsSet("default-transport") {
|
||||
config.DefaultTransport = ctx.GlobalString("default-transport")
|
||||
}
|
||||
|
@ -180,6 +183,10 @@ func main() {
|
|||
Name: "storage-opt",
|
||||
Usage: "storage driver option",
|
||||
},
|
||||
cli.StringSliceFlag{
|
||||
Name: "insecure-registry",
|
||||
Usage: "whether to disable TLS verification for the given registry",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "default-transport",
|
||||
Usage: "default transport",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue