diff --git a/README.md b/README.md index f4806ac7f..a610b583a 100644 --- a/README.md +++ b/README.md @@ -35,3 +35,33 @@ gpg --export-secret-keys --armor | kubectl create secret generic so ```bash sops --encrypt --pgp= --encrypted-regex '^(data|stringData)$' --in-place ``` + +## Labels nodes + +```bash + +kubectl taint node k3os-server k3s-controlplane=true:NoSchedule + +kubectl label node k3os-worker1 node-role.kubernetes.io/worker=true +kubectl label node k3os-worker2 node-role.kubernetes.io/worker=true +kubectl label node k3os-worker3 node-role.kubernetes.io/worker=true + +kubectl annotate node k3os-worker1 node.longhorn.io/default-node-tags='["storage","fast"]' +kubectl annotate node k3os-worker2 node.longhorn.io/default-node-tags='["storage","fast"]' +kubectl annotate node k3os-worker3 node.longhorn.io/default-node-tags='["storage","fast"]' + +kubectl annotate node k3os-worker1 node.longhorn.io/create-default-disk='config' +kubectl annotate node k3os-worker2 node.longhorn.io/create-default-disk='config' +kubectl annotate node k3os-worker3 node.longhorn.io/create-default-disk='config' + +kubectl annotate node k3os-worker1 node.longhorn.io/default-disks-config=[ { "name":"fast-ssd-disk", "path":"/var/lib/longhorn", "allowScheduling":true, "storageReserved":304857600, "tags":[ "ssd", "fast" ] }] +kubectl annotate node k3os-worker2 node.longhorn.io/default-disks-config=[ { "name":"fast-ssd-disk", "path":"/var/lib/longhorn", "allowScheduling":true, "storageReserved":304857600, "tags":[ "ssd", "fast" ] }] +kubectl annotate node k3os-worker3 node.longhorn.io/default-disks-config=[ { "name":"fast-ssd-disk", "path":"/var/lib/longhorn", "allowScheduling":true, "storageReserved":304857600, "tags":[ "ssd", "fast" ] }] + +#kubectl label node k3os-server plan.upgrade.cattle.io/k3os-latest=true +#kubectl label node k3os-worker1 plan.upgrade.cattle.io/k3os-latest=true +#kubectl label node k3os-worker2 plan.upgrade.cattle.io/k3os-latest=true +#kubectl label node k3os-worker3 plan.upgrade.cattle.io/k3os-latest=true +``` + +https://github.com/rancher/k3s/issues/1401 for k3os-system deployment \ No newline at end of file