implement basic status checking
diff --git a/main.go b/main.go
index c538eaa..87675bc 100644
--- a/main.go
+++ b/main.go
@@ -46,6 +46,12 @@
config := confpb.Config{}
proto.UnmarshalText(string(data), &config)
+ stm := state.NewManager()
+ err = stm.FetchState(ctx, &config)
+ if err != nil {
+ glog.Exitf("Initial state fetch failed: %v", err)
+ }
+
gr := graph.New()
err = gr.LoadConfig(&config)
if err != nil {
@@ -59,8 +65,6 @@
glog.Exitf("Initial netbox feed failed: %v", err)
}
- stm := state.NewManager()
-
sconf := ServiceConfig{
DebugListen: flagDebugListen,
}