File tree 3 files changed +21
-4
lines changed
3 files changed +21
-4
lines changed Original file line number Diff line number Diff line change @@ -46,3 +46,4 @@ verify_go_version
46
46
47
47
# Explicitly opt into go modules, even though we're inside a GOPATH directory
48
48
export GO111MODULE=on
49
+ export GOFLAGS=" -mod=vendor"
Original file line number Diff line number Diff line change @@ -66,7 +66,23 @@ prepare_crd_yaml() {
66
66
}
67
67
68
68
create_bootstrap () {
69
- kind create cluster --name " ${BOOTSTRAP_CLUSTER_NAME} "
69
+ cat << EOF > /tmp/integration.cluster
70
+ # this config file contains all config fields with comments
71
+ kind: Cluster
72
+ apiVersion: kind.sigs.k8s.io/v1alpha3
73
+ # patch the generated kubeadm config with some extra settings
74
+ kubeadmConfigPatches:
75
+ - |
76
+ apiVersion: kubeadm.k8s.io/v1beta1
77
+ kind: ClusterConfiguration
78
+ metadata:
79
+ name: config
80
+ apiServer:
81
+ extraArgs:
82
+ "feature-gates": "CustomResourceWebhookConversion=true"
83
+ EOF
84
+
85
+ kind create cluster --name " ${BOOTSTRAP_CLUSTER_NAME} " --config /tmp/integration.cluster
70
86
KUBECONFIG=" $( kind get kubeconfig-path --name=" ${BOOTSTRAP_CLUSTER_NAME} " ) "
71
87
export KUBECONFIG
72
88
Original file line number Diff line number Diff line change @@ -30,11 +30,11 @@ import (
30
30
"k8s.io/client-go/tools/clientcmd"
31
31
clusterv1alpha1 "sigs.k8s.io/cluster-api/pkg/apis/cluster/v1alpha2"
32
32
clientset "sigs.k8s.io/cluster-api/pkg/client/clientset_generated/clientset"
33
- client "sigs.k8s.io/cluster-api/pkg/client/clientset_generated/clientset/typed/cluster/v1alpha1 "
33
+ client "sigs.k8s.io/cluster-api/pkg/client/clientset_generated/clientset/typed/cluster/v1alpha2 "
34
34
)
35
35
36
36
var clusterSpec = & clusterv1alpha1.ClusterSpec {
37
- ClusterNetwork : clusterv1alpha1.ClusterNetworkingConfig {
37
+ ClusterNetwork : & clusterv1alpha1.ClusterNetworkingConfig {
38
38
ServiceDomain : "mydomain.com" ,
39
39
Services : clusterv1alpha1.NetworkRanges {
40
40
CIDRBlocks : []string {"10.96.0.0/12" },
@@ -84,7 +84,7 @@ var _ = Describe("Cluster-Controller", func() {
84
84
// Create clusterapi client
85
85
cs , err := clientset .NewForConfig (config )
86
86
Expect (err ).ShouldNot (HaveOccurred ())
87
- clusterapi = cs .ClusterV1alpha1 ().Clusters (testNamespace )
87
+ clusterapi = cs .ClusterV1alpha2 ().Clusters (testNamespace )
88
88
})
89
89
90
90
AfterEach (func () {
You can’t perform that action at this time.
0 commit comments