dhcp ipam: rename inconsistent options among files

Signed-off-by: SilverBut <SilverBut@users.noreply.github.com>
This commit is contained in:
SilverBut
2021-10-02 23:49:59 +08:00
parent c627ea807c
commit a1051f3bf1
3 changed files with 8 additions and 8 deletions

View File

@ -48,9 +48,9 @@ type IPAMConfig struct {
ProvideOptions []ProvideOption `json:"provide"`
// When requesting IP from DHCP server, claiming these options are necessary. Options are necessary unless `optional`
// is set to `false`.
// To override default required fields, set `skipDefault` to `false`.
// To override default requesting fields, set `skipDefault` to `false`.
// If an field is not optional, but the server failed to provide it, error will be raised.
RequireOptions []RequireOption `json:"require"`
RequestOptions []RequestOption `json:"request"`
}
// DHCPOption represents a DHCP option. It can be a number, or a string defined in manual dhcp-options(5).
@ -64,7 +64,7 @@ type ProvideOption struct {
ValueFromCNIArg string `json:"fromArg"`
}
type RequireOption struct {
type RequestOption struct {
SkipDefault bool `json:"skipDefault"`
Option DHCPOption `json:"option"`