Skip to content

Commit

Permalink
Merge pull request #274 from mikebrow/insecure-tls-support
Browse files Browse the repository at this point in the history
until there is an auth plan tls testing should support insecure
  • Loading branch information
Random-Liu authored Mar 21, 2018
2 parents 976680c + 6ba8505 commit 207e773
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion cmd/crictl/attach.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ func Attach(client pb.RuntimeServiceClient, opts attachOptions) error {
return err
}
logrus.Debugf("Attach URL: %v", URL)
attach, err := remoteclient.NewSPDYExecutor(&restclient.Config{}, "POST", URL)
attach, err := remoteclient.NewSPDYExecutor(&restclient.Config{TLSClientConfig: restclient.TLSClientConfig{Insecure: true}}, "POST", URL)
if err != nil {
return err
}
Expand Down
2 changes: 1 addition & 1 deletion cmd/crictl/exec.go
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ func Exec(client pb.RuntimeServiceClient, opts execOptions) error {
}

logrus.Debugf("Exec URL: %v", URL)
exec, err := remoteclient.NewSPDYExecutor(&restclient.Config{}, "POST", URL)
exec, err := remoteclient.NewSPDYExecutor(&restclient.Config{TLSClientConfig: restclient.TLSClientConfig{Insecure: true}}, "POST", URL)
if err != nil {
return err
}
Expand Down
6 changes: 3 additions & 3 deletions pkg/validate/streaming.go
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ func checkExec(c internalapi.RuntimeService, execServerURL string) {
// Only http is supported now.
// TODO: support streaming APIs via tls.
url := parseURL(c, execServerURL)
e, err := remoteclient.NewSPDYExecutor(&rest.Config{}, "POST", url)
e, err := remoteclient.NewSPDYExecutor(&rest.Config{TLSClientConfig: rest.TLSClientConfig{Insecure: true}}, "POST", url)
framework.ExpectNoError(err, "failed to create executor for %q", execServerURL)

err = e.Stream(remoteclient.StreamOptions{
Expand Down Expand Up @@ -232,7 +232,7 @@ func checkAttach(c internalapi.RuntimeService, attachServerURL string) {
// Only http is supported now.
// TODO: support streaming APIs via tls.
url := parseURL(c, attachServerURL)
e, err := remoteclient.NewSPDYExecutor(&rest.Config{}, "POST", url)
e, err := remoteclient.NewSPDYExecutor(&rest.Config{TLSClientConfig: rest.TLSClientConfig{Insecure: true}}, "POST", url)
framework.ExpectNoError(err, "failed to create executor for %q", attachServerURL)

err = e.Stream(remoteclient.StreamOptions{
Expand Down Expand Up @@ -264,7 +264,7 @@ func checkPortForward(c internalapi.RuntimeService, portForwardSeverURL string)
readyChan := make(chan struct{})
defer close(stopChan)

transport, upgrader, err := spdy.RoundTripperFor(&rest.Config{})
transport, upgrader, err := spdy.RoundTripperFor(&rest.Config{TLSClientConfig: rest.TLSClientConfig{Insecure: true}})
framework.ExpectNoError(err, "failed to create spdy round tripper")
url := parseURL(c, portForwardSeverURL)
dialer := spdy.NewDialer(upgrader, &http.Client{Transport: transport}, "POST", url)
Expand Down

0 comments on commit 207e773

Please # to comment.