Commit 6b38748
* feat: Add LoadBalancer support with Cloud Provider KIND
- Add LoadBalancer enum (Default/Enabled/Disabled) to ClusterSpec
- Add ProvidesLoadBalancerByDefault() distribution method
- Add CLI field selector for --load-balancer flag
- Wire LoadBalancer flag into init and create commands
- Add K3d scaffolding for --disable=servicelb flag
- Create Cloud Provider KIND installer for Vanilla × Docker
- Add LoadBalancer component installation logic
- Update ComponentRequirements with NeedsLoadBalancer field
Distribution × Provider Support Matrix:
- Vanilla (Kind) × Docker: Cloud Provider KIND (when Enabled)
- K3s × Docker: ServiceLB (Klipper) by default
- Talos × Docker: Future MetalLB support
- Talos × Hetzner: Future hcloud-ccm support
Related to #1714
* chore: update generated JSON schema
* chore: update generated CLI flags docs
* Add cloud-provider-kind cleanup and fix linting issues (#2005)
* Initial plan
* fix: resolve all golangci-lint issues
- Add ErrLoadBalancerNotImplemented static error
- Fix golines formatting in options.go (struct tag alignment)
- Fix golines formatting in components.go (line length)
- Fix golines formatting in installer.go (function signature)
- Fix lll issue in enums.go (comment line length)
Co-authored-by: devantler <[email protected]>
* feat: add cloud-provider-kind cleanup on last cluster deletion
- Add Uninstall method to CloudProviderKINDInstaller
- Add cleanup logic to detect when last kind cluster is deleted
- Clean up cloud-provider-kind load balancer containers
- Prevents orphaned containers when all kind clusters are removed
Co-authored-by: devantler <[email protected]>
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: devantler <[email protected]>
* chore: apply golangci-lint fixes
* test: add LoadBalancer system test matrix coverage (#2009)
* Fix missing LoadBalancer field mapping causing --unknown flag name (#2008)
* Fix cloud-provider-kind cleanup scope and code duplication (#2011)
* [WIP] Add load balancer support to cluster commands (#2012)
* chore: apply golangci-lint fixes
* Add test coverage and refine cloud-provider-kind cleanup logic (#2018)
* Initial plan
* Add review feedback improvements: tests, docs, and refactoring
- Add comment to detectIsKindCluster() explaining timing requirements
- Add comprehensive LoadBalancer enum tests (Set, String, Type, Default, ValidValues)
- Add ProvidesLoadBalancerByDefault() tests for all distribution × provider combinations
- Create cloudproviderkind installer unit tests following established patterns
- Update hasRemainingKindClusters() to accept *cobra.Command and use cmd.Context()
- Add hasCloudProviderKindContainers() to check existence before cleanup messages
- Update container prefix from "lb-" to "cpk-" for cloud-provider-kind
- Clarify Talos × Hetzner LoadBalancer logic (default support via hcloud-ccm)
Co-authored-by: devantler <[email protected]>
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: devantler <[email protected]>
* fix: resolve golangci-lint issues (funlen, varnamelen, golines) (#2019)
* chore: apply golangci-lint fixes
* test: fix delete command snapshot expectations (#2024)
* Initial plan
* test: fix delete command snapshot tests
Update snapshot expectations to reflect current behavior where cloud-provider-kind cleanup messages are not shown during tests (Docker operations are mocked/skipped in test environment).
The cleanup logic is still correct in production - it only shows cleanup messages when:
1. No Kind clusters remain (hasRemainingKindClusters returns false)
2. Cloud-provider-kind containers exist (hasCloudProviderKindContainers returns true)
In tests, the Docker client is mocked and returns no containers, so cleanup messages are correctly omitted.
Co-authored-by: devantler <[email protected]>
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: devantler <[email protected]>
* Update pkg/cli/cmd/cluster/delete.go
Co-authored-by: Copilot <[email protected]>
Signed-off-by: Nikolai Emil Damm <[email protected]>
* Update pkg/apis/cluster/v1alpha1/enums_test.go
Co-authored-by: Copilot <[email protected]>
Signed-off-by: Nikolai Emil Damm <[email protected]>
* fix: replace Helm-based cloud-provider-kind installer with Docker container approach (#2026)
* Initial plan
* fix: use Docker container for cloud-provider-kind instead of Helm
Cloud-provider-kind is not distributed as a Helm chart. The correct
approach is to run it as a Docker container with access to the Docker
socket, connected to the KIND network. This commit:
- Rewrites the cloud-provider-kind installer to use Docker API instead
of Helm
- Creates and manages the cloud-provider-kind container with proper
configuration (Docker socket mount, KIND network connection)
- Updates tests to use Docker client mocks instead of Helm mocks
- Uses the official image: registry.k8s.io/cloud-provider-kind/cloud-controller-manager:latest
Fixes the 404 error when trying to fetch non-existent Helm chart from
https://kubernetes-sigs.github.io/cloud-provider-kind/index.yaml
Co-authored-by: devantler <[email protected]>
* Co-authored-by: devantler <[email protected]>
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: devantler <[email protected]>
* chore: tidy go modules
* fix: resolve golangci-lint issues in LoadBalancer implementation (#2028)
* Initial plan
* fix: resolve all golangci-lint issues in LoadBalancer implementation
Co-authored-by: devantler <[email protected]>
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: devantler <[email protected]>
* chore: apply golangci-lint fixes
* Fix LoadBalancer installation to skip unsupported distribution × provider combinations (#2030)
* Fix golangci-lint violations (godox, golines) (#2032)
* chore: apply golangci-lint fixes
* chore: Apply megalinter fixes
---------
Signed-off-by: Nikolai Emil Damm <[email protected]>
Co-authored-by: GitHub Copilot <github-actions[bot]@users.noreply.github.com>
Co-authored-by: botantler[bot] <185060876+botantler[bot]@users.noreply.github.com>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: devantler <[email protected]>
Co-authored-by: Nikolai Emil Damm <[email protected]>
Co-authored-by: Copilot <[email protected]>
1 parent 58d6817 commit 6b38748
File tree
35 files changed
+1360
-392
lines changed- .github/workflows
- docs/src/content/docs/cli-flags/cluster
- pkg
- apis/cluster/v1alpha1
- cli
- cmd/cluster
- setup
- io
- config-manager/ksail
- scaffolder
- svc/installer/cloudproviderkind
- schemas
35 files changed
+1360
-392
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
3 | | - | |
4 | | - | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | | - | |
| 36 | + | |
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments