From 9e69aba7aa8300d5338b1cdae2b57c4af1dc4517 Mon Sep 17 00:00:00 2001 From: Yicheng Qin Date: Wed, 4 Mar 2015 16:21:20 -0800 Subject: [PATCH] tools/etcd-agent: add main func --- tools/functional-tester/etcd-agent/main.go | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/tools/functional-tester/etcd-agent/main.go b/tools/functional-tester/etcd-agent/main.go index f5f7042ab..481f84bf6 100644 --- a/tools/functional-tester/etcd-agent/main.go +++ b/tools/functional-tester/etcd-agent/main.go @@ -14,6 +14,21 @@ package main +import ( + "flag" + "log" +) + func main() { - panic("not implemented") + etcdPath := flag.String("etcd-path", "/opt/etcd/bin/etcd", "") + flag.Parse() + + a, err := newAgent(*etcdPath) + if err != nil { + log.Fatal(err) + } + a.serveRPC() + + var done chan struct{} + <-done }