Skip to content

Commit

Permalink
Closes #142, broaded validator restriction for dns entry
Browse files Browse the repository at this point in the history
  • Loading branch information
NHAS committed Nov 15, 2024
1 parent ac198fb commit f68c713
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions internal/data/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -350,9 +350,10 @@ func (lg *LoginSettings) ToWriteOps() (ret []clientv3.Op, err error) {
}

type GeneralSettings struct {
HelpMail string `validate:"required,email"`
ExternalAddress string `validate:"required,hostname|hostname_port|ip"`
DNS []string `validate:"omitempty,dive,hostname|ip"`
HelpMail string `validate:"required,email"`
ExternalAddress string `validate:"required,hostname|hostname_port|ip"`
// Allow hostname or ip/4/6 as dns entry for wireguard config
DNS []string `validate:"omitempty,dive,hostname|ip"`

WireguardConfigFilename string `validate:"required"`
CheckUpdates bool
Expand Down

0 comments on commit f68c713

Please sign in to comment.