go-openapi / runtime

openapi runtime interfaces

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Help wanted] Don't verify cert

smutel opened this issue · comments

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.

I am not an expert in Go. Could you please tell me how to put the struct TLSClientOptions in my code ?