Skip to content

Commit 0eae5c6

Browse files
authored
Merge pull request #1862 from ader1990/fix_cloudinit_docs
Fix cloud-init jinja templates 📖
2 parents 66c8134 + 08a3b66 commit 0eae5c6

File tree

2 files changed

+18
-18
lines changed

2 files changed

+18
-18
lines changed

docs/book/src/user/quick-start.md

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ spec:
292292
# refer to the Kubeadm Bootstrap Provider documentation.
293293
initConfiguration:
294294
nodeRegistration:
295-
name: '{{ ds.meta_data.hostname }}'
295+
name: '{{ ds.meta_data.local_hostname }}'
296296
kubeletExtraArgs:
297297
cloud-provider: aws
298298
clusterConfiguration:
@@ -427,7 +427,7 @@ spec:
427427
kubeletExtraArgs:
428428
cloud-config: /etc/kubernetes/azure.json
429429
cloud-provider: azure
430-
name: '{{ ds.meta_data["local_hostname"] }}'
430+
name: '{{ ds.meta_data.local_hostname }}'
431431
```
432432
{{#/tab }}
433433
{{#tab Docker}}
@@ -524,7 +524,7 @@ spec:
524524
# refer to the Kubeadm Bootstrap Provider documentation.
525525
initConfiguration:
526526
nodeRegistration:
527-
name: '{{ ds.meta_data.hostname }}'
527+
name: '{{ ds.meta_data.local_hostname }}'
528528
kubeletExtraArgs:
529529
cloud-provider: gce
530530
clusterConfiguration:
@@ -615,12 +615,12 @@ spec:
615615
criSocket: /var/run/containerd/containerd.sock
616616
kubeletExtraArgs:
617617
cloud-provider: external
618-
name: '{{ ds.meta_data.hostname }}'
618+
name: '{{ ds.meta_data.local_hostname }}'
619619
preKubeadmCommands:
620-
- hostname "{{ ds.meta_data.hostname }}"
620+
- hostname "{{ ds.meta_data.local_hostname }}"
621621
- echo "::1 ipv6-localhost ipv6-loopback" >/etc/hosts
622-
- echo "127.0.0.1 localhost {{ ds.meta_data.hostname }}" >>/etc/hosts
623-
- echo "{{ ds.meta_data.hostname }}" >/etc/hostname
622+
- echo "127.0.0.1 localhost {{ ds.meta_data.local_hostname }}" >>/etc/hosts
623+
- echo "{{ ds.meta_data.local_hostname }}" >/etc/hostname
624624
```
625625
{{#/tab }}
626626
{{#tab OpenStack}}
@@ -678,7 +678,7 @@ spec:
678678
advertiseAddress: '{{ ds.ec2_metadata.local_ipv4 }}'
679679
bindPort: 6443
680680
nodeRegistration:
681-
name: '{{ local_hostname }}'
681+
name: '{{ ds.meta_data.local_hostname }}'
682682
criSocket: "/var/run/containerd/containerd.sock"
683683
kubeletExtraArgs:
684684
cloud-provider: openstack
@@ -870,7 +870,7 @@ spec:
870870
# refer to the Kubeadm Bootstrap Provider documentation.
871871
joinConfiguration:
872872
nodeRegistration:
873-
name: '{{ ds.meta_data.hostname }}'
873+
name: '{{ ds.meta_data.local_hostname }}'
874874
kubeletExtraArgs:
875875
cloud-provider: aws
876876
```
@@ -967,7 +967,7 @@ spec:
967967
spec:
968968
joinConfiguration:
969969
nodeRegistration:
970-
name: '{{ ds.meta_data["local_hostname"] }}'
970+
name: '{{ ds.meta_data.local_hostname }}'
971971
kubeletExtraArgs:
972972
cloud-provider: azure
973973
cloud-config: /etc/kubernetes/azure.json
@@ -1127,7 +1127,7 @@ spec:
11271127
# refer to the Kubeadm Bootstrap Provider documentation.
11281128
joinConfiguration:
11291129
nodeRegistration:
1130-
name: '{{ ds.meta_data.hostname }}'
1130+
name: '{{ ds.meta_data.local_hostname }}'
11311131
kubeletExtraArgs:
11321132
cloud-provider: gce
11331133
```
@@ -1219,12 +1219,12 @@ spec:
12191219
criSocket: /var/run/containerd/containerd.sock
12201220
kubeletExtraArgs:
12211221
cloud-provider: external
1222-
name: '{{ ds.meta_data.hostname }}'
1222+
name: '{{ ds.meta_data.local_hostname }}'
12231223
preKubeadmCommands:
1224-
- hostname "{{ ds.meta_data.hostname }}"
1224+
- hostname "{{ ds.meta_data.local_hostname }}"
12251225
- echo "::1 ipv6-localhost ipv6-loopback" >/etc/hosts
1226-
- echo "127.0.0.1 localhost {{ ds.meta_data.hostname }}" >>/etc/hosts
1227-
- echo "{{ ds.meta_data.hostname }}" >/etc/hostname
1226+
- echo "127.0.0.1 localhost {{ ds.meta_data.local_hostname }}" >>/etc/hosts
1227+
- echo "{{ ds.meta_data.local_hostname }}" >/etc/hostname
12281228
```
12291229

12301230
{{#/tab }}

docs/proposals/20191017-kubeadm-based-control-plane.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,7 @@ spec:
405405
kubeadmConfigSpec:
406406
initConfiguration:
407407
nodeRegistration:
408-
name: '{{ ds.meta_data.hostname }}'
408+
name: '{{ ds.meta_data.local_hostname }}'
409409
kubeletExtraArgs:
410410
cloud-provider: acme
411411
clusterConfiguration:
@@ -418,7 +418,7 @@ spec:
418418
joinConfiguration:
419419
controlPlane: {}
420420
nodeRegistration:
421-
name: '{{ ds.meta_data.hostname }}'
421+
name: '{{ ds.meta_data.local_hostname }}'
422422
kubeletExtraArgs:
423423
cloud-provider: acme
424424
---
@@ -579,4 +579,4 @@ For the purposes of designing upgrades, two existing lifecycle managers were exa
579579
- [x] 10/17/2019: Initial Creation
580580
- [x] 11/19/2019: Initial KubeadmControlPlane types added [#1765](https://github.com/kubernetes-sigs/cluster-api/pull/1765)
581581
- [x] 12/04/2019: Updated References to ErrorMessage/ErrorReason to FailureMessage/FailureReason
582-
- [] 12/04/2019: Initial stubbed KubeadmControlPlane controller added [#1826](https://github.com/kubernetes-sigs/cluster-api/pull/1826)
582+
- [] 12/04/2019: Initial stubbed KubeadmControlPlane controller added [#1826](https://github.com/kubernetes-sigs/cluster-api/pull/1826)

0 commit comments

Comments
 (0)