Home Assistant: Enable insecure option for self-signed certificates in oauth2 flow (#30648)

Co-authored-by: andig <cpuidle@gmail.com>
Co-authored-by: Michael Geers <michael@geers.tv>
This commit is contained in:
Markus 2026-06-18 16:37:04 +02:00 • committed by GitHub
parent d7a294f06e
commit e5b9a014c5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
29 changed files with 336 additions and 115 deletions

View file

@ -18,15 +18,13 @@ func init() {
// NewHomeAssistantFromConfig creates a HomeAssistant meter from generic config
func NewHomeAssistantFromConfig(other map[string]any) (api.Meter, error) {
cc := struct {
URI string
Token_ string `mapstructure:"token"` // TODO deprecated
Home_ string `mapstructure:"home"` // TODO deprecated
Power string
Energy string
Currents []string
Voltages []string
Powers []string
Soc string
homeassistant.Config `mapstructure:",squash"`
Power string
Energy string
Currents []string
Voltages []string
Powers []string
Soc string
// pv
pvMaxACPower `mapstructure:",squash"`
@ -57,7 +55,7 @@ func NewHomeAssistantFromConfig(other map[string]any) (api.Meter, error) {
log := util.NewLogger("ha-meter")
conn, err := homeassistant.NewConnection(log, cc.URI, cc.Home_)
conn, err := cc.Config.NewConnection(log)
if err != nil {
return nil, err
}