Skip to content

Commit

Permalink
Add bootOptions to cp/md tinkerbellmachine template, fix unit-tests
Browse files Browse the repository at this point in the history
Signed-off-by: EKS Distro PR Bot <[email protected]>
  • Loading branch information
eks-distro-pr-bot committed Dec 20, 2024
1 parent 9877c1f commit 8e04adc
Show file tree
Hide file tree
Showing 24 changed files with 50 additions and 3 deletions.
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ require (
github.com/spf13/pflag v1.0.5
github.com/spf13/viper v1.18.2
github.com/stretchr/testify v1.9.0
github.com/tinkerbell/cluster-api-provider-tinkerbell v0.6.1
github.com/tinkerbell/tink v0.12.1
github.com/tinkerbell/cluster-api-provider-tinkerbell v0.1.1-0.20220615214617-9e9c2a397288
github.com/tinkerbell/tink v0.8.0
github.com/vmware/govmomi v0.37.2
go.uber.org/zap v1.26.0
golang.org/x/crypto v0.21.0
Expand Down
2 changes: 2 additions & 0 deletions pkg/providers/tinkerbell/config/template-cp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,8 @@ spec:
matchLabels: {{ range $key, $value := .etcdHardwareSelector}}
{{ $key }}: {{ $value}}
{{- end }}
bootOptions:
bootMode: netboot
templateOverride: |
{{.etcdTemplateOverride | indent 8}}
{{- end }}
Expand Down
2 changes: 2 additions & 0 deletions pkg/providers/tinkerbell/config/template-md.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ spec:
matchLabels: {{ range $key, $value := .hardwareSelector}}
{{ $key }}: {{ $value}}
{{- end }}
bootOptions:
bootMode: netboot
templateOverride: |
{{.workertemplateOverride | indent 8}}
{{- end}}
Expand Down
1 change: 0 additions & 1 deletion pkg/providers/tinkerbell/stack/stack_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,6 @@ func TestTinkerbellStackInstallWithDifferentOptions(t *testing.T) {
"-e", gomock.Any(),
"-e", gomock.Any(),
"-e", gomock.Any(),
"-e", gomock.Any(),
)
}

Expand Down
2 changes: 2 additions & 0 deletions pkg/providers/tinkerbell/testdata/expected_kct.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ spec:
required:
- labelSelector:
matchLabels:
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down Expand Up @@ -217,6 +219,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down Expand Up @@ -216,6 +218,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ spec:
- labelSelector:
matchLabels:
type: worker
bootOptions:
bootMode: netboot
templateOverride: |
global_timeout: 6000
id: ""
Expand Down

0 comments on commit 8e04adc

Please sign in to comment.