[Help wanted] Don't verify cert
smutel opened this issue · comments
Samuel Mutel commented
Hello,
I am using this piece of code:
defaultScheme := []string{scheme}
t := runtimeclient.New(url, client.DefaultBasePath, defaultScheme)
t.DefaultAuthentication = runtimeclient.APIKeyAuth(authHeaderName, "header",
fmt.Sprintf(authHeaderFormat, token))
return client.New(t, strfmt.Default), nil
I would like to add an option to not verify SSL cert. What is the easiest way to accomplish this ?
Thanks.
Ivan Porto Carrero commented
construct your client with this: https://github.com/go-openapi/runtime/blob/master/client/runtime.go#L86
Samuel Mutel commented
I am not an expert in Go. Could you please tell me how to put the struct TLSClientOptions
in my code ?