mirror of
https://github.com/rancher/types.git
synced 2025-06-25 05:01:33 +00:00
Make role an enum
This commit is contained in:
parent
4087cd55d5
commit
2a197d2490
@ -108,7 +108,7 @@ type MachineSpec struct {
|
||||
DisplayName string `json:"displayName,omitempty"`
|
||||
RequestedHostname string `json:"requestedHostname,omitempty" norman:"noupdate"`
|
||||
ClusterName string `json:"clusterName,omitempty" norman:"type=reference[cluster],noupdate,required"`
|
||||
Role []string `json:"role,omitempty" norman:"noupdate"`
|
||||
Role []string `json:"role,omitempty" norman:"noupdate,type=array[enum],options=etcd|worker|controlplane"`
|
||||
MachineTemplateName string `json:"machineTemplateName,omitempty" norman:"type=reference[machineTemplate],noupdate"`
|
||||
}
|
||||
|
||||
|
@ -29,7 +29,7 @@ type RKEConfigNode struct {
|
||||
// Optional - Internal address that will be used for components communication
|
||||
InternalAddress string `yaml:"internal_address" json:"internalAddress,omitempty"`
|
||||
// Node role in kubernetes cluster (controlplane, worker, or etcd)
|
||||
Role []string `yaml:"role" json:"role,omitempty"`
|
||||
Role []string `yaml:"role" json:"role,omitempty" norman:"type=array[enum],options=etcd|worker|controlplane"`
|
||||
// Optional - Hostname of the node
|
||||
HostnameOverride string `yaml:"hostname_override" json:"hostnameOverride,omitempty"`
|
||||
// SSH usesr that will be used by RKE
|
||||
|
Loading…
Reference in New Issue
Block a user