timer: changes config var from box to web

This commit is contained in:
Marvin Preuss 2021-08-11 13:46:22 +02:00
parent bc84a6fb50
commit 7751dfea95

View File

@ -58,11 +58,10 @@ func (t *Timer) Handle() {
// Run is the command line interface for triggering the timer. // Run is the command line interface for triggering the timer.
func Run(cmd *cobra.Command, args []string) { func Run(cmd *cobra.Command, args []string) {
conn, err := grpcclient.Conn(config.Cfg.Web.Hostname, config.Web.Box.Port) conn, err := grpcclient.Conn(config.Cfg.Web.Hostname, config.Cfg.Web.Port)
if err != nil { if err != nil {
log.Fatal().Err(err).Msg("could not connect") log.Fatal().Err(err).Msg("could not connect")
} }
defer conn.Close()
c := api.NewTimerServiceClient(conn) c := api.NewTimerServiceClient(conn)