Make NAT Action Service and Address Optional

This commit is contained in:
Samuel Lorch 2023-05-13 22:13:09 +02:00
parent a3ab1c7227
commit 6aa5ed2948
2 changed files with 4 additions and 4 deletions

View file

@ -2,6 +2,6 @@ package firewall
type DestinationNATRule struct {
Rule
Address string `json:"address,omitempty"`
Service string `json:"service,omitempty"`
Address *string `json:"address,omitempty"`
Service *string `json:"service,omitempty"`
}

View file

@ -5,8 +5,8 @@ import "encoding/json"
type SourceNATRule struct {
Rule
Type SnatType `json:"type" validate:"min=0,max=1"`
Address string `json:"address,omitempty"`
Service string `json:"service,omitempty"`
Address *string `json:"address,omitempty"`
Service *string `json:"service,omitempty"`
}
type SnatType int