Skip to content

Commit 5191b0e

Browse files
committed
yaml linting
Signed-off-by: Andrei Gaivoronskii <[email protected]> Signed-off-by: plandem <[email protected]>
1 parent 82eff43 commit 5191b0e

File tree

1 file changed

+31
-32
lines changed

1 file changed

+31
-32
lines changed

templates/k0s.yaml

Lines changed: 31 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212

1313
minimumLimaVersion: 1.1.0
1414

15-
base:
16-
- template://_images/ubuntu-lts
15+
base: template://_images/ubuntu-lts
1716

1817
# Mounts are disabled in this template, but can be enabled optionally.
1918
mounts: []
@@ -24,44 +23,44 @@ containerd:
2423
user: false
2524

2625
provision:
27-
- mode: system
28-
script: |
29-
#!/bin/bash
30-
set -eux -o pipefail
31-
command -v k0s >/dev/null 2>&1 && exit 0
26+
- mode: system
27+
script: |
28+
#!/bin/bash
29+
set -eux -o pipefail
30+
command -v k0s >/dev/null 2>&1 && exit 0
3231
33-
# install k0s prerequisites
34-
curl -sfL https://get.k0s.sh | sh
32+
# install k0s prerequisites
33+
curl -sfL https://get.k0s.sh | sh
3534
36-
- mode: system
37-
script: |
38-
#!/bin/bash
39-
set -eux -o pipefail
35+
- mode: system
36+
script: |
37+
#!/bin/bash
38+
set -eux -o pipefail
4039
41-
# start k0s as a single node cluster
42-
if ! systemctl status k0scontroller >/dev/null 2>&1; then
43-
k0s install controller --single
44-
fi
40+
# start k0s as a single node cluster
41+
if ! systemctl status k0scontroller >/dev/null 2>&1; then
42+
k0s install controller --single
43+
fi
4544
46-
systemctl start k0scontroller
45+
systemctl start k0scontroller
4746
4847
probes:
49-
- description: "k0s to be running"
50-
script: |
51-
#!/bin/bash
52-
set -eux -o pipefail
53-
if ! timeout 30s bash -c "until sudo test -f /var/lib/k0s/pki/admin.conf; do sleep 3; done"; then
54-
echo >&2 "k0s kubeconfig file has not yet been created"
55-
exit 1
56-
fi
57-
hint: |
58-
The k0s control plane is not ready yet.
59-
Run "limactl shell k0s sudo journalctl -u k0scontroller" to debug.
48+
- description: "k0s to be running"
49+
script: |
50+
#!/bin/bash
51+
set -eux -o pipefail
52+
if ! timeout 30s bash -c "until sudo test -f /var/lib/k0s/pki/admin.conf; do sleep 3; done"; then
53+
echo >&2 "k0s kubeconfig file has not yet been created"
54+
exit 1
55+
fi
56+
hint: |
57+
The k0s control plane is not ready yet.
58+
Run "limactl shell k0s sudo journalctl -u k0scontroller" to debug.
6059
6160
copyToHost:
62-
- guest: "/var/lib/k0s/pki/admin.conf"
63-
host: "{{.Dir}}/copied-from-guest/kubeconfig.yaml"
64-
deleteOnStop: true
61+
- guest: "/var/lib/k0s/pki/admin.conf"
62+
host: "{{.Dir}}/copied-from-guest/kubeconfig.yaml"
63+
deleteOnStop: true
6564
message: |
6665
To run `kubectl` on the host (assumes kubectl is installed), run the following commands:
6766
------

0 commit comments

Comments
 (0)