diff --git a/packages/bundles/provider-c3os/build.yaml b/packages/bundles/provider-c3os/build.yaml new file mode 100644 index 0000000..ec884e6 --- /dev/null +++ b/packages/bundles/provider-c3os/build.yaml @@ -0,0 +1,26 @@ +{{ if eq .Values.init "systemd" }} +image: golang:1.18 +prelude: +- apt-get update +- apt-get install -y git curl systemd +{{ else }} +image: golang:1.18-alpine +prelude: +- apk add git curl openrc +{{ end }} +- git clone https://github.com/c3os-io/provider-c3os +- cd provider-c3os && git checkout {{.Values.tag}} +- curl -sfL https://get.k3s.io > installer.sh +steps: +- cd provider-c3os && go build -o agent-provider-c3os ./ +- mv provider-c3os/agent-provider-c3os /usr/local/bin +- bash installer.sh +- bash installer.sh agent +{{ if ne .Values.init "systemd" }} +- rm -rf /etc/rancher/k3s/k3s.env /etc/rancher/k3s/k3s-agent.env && touch /etc/rancher/k3s/.keep +{{end}} + +env: +- INSTALL_K3S_VERSION={{.Values.k3s_version}} +- INSTALL_K3S_SKIP_START="true" +- INSTALL_K3S_SKIP_ENABLE="true" \ No newline at end of file diff --git a/packages/bundles/provider-c3os/collection.yaml b/packages/bundles/provider-c3os/collection.yaml new file mode 100644 index 0000000..7564f92 --- /dev/null +++ b/packages/bundles/provider-c3os/collection.yaml @@ -0,0 +1,7 @@ +packages: +- name: "provider-c3os" + category: "bundles" + k3s_version: "v1.21.14+k3s1" + version: "0.0.1-alpha2+k3s1.21.14" + tag: "v0.0.1-alpha2" + init: systemd \ No newline at end of file