Skip to content

Commit 29ebf3c

Browse files
authored
sdk: rolling update for 0.11.34 (#230)
1 parent de7d0d6 commit 29ebf3c

File tree

47 files changed

+3473
-557
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+3473
-557
lines changed

ucloud/services/cube/client.py

+27
Original file line numberDiff line numberDiff line change
@@ -521,6 +521,33 @@ def modify_cube_tag(
521521
resp = self.invoke("ModifyCubeTag", d, **kwargs)
522522
return apis.ModifyCubeTagResponseSchema().loads(resp)
523523

524+
def reboot_cube_pod(
525+
self, req: typing.Optional[dict] = None, **kwargs
526+
) -> dict:
527+
"""RebootCubePod - 重启Cube Pod
528+
529+
**Request**
530+
531+
- **ProjectId** (str) - (Config) 项目ID。不填写为默认项目,子帐号必须填写。 请参考 `GetProjectList接口 <https://docs.ucloud.cn/api/summary/get_project_list>`_
532+
- **Region** (str) - (Config) 地域。 参见 `地域和可用区列表 <https://docs.ucloud.cn/api/summary/regionlist>`_
533+
- **CubeId** (str) - (Required) cube资源id(cube-xxxxxx)
534+
- **Zone** (str) - 可用区。参见 `可用区列表 <https://docs.ucloud.cn/api/summary/regionlist>`_
535+
536+
**Response**
537+
538+
539+
"""
540+
# build request
541+
d = {
542+
"ProjectId": self.config.project_id,
543+
"Region": self.config.region,
544+
}
545+
req and d.update(req)
546+
d = apis.RebootCubePodRequestSchema().dumps(d)
547+
548+
resp = self.invoke("RebootCubePod", d, **kwargs)
549+
return apis.RebootCubePodResponseSchema().loads(resp)
550+
524551
def renew_cube_pod(
525552
self, req: typing.Optional[dict] = None, **kwargs
526553
) -> dict:

ucloud/services/cube/schemas/apis.py

+24
Original file line numberDiff line numberDiff line change
@@ -446,6 +446,30 @@ class ModifyCubeTagResponseSchema(schema.ResponseSchema):
446446
}
447447

448448

449+
"""
450+
API: RebootCubePod
451+
452+
重启Cube Pod
453+
"""
454+
455+
456+
class RebootCubePodRequestSchema(schema.RequestSchema):
457+
"""RebootCubePod - 重启Cube Pod"""
458+
459+
fields = {
460+
"CubeId": fields.Str(required=True, dump_to="CubeId"),
461+
"ProjectId": fields.Str(required=False, dump_to="ProjectId"),
462+
"Region": fields.Str(required=True, dump_to="Region"),
463+
"Zone": fields.Str(required=False, dump_to="Zone"),
464+
}
465+
466+
467+
class RebootCubePodResponseSchema(schema.ResponseSchema):
468+
"""RebootCubePod - 重启Cube Pod"""
469+
470+
fields = {}
471+
472+
449473
"""
450474
API: RenewCubePod
451475

ucloud/services/ipsecvpn/client.py

+7-5
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,8 @@ def create_vpn_tunnel(
9494
9595
**Request**
9696
97-
- **ProjectId** (str) - (Config) 项目ID。不填写为默认项目,子帐号必须填写。 请参考 `GetProjectList接口 <https://docs.ucloud.cn/api/summary/get_project_list.html>`_
98-
- **Region** (str) - (Config) 地域。 参见 `地域和可用区列表 <https://docs.ucloud.cn/api/summary/regionlist.html>`_
97+
- **ProjectId** (str) - (Config) 项目ID。不填写为默认项目,子帐号必须填写。 请参考 `GetProjectList接口 <https://docs.ucloud.cn/api/summary/get_project_list>`_
98+
- **Region** (str) - (Config) 地域。 参见 `地域和可用区列表 <https://docs.ucloud.cn/api/summary/regionlist>`_
9999
- **IKEPreSharedKey** (str) - (Required) 预共享密钥
100100
- **IKEVersion** (str) - (Required) ike版本,枚举值: "IKE V1","IKE V2",默认v1
101101
- **IPSecLocalSubnetIds** (list) - (Required) 指定VPN连接的本地子网的资源ID,最多可填写10个。
@@ -111,7 +111,8 @@ def create_vpn_tunnel(
111111
- **IKELocalId** (str) - 本端标识。枚举值,自动识别,“auto”;IP地址或域名。默认为自动识别“auto”。IKEV2必填该参数
112112
- **IKERemoteId** (str) - 客户端标识。枚举值,自动识别,“auto”;IP地址或域名。默认为“自动识别“auto”。IKEV2必填该参数
113113
- **IKESALifetime** (str) - IKE中SA的生存时间,可填写范围为600-604800。默认为86400。
114-
- **IPSecAuthenticationAlgorithm** (str) - IPSec隧道中使用的认证算法,枚举值,"md5", "sha1"。默认值为“sha1”
114+
- **IPSecAuthenticationAlgorithm** (str) - IPSec隧道中使用的认证算法,枚举值,"md5", "sha1","sha2-256"。默认值为“sha1”
115+
- **IPSecCloseAction** (str) - IPSec隧道关闭后的处理动作,枚举值:“none”,流量触发;“restart”,自动重联,默认为none
115116
- **IPSecEncryptionAlgorithm** (str) - IPSec隧道中使用的加密算法,枚举值,"aes128", "aes192", "aes256", "aes512", "3des"。默认值为“aes128”
116117
- **IPSecPFSDhGroup** (str) - IPSec的PFS是否开启,枚举值,,不开启,"disable";数字表示DH组, "1", "2", "5", "14", "15", "16"。默认为“disable”。
117118
- **IPSecProtocol** (str) - 使用的安全协议,枚举值,“esp”,“ah”。默认为“esp”
@@ -483,8 +484,8 @@ def update_vpn_tunnel_attribute(
483484
484485
**Request**
485486
486-
- **ProjectId** (str) - (Config) 项目ID。不填写为默认项目,子帐号必须填写。 请参考 `GetProjectList接口 <https://docs.ucloud.cn/api/summary/get_project_list.html>`_
487-
- **Region** (str) - (Config) 地域。 参见 `地域和可用区列表 <https://docs.ucloud.cn/api/summary/regionlist.html>`_
487+
- **ProjectId** (str) - (Config) 项目ID。不填写为默认项目,子帐号必须填写。 请参考 `GetProjectList接口 <https://docs.ucloud.cn/api/summary/get_project_list>`_
488+
- **Region** (str) - (Config) 地域。 参见 `地域和可用区列表 <https://docs.ucloud.cn/api/summary/regionlist>`_
488489
- **VPNTunnelId** (str) - (Required) VPN隧道的资源ID
489490
- **IKEAuthenticationAlgorithm** (str) - IKE协商过程中使用的认证算法
490491
- **IKEDhGroup** (str) - IKE协商过程中使用的DH组
@@ -496,6 +497,7 @@ def update_vpn_tunnel_attribute(
496497
- **IKESALifetime** (str) - IKE中SA的生存时间
497498
- **IKEVersion** (str) - 枚举值:"IKE V1","IKE V2"
498499
- **IPSecAuthenticationAlgorithm** (str) - IPSec隧道中使用的认证算法
500+
- **IPSecCloseAction** (str) - IPSec隧道关闭后的处理动作,默认与原本一致,若原本为空,必传。枚举值:“none”,不处理(推荐为none,流量会自动触发隧道重建);“restart”重建
499501
- **IPSecEncryptionAlgorithm** (str) - IPSec隧道中使用的加密算法
500502
- **IPSecLocalSubnetIds** (list) - 指定VPN连接的本地子网的id,用逗号分隔
501503
- **IPSecPFSDhGroup** (str) - IPSec中的PFS是否开启

ucloud/services/ipsecvpn/schemas/apis.py

+6
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ class CreateVPNTunnelRequestSchema(schema.RequestSchema):
105105
"IPSecAuthenticationAlgorithm": fields.Str(
106106
required=False, dump_to="IPSecAuthenticationAlgorithm"
107107
),
108+
"IPSecCloseAction": fields.Str(
109+
required=False, dump_to="IPSecCloseAction"
110+
),
108111
"IPSecEncryptionAlgorithm": fields.Str(
109112
required=False, dump_to="IPSecEncryptionAlgorithm"
110113
),
@@ -423,6 +426,9 @@ class UpdateVPNTunnelAttributeRequestSchema(schema.RequestSchema):
423426
"IPSecAuthenticationAlgorithm": fields.Str(
424427
required=False, dump_to="IPSecAuthenticationAlgorithm"
425428
),
429+
"IPSecCloseAction": fields.Str(
430+
required=False, dump_to="IPSecCloseAction"
431+
),
426432
"IPSecEncryptionAlgorithm": fields.Str(
427433
required=False, dump_to="IPSecEncryptionAlgorithm"
428434
),

0 commit comments

Comments
 (0)