cammount: setup transport (trusted certs support)

Change-Id: I2970986637094d5bf581545bbedab601c62c1641
This commit is contained in:
mpl 2013-06-26 15:19:14 +02:00
parent 90ecd785ba
commit bb7487ea0b
1 changed files with 3 additions and 0 deletions

View File

@ -20,6 +20,7 @@ import (
"flag"
"fmt"
"log"
"net/http"
"os"
"os/signal"
"strings"
@ -81,9 +82,11 @@ func main() {
if root == nil {
log.Fatalf("Error parsing root blobref: %q\n", rootArg)
}
cl.SetHTTPClient(&http.Client{Transport: cl.TransportForConfig(nil)})
}
} else {
cl = client.NewOrFail() // automatic from flags
cl.SetHTTPClient(&http.Client{Transport: cl.TransportForConfig(nil)})
}
// TODO(mpl): probably needs the transport setup for trusted certs here.