diff options
author | Taylor Gerring <taylor.gerring@gmail.com> | 2015-01-21 03:40:24 +0800 |
---|---|---|
committer | Taylor Gerring <taylor.gerring@gmail.com> | 2015-01-21 03:40:24 +0800 |
commit | 0c77a962499479cffe7cc5b8e3903197919ca682 (patch) | |
tree | 24aaa1084d916f1754e497d60dd4c00267503b56 /cmd/utils/cmd.go | |
parent | d92fde698031758f64fcabe7af354360a93f6326 (diff) | |
download | dexon-0c77a962499479cffe7cc5b8e3903197919ca682.tar.gz dexon-0c77a962499479cffe7cc5b8e3903197919ca682.tar.zst dexon-0c77a962499479cffe7cc5b8e3903197919ca682.zip |
Move websockets out of cmd/util
Diffstat (limited to 'cmd/utils/cmd.go')
-rw-r--r-- | cmd/utils/cmd.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/cmd/utils/cmd.go b/cmd/utils/cmd.go index a57d3266f..95a7f89c8 100644 --- a/cmd/utils/cmd.go +++ b/cmd/utils/cmd.go @@ -40,6 +40,7 @@ import ( "github.com/ethereum/go-ethereum/rlp" "github.com/ethereum/go-ethereum/rpc" "github.com/ethereum/go-ethereum/state" + "github.com/ethereum/go-ethereum/websocket" "github.com/ethereum/go-ethereum/xeth" ) @@ -200,6 +201,13 @@ func StartRpc(ethereum *eth.Ethereum, RpcPort int) { } } +func StartWebSockets(eth *eth.Ethereum) { + clilogger.Infoln("Starting WebSockets") + + sock := websocket.NewWebSocketServer(eth) + go sock.Serv() +} + var gminer *miner.Miner func GetMiner() *miner.Miner { |