Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
d69e0ff3
Commit
d69e0ff3
authored
Mar 01, 2019
by
Xing Yang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Enable CSI test suite and fix test failures
parent
85867e56
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
37 additions
and
78 deletions
+37
-78
csi_mock_volume.go
test/e2e/storage/csi_mock_volume.go
+0
-1
csi_volumes.go
test/e2e/storage/csi_volumes.go
+1
-5
BUILD
test/integration/auth/BUILD
+1
-3
node_test.go
test/integration/auth/node_test.go
+34
-60
rbac_test.go
test/integration/auth/rbac_test.go
+0
-8
data.go
test/integration/etcd/data.go
+1
-1
No files found.
test/e2e/storage/csi_mock_volume.go
View file @
d69e0ff3
...
@@ -33,7 +33,6 @@ import (
...
@@ -33,7 +33,6 @@ import (
"k8s.io/apimachinery/pkg/util/sets"
"k8s.io/apimachinery/pkg/util/sets"
"k8s.io/apimachinery/pkg/util/wait"
"k8s.io/apimachinery/pkg/util/wait"
clientset
"k8s.io/client-go/kubernetes"
clientset
"k8s.io/client-go/kubernetes"
//csiclient "k8s.io/csi-api/pkg/client/clientset/versioned"
volumeutil
"k8s.io/kubernetes/pkg/volume/util"
volumeutil
"k8s.io/kubernetes/pkg/volume/util"
"k8s.io/kubernetes/test/e2e/framework"
"k8s.io/kubernetes/test/e2e/framework"
"k8s.io/kubernetes/test/e2e/storage/drivers"
"k8s.io/kubernetes/test/e2e/storage/drivers"
...
...
test/e2e/storage/csi_volumes.go
View file @
d69e0ff3
...
@@ -55,11 +55,7 @@ var _ = utils.SIGDescribe("CSI Volumes", func() {
...
@@ -55,11 +55,7 @@ var _ = utils.SIGDescribe("CSI Volumes", func() {
curDriver
:=
initDriver
()
curDriver
:=
initDriver
()
Context
(
testsuites
.
GetDriverNameWithFeatureTags
(
curDriver
),
func
()
{
Context
(
testsuites
.
GetDriverNameWithFeatureTags
(
curDriver
),
func
()
{
// TODO(xyang): Disable the CSI tests until the sidecar container images
testsuites
.
DefineTestSuite
(
curDriver
,
csiTestSuites
)
// are updated to support CSINodeInfo and CSIDriver Core APIs in the
// following PR:
// https://github.com/kubernetes/kubernetes/pull/73883
//testsuites.DefineTestSuite(curDriver, csiTestSuites)
})
})
}
}
...
...
test/integration/auth/BUILD
View file @
d69e0ff3
...
@@ -52,6 +52,7 @@ go_test(
...
@@ -52,6 +52,7 @@ go_test(
"//staging/src/k8s.io/api/authentication/v1beta1:go_default_library",
"//staging/src/k8s.io/api/authentication/v1beta1:go_default_library",
"//staging/src/k8s.io/api/core/v1:go_default_library",
"//staging/src/k8s.io/api/core/v1:go_default_library",
"//staging/src/k8s.io/api/storage/v1:go_default_library",
"//staging/src/k8s.io/api/storage/v1:go_default_library",
"//staging/src/k8s.io/api/storage/v1beta1:go_default_library",
"//staging/src/k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1:go_default_library",
"//staging/src/k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1:go_default_library",
"//staging/src/k8s.io/apiextensions-apiserver/pkg/client/clientset/clientset:go_default_library",
"//staging/src/k8s.io/apiextensions-apiserver/pkg/client/clientset/clientset:go_default_library",
"//staging/src/k8s.io/apimachinery/pkg/api/errors:go_default_library",
"//staging/src/k8s.io/apimachinery/pkg/api/errors:go_default_library",
...
@@ -87,11 +88,8 @@ go_test(
...
@@ -87,11 +88,8 @@ go_test(
"//staging/src/k8s.io/client-go/transport:go_default_library",
"//staging/src/k8s.io/client-go/transport:go_default_library",
"//staging/src/k8s.io/client-go/util/keyutil:go_default_library",
"//staging/src/k8s.io/client-go/util/keyutil:go_default_library",
"//staging/src/k8s.io/cluster-bootstrap/token/api:go_default_library",
"//staging/src/k8s.io/cluster-bootstrap/token/api:go_default_library",
"//staging/src/k8s.io/csi-api/pkg/apis/csi/v1alpha1:go_default_library",
"//staging/src/k8s.io/csi-api/pkg/client/clientset/versioned:go_default_library",
"//test/e2e/lifecycle/bootstrap:go_default_library",
"//test/e2e/lifecycle/bootstrap:go_default_library",
"//test/integration:go_default_library",
"//test/integration:go_default_library",
"//test/integration/etcd:go_default_library",
"//test/integration/framework:go_default_library",
"//test/integration/framework:go_default_library",
"//vendor/gopkg.in/square/go-jose.v2/jwt:go_default_library",
"//vendor/gopkg.in/square/go-jose.v2/jwt:go_default_library",
"//vendor/k8s.io/klog:go_default_library",
"//vendor/k8s.io/klog:go_default_library",
...
...
test/integration/auth/node_test.go
View file @
d69e0ff3
...
@@ -24,6 +24,7 @@ import (
...
@@ -24,6 +24,7 @@ import (
"time"
"time"
storagev1
"k8s.io/api/storage/v1"
storagev1
"k8s.io/api/storage/v1"
storagev1beta1
"k8s.io/api/storage/v1beta1"
apiextensionsv1beta1
"k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1"
apiextensionsv1beta1
"k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/api/resource"
"k8s.io/apimachinery/pkg/api/resource"
...
@@ -34,8 +35,6 @@ import (
...
@@ -34,8 +35,6 @@ import (
utilfeature
"k8s.io/apiserver/pkg/util/feature"
utilfeature
"k8s.io/apiserver/pkg/util/feature"
utilfeaturetesting
"k8s.io/apiserver/pkg/util/feature/testing"
utilfeaturetesting
"k8s.io/apiserver/pkg/util/feature/testing"
externalclientset
"k8s.io/client-go/kubernetes"
externalclientset
"k8s.io/client-go/kubernetes"
csiv1alpha1
"k8s.io/csi-api/pkg/apis/csi/v1alpha1"
csiclientset
"k8s.io/csi-api/pkg/client/clientset/versioned"
kubeapiservertesting
"k8s.io/kubernetes/cmd/kube-apiserver/app/testing"
kubeapiservertesting
"k8s.io/kubernetes/cmd/kube-apiserver/app/testing"
"k8s.io/kubernetes/pkg/api/legacyscheme"
"k8s.io/kubernetes/pkg/api/legacyscheme"
"k8s.io/kubernetes/pkg/apis/coordination"
"k8s.io/kubernetes/pkg/apis/coordination"
...
@@ -44,7 +43,6 @@ import (
...
@@ -44,7 +43,6 @@ import (
"k8s.io/kubernetes/pkg/apis/policy"
"k8s.io/kubernetes/pkg/apis/policy"
clientset
"k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset"
clientset
"k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset"
"k8s.io/kubernetes/pkg/features"
"k8s.io/kubernetes/pkg/features"
"k8s.io/kubernetes/test/integration/etcd"
"k8s.io/kubernetes/test/integration/framework"
"k8s.io/kubernetes/test/integration/framework"
"k8s.io/utils/pointer"
"k8s.io/utils/pointer"
)
)
...
@@ -67,7 +65,7 @@ func TestNodeAuthorizer(t *testing.T) {
...
@@ -67,7 +65,7 @@ func TestNodeAuthorizer(t *testing.T) {
// Enable NodeLease feature so that nodes can create leases
// Enable NodeLease feature so that nodes can create leases
defer
utilfeaturetesting
.
SetFeatureGateDuringTest
(
t
,
utilfeature
.
DefaultFeatureGate
,
features
.
NodeLease
,
true
)()
defer
utilfeaturetesting
.
SetFeatureGateDuringTest
(
t
,
utilfeature
.
DefaultFeatureGate
,
features
.
NodeLease
,
true
)()
// Enable CSINodeInfo feature so that nodes can create CSINode
Info
objects.
// Enable CSINodeInfo feature so that nodes can create CSINode objects.
defer
utilfeaturetesting
.
SetFeatureGateDuringTest
(
t
,
utilfeature
.
DefaultFeatureGate
,
features
.
CSINodeInfo
,
true
)()
defer
utilfeaturetesting
.
SetFeatureGateDuringTest
(
t
,
utilfeature
.
DefaultFeatureGate
,
features
.
CSINodeInfo
,
true
)()
tokenFile
,
err
:=
ioutil
.
TempFile
(
""
,
"kubeconfig"
)
tokenFile
,
err
:=
ioutil
.
TempFile
(
""
,
"kubeconfig"
)
...
@@ -95,7 +93,6 @@ func TestNodeAuthorizer(t *testing.T) {
...
@@ -95,7 +93,6 @@ func TestNodeAuthorizer(t *testing.T) {
// Build client config and superuser clientset
// Build client config and superuser clientset
clientConfig
:=
server
.
ClientConfig
clientConfig
:=
server
.
ClientConfig
superuserClient
,
superuserClientExternal
:=
clientsetForToken
(
tokenMaster
,
clientConfig
)
superuserClient
,
superuserClientExternal
:=
clientsetForToken
(
tokenMaster
,
clientConfig
)
superuserCRDClient
:=
crdClientsetForToken
(
tokenMaster
,
clientConfig
)
// Wait for a healthy server
// Wait for a healthy server
for
{
for
{
...
@@ -158,13 +155,6 @@ func TestNodeAuthorizer(t *testing.T) {
...
@@ -158,13 +155,6 @@ func TestNodeAuthorizer(t *testing.T) {
t
.
Fatal
(
err
)
t
.
Fatal
(
err
)
}
}
csiNodeInfoCRD
,
err
:=
crdFromManifest
(
"../../../staging/src/k8s.io/csi-api/pkg/crd/manifests/csinodeinfo.yaml"
)
if
err
!=
nil
{
t
.
Fatal
(
err
)
}
etcd
.
CreateTestCRDs
(
t
,
superuserCRDClient
,
false
,
csiNodeInfoCRD
)
getSecret
:=
func
(
client
clientset
.
Interface
)
func
()
error
{
getSecret
:=
func
(
client
clientset
.
Interface
)
func
()
error
{
return
func
()
error
{
return
func
()
error
{
_
,
err
:=
client
.
Core
()
.
Secrets
(
"ns"
)
.
Get
(
"mysecret"
,
metav1
.
GetOptions
{})
_
,
err
:=
client
.
Core
()
.
Secrets
(
"ns"
)
.
Get
(
"mysecret"
,
metav1
.
GetOptions
{})
...
@@ -412,84 +402,68 @@ func TestNodeAuthorizer(t *testing.T) {
...
@@ -412,84 +402,68 @@ func TestNodeAuthorizer(t *testing.T) {
}
}
}
}
getNode1CSINode
Info
:=
func
(
client
csi
clientset
.
Interface
)
func
()
error
{
getNode1CSINode
:=
func
(
client
external
clientset
.
Interface
)
func
()
error
{
return
func
()
error
{
return
func
()
error
{
_
,
err
:=
client
.
CsiV1alpha1
()
.
CSINodeInfo
s
()
.
Get
(
"node1"
,
metav1
.
GetOptions
{})
_
,
err
:=
client
.
StorageV1beta1
()
.
CSINode
s
()
.
Get
(
"node1"
,
metav1
.
GetOptions
{})
return
err
return
err
}
}
}
}
createNode1CSINode
Info
:=
func
(
client
csi
clientset
.
Interface
)
func
()
error
{
createNode1CSINode
:=
func
(
client
external
clientset
.
Interface
)
func
()
error
{
return
func
()
error
{
return
func
()
error
{
nodeInfo
:=
&
csiv1alpha1
.
CSINodeInfo
{
nodeInfo
:=
&
storagev1beta1
.
CSINode
{
ObjectMeta
:
metav1
.
ObjectMeta
{
ObjectMeta
:
metav1
.
ObjectMeta
{
Name
:
"node1"
,
Name
:
"node1"
,
},
},
Spec
:
csiv1alpha1
.
CSINodeInfo
Spec
{
Spec
:
storagev1beta1
.
CSINode
Spec
{
Drivers
:
[]
csiv1alpha1
.
CSIDriverInfoSpec
{
Drivers
:
[]
storagev1beta1
.
CSINodeDriver
{
{
{
Name
:
"com.example.csi
/
driver1"
,
Name
:
"com.example.csi
.
driver1"
,
NodeID
:
"com.example.csi/node1"
,
NodeID
:
"com.example.csi/node1"
,
TopologyKeys
:
[]
string
{
"com.example.csi/zone"
},
TopologyKeys
:
[]
string
{
"com.example.csi/zone"
},
},
},
},
},
},
},
Status
:
csiv1alpha1
.
CSINodeInfoStatus
{
Drivers
:
[]
csiv1alpha1
.
CSIDriverInfoStatus
{
{
Name
:
"com.example.csi/driver1"
,
Available
:
true
,
VolumePluginMechanism
:
csiv1alpha1
.
VolumePluginMechanismInTree
,
},
},
},
}
}
_
,
err
:=
client
.
CsiV1alpha1
()
.
CSINodeInfo
s
()
.
Create
(
nodeInfo
)
_
,
err
:=
client
.
StorageV1beta1
()
.
CSINode
s
()
.
Create
(
nodeInfo
)
return
err
return
err
}
}
}
}
updateNode1CSINode
Info
:=
func
(
client
csi
clientset
.
Interface
)
func
()
error
{
updateNode1CSINode
:=
func
(
client
external
clientset
.
Interface
)
func
()
error
{
return
func
()
error
{
return
func
()
error
{
nodeInfo
,
err
:=
client
.
CsiV1alpha1
()
.
CSINodeInfo
s
()
.
Get
(
"node1"
,
metav1
.
GetOptions
{})
nodeInfo
,
err
:=
client
.
StorageV1beta1
()
.
CSINode
s
()
.
Get
(
"node1"
,
metav1
.
GetOptions
{})
if
err
!=
nil
{
if
err
!=
nil
{
return
err
return
err
}
}
nodeInfo
.
Spec
.
Drivers
=
[]
csiv1alpha1
.
CSIDriverInfoSpec
{
nodeInfo
.
Spec
.
Drivers
=
[]
storagev1beta1
.
CSINodeDriver
{
{
{
Name
:
"com.example.csi
/driver1
"
,
Name
:
"com.example.csi
.driver2
"
,
NodeID
:
"com.example.csi/node1"
,
NodeID
:
"com.example.csi/node1"
,
TopologyKeys
:
[]
string
{
"com.example.csi/rack"
},
TopologyKeys
:
[]
string
{
"com.example.csi/rack"
},
},
},
}
}
nodeInfo
.
Status
.
Drivers
=
[]
csiv1alpha1
.
CSIDriverInfoStatus
{
_
,
err
=
client
.
StorageV1beta1
()
.
CSINodes
()
.
Update
(
nodeInfo
)
{
Name
:
"com.example.csi/driver1"
,
Available
:
true
,
VolumePluginMechanism
:
csiv1alpha1
.
VolumePluginMechanismInTree
,
},
}
_
,
err
=
client
.
CsiV1alpha1
()
.
CSINodeInfos
()
.
Update
(
nodeInfo
)
return
err
return
err
}
}
}
}
patchNode1CSINode
Info
:=
func
(
client
csi
clientset
.
Interface
)
func
()
error
{
patchNode1CSINode
:=
func
(
client
external
clientset
.
Interface
)
func
()
error
{
return
func
()
error
{
return
func
()
error
{
bs
:=
[]
byte
(
fmt
.
Sprintf
(
`{"csiDrivers": [ { "driver": "net.example.storage
/
driver2", "nodeID": "net.example.storage/node1", "topologyKeys": [ "net.example.storage/region" ] } ] }`
))
bs
:=
[]
byte
(
fmt
.
Sprintf
(
`{"csiDrivers": [ { "driver": "net.example.storage
.
driver2", "nodeID": "net.example.storage/node1", "topologyKeys": [ "net.example.storage/region" ] } ] }`
))
// StrategicMergePatch is unsupported by CRs. Falling back to MergePatch
// StrategicMergePatch is unsupported by CRs. Falling back to MergePatch
_
,
err
:=
client
.
CsiV1alpha1
()
.
CSINodeInfo
s
()
.
Patch
(
"node1"
,
types
.
MergePatchType
,
bs
)
_
,
err
:=
client
.
StorageV1beta1
()
.
CSINode
s
()
.
Patch
(
"node1"
,
types
.
MergePatchType
,
bs
)
return
err
return
err
}
}
}
}
deleteNode1CSINode
Info
:=
func
(
client
csi
clientset
.
Interface
)
func
()
error
{
deleteNode1CSINode
:=
func
(
client
external
clientset
.
Interface
)
func
()
error
{
return
func
()
error
{
return
func
()
error
{
return
client
.
CsiV1alpha1
()
.
CSINodeInfo
s
()
.
Delete
(
"node1"
,
&
metav1
.
DeleteOptions
{})
return
client
.
StorageV1beta1
()
.
CSINode
s
()
.
Delete
(
"node1"
,
&
metav1
.
DeleteOptions
{})
}
}
}
}
nodeanonClient
,
_
:=
clientsetForToken
(
tokenNodeUnknown
,
clientConfig
)
nodeanonClient
,
_
:=
clientsetForToken
(
tokenNodeUnknown
,
clientConfig
)
node1Client
,
node1ClientExternal
:=
clientsetForToken
(
tokenNode1
,
clientConfig
)
node1Client
,
node1ClientExternal
:=
clientsetForToken
(
tokenNode1
,
clientConfig
)
node2Client
,
node2ClientExternal
:=
clientsetForToken
(
tokenNode2
,
clientConfig
)
node2Client
,
node2ClientExternal
:=
clientsetForToken
(
tokenNode2
,
clientConfig
)
csiNode1Client
:=
csiC
lientsetForToken
(
tokenNode1
,
clientConfig
)
_
,
csiNode1Client
:=
c
lientsetForToken
(
tokenNode1
,
clientConfig
)
csiNode2Client
:=
csiC
lientsetForToken
(
tokenNode2
,
clientConfig
)
_
,
csiNode2Client
:=
c
lientsetForToken
(
tokenNode2
,
clientConfig
)
// all node requests from node1 and unknown node fail
// all node requests from node1 and unknown node fail
expectForbidden
(
t
,
getSecret
(
nodeanonClient
))
expectForbidden
(
t
,
getSecret
(
nodeanonClient
))
...
@@ -645,18 +619,18 @@ func TestNodeAuthorizer(t *testing.T) {
...
@@ -645,18 +619,18 @@ func TestNodeAuthorizer(t *testing.T) {
expectForbidden
(
t
,
patchNode1Lease
(
node2Client
))
expectForbidden
(
t
,
patchNode1Lease
(
node2Client
))
expectForbidden
(
t
,
deleteNode1Lease
(
node2Client
))
expectForbidden
(
t
,
deleteNode1Lease
(
node2Client
))
// node1 allowed to operate on its own CSINode
Info
// node1 allowed to operate on its own CSINode
expectAllowed
(
t
,
createNode1CSINode
Info
(
csiNode1Client
))
expectAllowed
(
t
,
createNode1CSINode
(
csiNode1Client
))
expectAllowed
(
t
,
getNode1CSINode
Info
(
csiNode1Client
))
expectAllowed
(
t
,
getNode1CSINode
(
csiNode1Client
))
expectAllowed
(
t
,
updateNode1CSINode
Info
(
csiNode1Client
))
expectAllowed
(
t
,
updateNode1CSINode
(
csiNode1Client
))
expectAllowed
(
t
,
patchNode1CSINode
Info
(
csiNode1Client
))
expectAllowed
(
t
,
patchNode1CSINode
(
csiNode1Client
))
expectAllowed
(
t
,
deleteNode1CSINode
Info
(
csiNode1Client
))
expectAllowed
(
t
,
deleteNode1CSINode
(
csiNode1Client
))
// node2 not allowed to operate on another node's CSINode
Info
// node2 not allowed to operate on another node's CSINode
expectForbidden
(
t
,
createNode1CSINode
Info
(
csiNode2Client
))
expectForbidden
(
t
,
createNode1CSINode
(
csiNode2Client
))
expectForbidden
(
t
,
getNode1CSINode
Info
(
csiNode2Client
))
expectForbidden
(
t
,
getNode1CSINode
(
csiNode2Client
))
expectForbidden
(
t
,
updateNode1CSINode
Info
(
csiNode2Client
))
expectForbidden
(
t
,
updateNode1CSINode
(
csiNode2Client
))
expectForbidden
(
t
,
patchNode1CSINode
Info
(
csiNode2Client
))
expectForbidden
(
t
,
patchNode1CSINode
(
csiNode2Client
))
expectForbidden
(
t
,
deleteNode1CSINode
Info
(
csiNode2Client
))
expectForbidden
(
t
,
deleteNode1CSINode
(
csiNode2Client
))
}
}
// expect executes a function a set number of times until it either returns the
// expect executes a function a set number of times until it either returns the
...
...
test/integration/auth/rbac_test.go
View file @
d69e0ff3
...
@@ -45,7 +45,6 @@ import (
...
@@ -45,7 +45,6 @@ import (
restclient
"k8s.io/client-go/rest"
restclient
"k8s.io/client-go/rest"
watchtools
"k8s.io/client-go/tools/watch"
watchtools
"k8s.io/client-go/tools/watch"
"k8s.io/client-go/transport"
"k8s.io/client-go/transport"
csiclientset
"k8s.io/csi-api/pkg/client/clientset/versioned"
"k8s.io/klog"
"k8s.io/klog"
"k8s.io/kubernetes/pkg/api/legacyscheme"
"k8s.io/kubernetes/pkg/api/legacyscheme"
"k8s.io/kubernetes/pkg/api/testapi"
"k8s.io/kubernetes/pkg/api/testapi"
...
@@ -86,13 +85,6 @@ func crdClientsetForToken(user string, config *restclient.Config) apiextensionsc
...
@@ -86,13 +85,6 @@ func crdClientsetForToken(user string, config *restclient.Config) apiextensionsc
return
apiextensionsclient
.
NewForConfigOrDie
(
&
configCopy
)
return
apiextensionsclient
.
NewForConfigOrDie
(
&
configCopy
)
}
}
func
csiClientsetForToken
(
user
string
,
config
*
restclient
.
Config
)
csiclientset
.
Interface
{
configCopy
:=
*
config
configCopy
.
BearerToken
=
user
configCopy
.
ContentType
=
"application/json"
// // csi client works with CRDs that support json only
return
csiclientset
.
NewForConfigOrDie
(
&
configCopy
)
}
type
testRESTOptionsGetter
struct
{
type
testRESTOptionsGetter
struct
{
config
*
master
.
Config
config
*
master
.
Config
}
}
...
...
test/integration/etcd/data.go
View file @
d69e0ff3
...
@@ -491,7 +491,7 @@ func GetEtcdStorageData() map[schema.GroupVersionResource]StorageData {
...
@@ -491,7 +491,7 @@ func GetEtcdStorageData() map[schema.GroupVersionResource]StorageData {
// add csinodes if CSINodeInfo feature gate is enabled
// add csinodes if CSINodeInfo feature gate is enabled
if
utilfeature
.
DefaultFeatureGate
.
Enabled
(
features
.
CSINodeInfo
)
{
if
utilfeature
.
DefaultFeatureGate
.
Enabled
(
features
.
CSINodeInfo
)
{
etcdStorageData
[
gvr
(
"storage.k8s.io"
,
"v1beta1"
,
"csinodes"
)]
=
StorageData
{
etcdStorageData
[
gvr
(
"storage.k8s.io"
,
"v1beta1"
,
"csinodes"
)]
=
StorageData
{
Stub
:
`{"metadata": {"name": "csini1"}, "spec": {"drivers": [{"name": "test-driver", "nodeID": "localhost", "topologyKeys": ["company.com/zone1", "company.com/zone2"]}]}`
,
Stub
:
`{"metadata": {"name": "csini1"}, "spec": {"drivers": [{"name": "test-driver", "nodeID": "localhost", "topologyKeys": ["company.com/zone1", "company.com/zone2"]}]}
}
`
,
ExpectedEtcdPath
:
"/registry/csinodes/csini1"
,
ExpectedEtcdPath
:
"/registry/csinodes/csini1"
,
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment