Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(kind) let users specify a KIND config file #222

Merged
merged 3 commits into from
Feb 17, 2022
Merged

Conversation

rainest
Copy link
Contributor

@rainest rainest commented Feb 17, 2022

As seen in Kong/kubernetes-ingress-controller#2258

When creating a KIND cluster, users can specify a KIND configuration file. This requires creating a cluster and then an environment with that existing cluster, since it is not a generic Environment feature.

@rainest rainest requested a review from a team as a code owner February 17, 2022 20:09
@rainest rainest temporarily deployed to integration-tests February 17, 2022 20:09 Inactive
pkg/clusters/types/kind/builder.go Outdated Show resolved Hide resolved
@shaneutt
Copy link
Contributor

We do need to make sure that we test this locally before merging, then LGTM.

Co-authored-by: Shane Utt <shaneutt@linux.com>
@rainest rainest temporarily deployed to integration-tests February 17, 2022 20:27 Inactive
@rainest rainest temporarily deployed to integration-tests February 17, 2022 20:27 Inactive
@rainest rainest enabled auto-merge (squash) February 17, 2022 20:28
@rainest
Copy link
Contributor Author

rainest commented Feb 17, 2022

Testing was essentially "it makes the other PR work" and execing into the kubelet to check its kubeadm config did indeed include the change.

A simpler demonstration is to try and load malformed YAML; KIND will quickly complain at you:

11:25:47-0800 esenin $ TEST_KONG_CONTROLLER_IMAGE_LOAD="traines/kic:2.2.0-cert" TEST_KONG_CONTROLLER_IMAGE_OVERRIDE="traines/kic:2.2.0-cert" GOFLAGS="-tags=e2e_tests" dlv test -- -test.v -test.run TestWebhookUpdate
Type 'help' for list of commands.
(dlv) c
=== RUN   TestWebhookUpdate
    features_test.go:107: configuring all-in-one-dbless.yaml manifest test
=== PAUSE TestWebhookUpdate
=== CONT  TestWebhookUpdate
    features_test.go:112: building test cluster and environment
    features_test.go:129: 
        	Error Trace:	features_test.go:129
        	Error:      	Received unexpected error:
        	            	failed to create cluster 1903f8ef-78b7-42cf-9726-eb8a5289fea0: ERROR: failed to create cluster: could not determine kind / apiVersion for config: yaml: line 6: found a tab character where an indentation space is expected
        	            	: exit status 1
        	Test:       	TestWebhookUpdate
--- FAIL: TestWebhookUpdate (0.03s)
FAIL
Process 466676 has exited with status 1

@shaneutt
Copy link
Contributor

Sounds good 🖖 🚢

@rainest rainest merged commit 8fd7331 into main Feb 17, 2022
@rainest rainest deleted the feat/kindconfig branch February 17, 2022 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants