Skip to content

Commit

Permalink
pkg/transport: remove dependency on pkg/fileutils
Browse files Browse the repository at this point in the history
4a0f922 changed SelfCert to use a helper from pkg/fileutils which
introduced a transitive dependency on coreos/pkg/capnslog. This means
anyone who imports pkg/transport to use TLS with the clientv3 library
has the default stdlib logger hijacked by capnslog.

This PR reverts 4a0f922. There are no tests because 4a0f922 contained no
test and was not attached to a PR.

Fixes #7350
  • Loading branch information
dcheney-atlassian committed Feb 20, 2017
1 parent 2533c2a commit 9b84127
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pkg/transport/listener.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ import (
"strings"
"time"

"github.com/coreos/etcd/pkg/fileutil"
"github.com/coreos/etcd/pkg/tlsutil"
)

Expand Down Expand Up @@ -86,7 +85,7 @@ func (info TLSInfo) Empty() bool {
}

func SelfCert(dirpath string, hosts []string) (info TLSInfo, err error) {
if err = fileutil.TouchDirAll(dirpath); err != nil {
if err = os.MkdirAll(dirpath, 0700); err != nil {
return
}

Expand Down

0 comments on commit 9b84127

Please sign in to comment.