@@ -38,42 +38,40 @@ var _ = ginkgo.Describe("test clusteradm with bootstrap token in singleton mode"
38
38
"--use-bootstrap-token" ,
39
39
"--context" , e2e .Cluster ().Hub ().Context (),
40
40
"--bundle-version=latest" ,
41
- "--registration-auth =awsirsa" ,
41
+ "--registration-drivers =awsirsa" ,
42
42
"--hub-cluster-arn=arn:aws:eks:us-west-2:123456789012:cluster/hub-cluster1" ,
43
43
)
44
44
gomega .Expect (err ).NotTo (gomega .HaveOccurred (), "clusteradm init error" )
45
45
46
46
cm , err = operatorClient .OperatorV1 ().ClusterManagers ().Get (context .TODO (), "cluster-manager" , metav1.GetOptions {})
47
47
gomega .Expect (err ).NotTo (gomega .HaveOccurred ())
48
- // Ensure that when only awsirsa is passed as registration-auth only awsirsa driver is available
48
+ // Ensure that when only awsirsa is passed as registration-drivers only awsirsa driver is available
49
49
gomega .Expect (len (cm .Spec .RegistrationConfiguration .RegistrationDrivers )).Should (gomega .Equal (1 ))
50
50
gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ].AuthType ).Should (gomega .Equal ("awsirsa" ))
51
51
52
52
err = e2e .Clusteradm ().Init (
53
53
"--use-bootstrap-token" ,
54
54
"--context" , e2e .Cluster ().Hub ().Context (),
55
55
"--bundle-version=latest" ,
56
- "--registration-auth=awsirsa" ,
57
- "--registration-auth=csr" ,
56
+ "--registration-drivers=awsirsa,csr" ,
58
57
"--hub-cluster-arn=arn:aws:eks:us-west-2:123456789012:cluster/hub-cluster1" ,
59
58
)
60
59
gomega .Expect (err ).NotTo (gomega .HaveOccurred (), "clusteradm init error" )
61
60
62
61
cm , err = operatorClient .OperatorV1 ().ClusterManagers ().Get (context .TODO (), "cluster-manager" , metav1.GetOptions {})
63
62
gomega .Expect (err ).NotTo (gomega .HaveOccurred ())
64
- // Ensure that awsirsa and csr is passed as registration-auth both the values are set.
63
+ // Ensure that awsirsa and csr is passed as registration-drivers both the values are set.
65
64
gomega .Expect (len (cm .Spec .RegistrationConfiguration .RegistrationDrivers )).Should (gomega .Equal (2 ))
66
- gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ].AuthType ).Should (gomega .Equal ("csr " ))
67
- gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [1 ].AuthType ).Should (gomega .Equal ("awsirsa " ))
68
- gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [1 ].HubClusterArn ).
65
+ gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ].AuthType ).Should (gomega .Equal ("awsirsa " ))
66
+ gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [1 ].AuthType ).Should (gomega .Equal ("csr " ))
67
+ gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ].HubClusterArn ).
69
68
Should (gomega .Equal ("arn:aws:eks:us-west-2:123456789012:cluster/hub-cluster1" ))
70
69
71
70
err = e2e .Clusteradm ().Init (
72
71
"--use-bootstrap-token" ,
73
72
"--context" , e2e .Cluster ().Hub ().Context (),
74
73
"--bundle-version=latest" ,
75
- "--registration-auth=awsirsa" ,
76
- "--registration-auth=csr" ,
74
+ "--registration-drivers=awsirsa,csr" ,
77
75
"--hub-cluster-arn=arn:aws:eks:us-west-2:123456789012:cluster/hub-cluster1" ,
78
76
"--feature-gates=ManagedClusterAutoApproval=true" ,
79
77
"--auto-approved-csr-identities=csr1" ,
@@ -83,10 +81,10 @@ var _ = ginkgo.Describe("test clusteradm with bootstrap token in singleton mode"
83
81
cm , err = operatorClient .OperatorV1 ().ClusterManagers ().Get (context .TODO (), "cluster-manager" , metav1.GetOptions {})
84
82
gomega .Expect (err ).NotTo (gomega .HaveOccurred ())
85
83
// Ensure that the auto approval identities contain user for CSR and pattern for AWS
86
- gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ].AuthType ).Should (gomega .Equal ("csr " ))
87
- gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [1 ].AuthType ).Should (gomega .Equal ("awsirsa " ))
88
- gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ]. CSR . AutoApprovedIdentities ).Should (gomega .Equal ("csr1" ))
89
- gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [1 ]. AwsIrsa . AutoApprovedIdentities ).Should (gomega .Equal ("arn:aws:eks:us-west-2:123456789012:cluster/*" ))
84
+ gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ].AuthType ).Should (gomega .Equal ("awsirsa " ))
85
+ gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [1 ].AuthType ).Should (gomega .Equal ("csr " ))
86
+ gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [1 ]. AutoApprovedIdentities [ 0 ] ).Should (gomega .Equal ("csr1" ))
87
+ gomega .Expect (cm .Spec .RegistrationConfiguration .RegistrationDrivers [0 ]. AutoApprovedIdentities [ 0 ] ).Should (gomega .Equal ("arn:aws:eks:us-west-2:123456789012:cluster/*" ))
90
88
91
89
err = e2e .Clusteradm ().Init (
92
90
"--use-bootstrap-token" ,
0 commit comments