Skip to content

Commit 38f28da

Browse files
committed
docs: Correct OpenStackMachineTemplate examples
Our examples indicated: apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7 kind: OpenStackMachineTemplate ... spec: foo: ... when in fact it should read: apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7 kind: OpenStackMachineTemplate ... spec: template: spec: foo: ... Correct this oversight. Signed-off-by: Stephen Finucane <[email protected]>
1 parent dd5e590 commit 38f28da

File tree

1 file changed

+67
-55
lines changed

1 file changed

+67
-55
lines changed

docs/book/src/clusteropenstack/configuration.md

Lines changed: 67 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -303,9 +303,11 @@ metadata:
303303
name: <cluster-name>-controlplane
304304
namespace: <cluster-name>
305305
spec:
306-
networks:
307-
- filter:
308-
name: <network-name>
306+
template:
307+
spec:
308+
networks:
309+
- filter:
310+
name: <network-name>
309311
```
310312

311313
## Multiple Networks
@@ -319,12 +321,14 @@ metadata:
319321
name: <cluster-name>-controlplane
320322
namespace: <cluster-name>
321323
spec:
322-
networks:
323-
- filter:
324-
name: myNetwork
325-
tags: myTag
326-
- uuid: your_network_id
327-
- subnet_id: your_subnet_id
324+
template:
325+
spec:
326+
networks:
327+
- filter:
328+
name: myNetwork
329+
tags: myTag
330+
- uuid: your_network_id
331+
- subnet_id: your_subnet_id
328332
```
329333

330334
## Subnet Filters
@@ -338,12 +342,14 @@ metadata:
338342
name: <cluster-name>-controlplane
339343
namespace: <cluster-name>
340344
spec:
341-
networks:
342-
- filter:
343-
name: <network-name>
344-
subnets:
345-
- filter:
346-
name: <subnet-name>
345+
template:
346+
spec:
347+
networks:
348+
- filter:
349+
name: <network-name>
350+
subnets:
351+
- filter:
352+
name: <subnet-name>
347353
```
348354

349355
## Ports
@@ -357,26 +363,28 @@ metadata:
357363
name: <cluster-name>-controlplane
358364
namespace: <cluster-name>
359365
spec:
360-
ports:
361-
- network:
362-
id: <your-network-id>
363-
fixedIPs:
364-
- subnet:
365-
id: <your-subnet-id>
366-
ipAddress: <your-fixed-ip>
367-
- subnet:
368-
name: <your-subnet-name>
369-
tags:
370-
- tag1
371-
- tag2
372-
nameSuffix: <your-port-name>
373-
description: <your-custom-port-description>
374-
vnicType: normal
375-
securityGroups:
376-
- <your-security-group-id>
377-
profile:
378-
capabilities:
379-
- <capability>
366+
template:
367+
spec:
368+
ports:
369+
- network:
370+
id: <your-network-id>
371+
fixedIPs:
372+
- subnet:
373+
id: <your-subnet-id>
374+
ipAddress: <your-fixed-ip>
375+
- subnet:
376+
name: <your-subnet-name>
377+
tags:
378+
- tag1
379+
- tag2
380+
nameSuffix: <your-port-name>
381+
description: <your-custom-port-description>
382+
vnicType: normal
383+
securityGroups:
384+
- <your-security-group-id>
385+
profile:
386+
capabilities:
387+
- <capability>
380388
```
381389

382390
Any such ports are created in addition to ports used for connections to networks or subnets.
@@ -453,12 +461,14 @@ metadata:
453461
name: <cluster-name>-controlplane
454462
namespace: <cluster-name>
455463
spec:
456-
ports:
457-
- network:
458-
id: <your-network-id>
459-
...
460-
disablePortSecurity: true
461-
...
464+
template:
465+
spec:
466+
ports:
467+
- network:
468+
id: <your-network-id>
469+
...
470+
disablePortSecurity: true
471+
...
462472
```
463473

464474
## Security groups
@@ -554,20 +564,22 @@ spec:
554564

555565
For example in `OpenStackMachineTemplate` set `spec.rootVolume.diskSize` to something greater than `0` means boot from volume.
556566

557-
```yaml
558-
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7
559-
kind: OpenStackMachineTemplate
560-
metadata:
561-
name: <cluster-name>-controlplane
562-
namespace: <cluster-name>
563-
spec:
564-
...
565-
rootVolume:
566-
diskSize: <image size>
567-
volumeType: <a cinder volume type (*optional)>
568-
availabilityZone: <the cinder availability zone for the root volume (*optional)>
569-
...
570-
```
567+
```yaml
568+
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7
569+
kind: OpenStackMachineTemplate
570+
metadata:
571+
name: <cluster-name>-controlplane
572+
namespace: <cluster-name>
573+
spec:
574+
template:
575+
spec:
576+
...
577+
rootVolume:
578+
diskSize: <image size>
579+
volumeType: <a cinder volume type (*optional)>
580+
availabilityZone: <the cinder availability zone for the root volume (*optional)>
581+
...
582+
```
571583

572584
If `volumeType` is not specified, cinder will use the default volume type.
573585

0 commit comments

Comments
 (0)