fix(etcd): use transporter scheme in joinCluster

Follow the transporter scheme when trying to join the cluster. Otherwise
the scheme is empty and the http client errors.
release-0.4
Brandon Philips 2013-08-10 21:35:22 -07:00
parent 7db07aa96a
commit 3be13a38f1
1 changed files with 2 additions and 1 deletions

View File

@ -592,7 +592,8 @@ func joinCluster(s *raft.Server, serverName string) error {
debugf("Send Join Request to %s", serverName)
resp, err := t.Post(fmt.Sprintf("%s/join", serverName), &b)
joinURL := url.URL{Host: serverName, Scheme: raftTransporter.scheme, Path: "/join"}
resp, err := t.Post(joinURL.String(), &b)
for {
if err != nil {