openpdu/src/main.go

34 lines
498 B
Go

package main
import (
"github.com/spf13/viper"
)
// Dictionary aaa
type Dictionary map[string]interface{}
func init() {
viper.SetDefault("hostname", "openpdu")
}
func main() {
parseBoardsConfig()
go mqttLoop()
go UpsConnect()
logInfo("hostname: " + viper.GetString("hostname"))
startServer()
}
// https://github.com/ColorlibHQ/AdminLTE/archive/v2.4.17.tar.gz
/* TODO
- config reset gpio
- classi per board
- classi per outlet
- fai funzionare toggle
- scan i2c
- impostazioni log
*/