Skip to content

Commit

Permalink
Update disables list when building with no_stage
Browse files Browse the repository at this point in the history
The --disable/--no-deploy flags actually turn off some built-in
controllers, in addition to preventing manifests from getting loaded.
Make it clear which controllers can still be disabled even when the
packaged components are ommited by the no_stage build tag.

Signed-off-by: Brad Davidson <[email protected]>
  • Loading branch information
brandond committed Nov 4, 2020
1 parent ea91603 commit 3b8ec74
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 2 deletions.
9 changes: 9 additions & 0 deletions pkg/cli/cmds/nostage.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
// +build no_stage

package cmds

const (
// The coredns and servicelb controllers can still be disabled, even if their manifests
// are missing. Same with CloudController/ccm.
DisableItems = "coredns, servicelb"
)
2 changes: 0 additions & 2 deletions pkg/cli/cmds/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ import (
)

const (
DisableItems = "coredns, servicelb, traefik, local-storage, metrics-server"

defaultSnapshotRentention = 5
defaultSnapshotIntervalHours = 12
)
Expand Down
10 changes: 10 additions & 0 deletions pkg/cli/cmds/stage.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// +build !no_stage

package cmds

const (
// coredns and servicelb run controllers that are turned off when their manifests are disabled.
// The k3s CloudController also has a bundled manifest and can be disabled via the
// --disable-cloud-controller flag or --disable=ccm, but the latter method is not documented.
DisableItems = "coredns, servicelb, traefik, local-storage, metrics-server"
)

0 comments on commit 3b8ec74

Please sign in to comment.