File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed
test/integration/models/lke Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change 88 Base ,
99 DerivedBase ,
1010 Instance ,
11+ InstanceDiskEncryptionType ,
1112 JSONObject ,
1213 MappedObject ,
1314 Property ,
@@ -422,6 +423,9 @@ def node_pool_create(
422423 ] = None ,
423424 update_strategy : Optional [str ] = None ,
424425 label : str = None ,
426+ disk_encryption : Optional [
427+ Union [str , InstanceDiskEncryptionType ]
428+ ] = None ,
425429 ** kwargs ,
426430 ):
427431 """
@@ -443,6 +447,9 @@ def node_pool_create(
443447 :param update_strategy: The strategy to use when updating this node pool.
444448 NOTE: This field is specific to enterprise clusters.
445449 :type update_strategy: str
450+ :param disk_encryption: Local disk encryption setting for this LKE node pool.
451+ One of 'enabled' or 'disabled'. Defaults to 'disabled'.
452+ :type disk_encryption: str or InstanceDiskEncryptionType
446453 :param kwargs: Any other arguments to pass to the API. See the API docs
447454 for possible values.
448455
@@ -459,6 +466,7 @@ def node_pool_create(
459466 "taints" : taints ,
460467 "k8s_version" : k8s_version ,
461468 "update_strategy" : update_strategy ,
469+ "disk_encryption" : disk_encryption ,
462470 }
463471 params .update (kwargs )
464472
Original file line number Diff line number Diff line change @@ -211,6 +211,21 @@ def _to_comparable(p: LKENodePool) -> Dict[str, Any]:
211211 )
212212
213213
214+ def test_node_pool_create_with_disk_encryption (test_linode_client , lke_cluster ):
215+ node_type = test_linode_client .linode .types ()[1 ]
216+
217+ pool = lke_cluster .node_pool_create (
218+ node_type ,
219+ 1 ,
220+ disk_encryption = InstanceDiskEncryptionType .enabled ,
221+ )
222+
223+ try :
224+ assert pool .disk_encryption == InstanceDiskEncryptionType .enabled
225+ finally :
226+ pool .delete ()
227+
228+
214229def test_cluster_dashboard_url_view (lke_cluster ):
215230 cluster = lke_cluster
216231
You can’t perform that action at this time.
0 commit comments