Skip to content

Do not merge: HA default true for cluster create#1812

Draft
pyadagiri-do wants to merge 6 commits intodigitalocean:mainfrom
pyadagiri-do:pyadagiri/ha
Draft

Do not merge: HA default true for cluster create#1812
pyadagiri-do wants to merge 6 commits intodigitalocean:mainfrom
pyadagiri-do:pyadagiri/ha

Conversation

@pyadagiri-do
Copy link

@pyadagiri-do pyadagiri-do commented Mar 12, 2026

Updates the --ha flag default to true for doctl kubernetes cluster create when creating clusters

This behaviour in DOKS API will be there from version 1.36.0 and later. Hence also merge this during 1.36 doks release

Do not merge

Validations done:
built and validated cluster creation using local ./doctl with and without explicit ha flag.
updated UTs and validated.
go test ./commands/... -run "Kubernetes" -v -count=1
go test ./integration/... -run "TestRun/doctl/kubernetes" -v -count=1

@pyadagiri-do pyadagiri-do changed the title HA default true for cluster create (1.36.0 and later) HA default true for cluster create Mar 12, 2026
- Integration: test HA defaults to true when --ha is omitted
- Integration: test HA disabled when --ha=false
- Commands: add unit test for HA default in cluster create request
@pyadagiri-do pyadagiri-do changed the title HA default true for cluster create Do not merge: HA default true for cluster create Mar 13, 2026
expect.Equal(strings.TrimSpace(fmt.Sprintf(kubeClustersCreateOutput, f.Name())), strings.TrimSpace(string(output)))
})

it("creates a kube cluster with HA defaulting to true when --ha is omitted", func() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do these integration tests actually create clusters? If so, then let's remove the extra integration tests before merging this PR - we can't afford to e2e or integration test for every combination of cluster fields.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants