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

Add k0s Packages #1225

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Add k0s Packages #1225

wants to merge 3 commits into from

Conversation

wrkode
Copy link

@wrkode wrkode commented Jan 16, 2025

This PR adds the creation of k0s packages for openrc and systemd.
It is explicitly targeting Kubernetes versions 1.31.3, 1.30.7 and 1.29.11.

Thanks for reviewing

fixes kairos-io/kairos#3124

@mauromorales mauromorales requested a review from a team January 16, 2025 07:58
- touch /bin/systemctl && chmod +x /bin/systemctl
- mkdir -p /etc/systemd/system/
{{ end }}
- bash installer.sh
Copy link
Member

Choose a reason for hiding this comment

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

I think the installer still needs to be downloaded somewhere before this line

Copy link
Member

Choose a reason for hiding this comment

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

Here's how we download the k3s installer for example

- curl -sfL https://get.k3s.io > installer.sh

category: "development"
version: ">=0"
env:
- K0S_VERSION=v{{ regexReplaceAll "\\+\\d+$" .Values.version "" }}+k0s.{{.Values.k0s_version}}
Copy link
Member

Choose a reason for hiding this comment

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

This is used in k3s becuase the installer script takes that env var to decide which version of k3s to install, I wasn't able to find a K0S_VERSION in the k0s docs

labels:
github.owner: "k0sproject"
github.repo: "k0s"
autobump.sed_script: 's/\+k0s.[0-9]//g'
Copy link
Member

Choose a reason for hiding this comment

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

This is similar to what we have in k3s, so I'm sure it will work, just keep in mind that by doing this we ignore patched versions e.g. v1.31.3+k0s.1 will not be considered because version v1.31.3+k0s.0 is already installed.

this is an internal problem that we need to solve. I thought I had a ticket for it but I cannot find it, will relate to this one instead in the meantime kairos-io/kairos#1934

No need to worry on your side about this atm, just a not to self kind of thing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Under review 🔍
Development

Successfully merging this pull request may close these issues.

feat: Add a k0s package
2 participants