aboutsummaryrefslogtreecommitdiffstats
path: root/ethereum.go
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-05-13 18:42:35 +0800
committerobscuren <geffobscura@gmail.com>2014-05-13 18:42:35 +0800
commit8ec1bb382aade4aaba20b7fd051a7e52cee61d6e (patch)
tree41c55187c1ac40a7bb2d06cb4028be128164a299 /ethereum.go
parentcac9562c059a94902dc420fea697026a682014bc (diff)
parentd31303a592bcf8662fbbe66e542535e0e82c5a83 (diff)
downloadgo-tangerine-8ec1bb382aade4aaba20b7fd051a7e52cee61d6e.tar.gz
go-tangerine-8ec1bb382aade4aaba20b7fd051a7e52cee61d6e.tar.zst
go-tangerine-8ec1bb382aade4aaba20b7fd051a7e52cee61d6e.zip
Merge branch 'develop' of github.com-obscure:ethereum/eth-go into develop
Diffstat (limited to 'ethereum.go')
-rw-r--r--ethereum.go21
1 files changed, 17 insertions, 4 deletions
diff --git a/ethereum.go b/ethereum.go
index bd391ba37..92c4e4ba1 100644
--- a/ethereum.go
+++ b/ethereum.go
@@ -325,8 +325,21 @@ func (s *Ethereum) Start(seed bool) {
}
func (s *Ethereum) Seed() {
- ethutil.Config.Log.Debugln("Seeding")
- // DNS Bootstrapping
+ ethutil.Config.Log.Debugln("[SERV] Retrieving seed nodes")
+
+ // Eth-Go Bootstrapping
+ ips, er := net.LookupIP("seed.bysh.me")
+ if er == nil {
+ peers := []string{}
+ for _, ip := range ips {
+ node := fmt.Sprintf("%s:%d", ip.String(), 30303)
+ ethutil.Config.Log.Debugln("[SERV] Found DNS Go Peer:", node)
+ peers = append(peers, node)
+ }
+ s.ProcessPeerList(peers)
+ }
+
+ // Official DNS Bootstrapping
_, nodes, err := net.LookupSRV("eth", "tcp", "ethereum.org")
if err == nil {
peers := []string{}
@@ -340,11 +353,11 @@ func (s *Ethereum) Seed() {
for _, a := range addr {
// Build string out of SRV port and Resolved IP
peer := net.JoinHostPort(a, port)
- log.Println("Found DNS Bootstrap Peer:", peer)
+ ethutil.Config.Log.Debugln("[SERV] Found DNS Bootstrap Peer:", peer)
peers = append(peers, peer)
}
} else {
- log.Println("Couldn't resolve :", target)
+ ethutil.Config.Log.Debugln("[SERV} Couldn't resolve :", target)
}
}
// Connect to Peer list