feat(gcp): install k0s with k0sctl before Codesphere - #602
Open
NautiluX wants to merge 2 commits into
Open
Conversation
NautiluX
force-pushed
the
bootstrap-k0sctl
branch
4 times, most recently
from
July 23, 2026 13:50
7bc321e to
0c9cdf2
Compare
joka134
reviewed
Jul 23, 2026
| func (b *GCPBootstrapper) InstallK0s() error { | ||
| // Reuse matching cached binaries and let k0sctl reconcile normally. Without | ||
| // --force, an unchanged cluster remains untouched on bootstrap retries. | ||
| installCmd := fmt.Sprintf("oms install k0s --install-config /etc/codesphere/config.yaml --vault %s --vault-priv-key %s/age_key.txt", |
Member
There was a problem hiding this comment.
When rerunning this, it fails with:
Using latest k0s version: v1.36.2+k0s.0
Downloading k0s version v1.36.2+k0s.0
Error: failed to download k0s: k0s binary already exists at /root/.cache/oms/k0s. Use --force to overwrite
So we are not using the version we defined before and we should force it (or remove this behaviour in oms when the binary already exists)
joka134
reviewed
Jul 23, 2026
| host := createK0sctlHost(cp, "controller", nil, sshKeyPath, k0sBinaryPath) | ||
| var installFlags []string | ||
| if workerIPs[cp.IPAddress] { | ||
| installFlags = []string{"--enable-worker", "--no-taints=true"} |
Member
There was a problem hiding this comment.
I tried setting up a single node cluster on gcp with this branch and the cp was not showing up as worker node. Need some further investigation why.
NautiluX
force-pushed
the
bootstrap-k0sctl
branch
from
July 28, 2026 12:33
db032cf to
31eb111
Compare
NautiluX
force-pushed
the
bootstrap-k0sctl
branch
from
July 28, 2026 14:58
c736681 to
da6cd52
Compare
Signed-off-by: NautiluX <2600004+NautiluX@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Use k0sctl installation integrated in OMS to bootstrap on GCP