diff --git a/packages/k3s/build.yaml b/packages/k3s/build.yaml new file mode 100644 index 0000000..158845f --- /dev/null +++ b/packages/k3s/build.yaml @@ -0,0 +1,24 @@ +requires: +- name: "toolchain-go" + category: "development" + version: ">=0" +prelude: +{{$arch:=(default .Values.arch "amd64")}} + +{{ if eq $arch "amd64" }} +- wget https://github.com/k3s-io/k3s/releases/download/v{{.Values.version}}+k3s{{.Values.k3s_version}}/k3s +{{ else }} +{{ if eq $arch "arm" }} +{{$arch:="arm64"}} +{{end}} +- wget https://github.com/k3s-io/k3s/releases/download/v{{.Values.version}}+k3s{{.Values.k3s_version}}/k3s-{{$arch}} +{{ end }} +- /bin/bash -c 'echo "{{ ( index .Values (print "checksum-" $arch) ) }} k3s" | sha256sum -c' +steps: +- | + mv {{.Values.name}} /usr/local/bin/ +- chmod +x /usr/local/bin/{{.Values.name}} +includes: +- /usr/local/bin/{{.Values.name}} + +# TODO: service files for openrc/systemd diff --git a/packages/k3s/collection.yaml b/packages/k3s/collection.yaml new file mode 100644 index 0000000..a281967 --- /dev/null +++ b/packages/k3s/collection.yaml @@ -0,0 +1,13 @@ +packages: +- name: k3s + category: bundle + checksum-amd64: "c3c816290461dc0e8e632e70ceb0f771382629860a851ae88545c816beb9797c" + version: "1.24.2" + k3s_version: "2" + labels: + github.repo: "k3s-io" + github.owner: "k3s" + uri: + - https://github.com/k3s-io/k3s + license: "APL-2" + description: " Lightweight Kubernetes " \ No newline at end of file