Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: make vmType optional #4214

Merged
merged 1 commit into from
Jul 4, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions pkg/provider/azure.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ type Config struct {
// the cloudprovider will try to add all nodes to a single backend pool which is forbidden.
// In other words, if you use multiple agent pools (availability sets), you MUST set this field.
PrimaryAvailabilitySetName string `json:"primaryAvailabilitySetName,omitempty" yaml:"primaryAvailabilitySetName,omitempty"`
// The type of azure nodes. Candidate values are: vmss and standard.
// If not set, it will be default to standard.
// The type of azure nodes. Candidate values are: vmss, standard and vmssflex.
// If not set, it will be default to vmss.
VMType string `json:"vmType,omitempty" yaml:"vmType,omitempty"`
// The name of the scale set that should be used as the load balancer backend.
// If this is set, the Azure cloudprovider will only add nodes from that scale set to the load
Expand Down Expand Up @@ -556,8 +556,8 @@ func (az *Cloud) InitializeCloudFromConfig(ctx context.Context, config *Config,
}

if config.VMType == "" {
// default to standard vmType if not set.
config.VMType = consts.VMTypeStandard
// default to vmss vmType if not set.
config.VMType = consts.VMTypeVMSS
}

if config.RouteUpdateWaitingInSeconds <= 0 {
Expand Down