tccli 3.0.1036.1__py2.py3-none-any.whl → 3.0.1037.1__py2.py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- tccli/__init__.py +1 -1
- tccli/examples/cdc/v20201214/DescribeDedicatedClusterHosts.md +2 -0
- tccli/examples/cdc/v20201214/DescribeDedicatedClusterOverview.md +59 -7
- tccli/examples/cdwch/v20200915/DescribeInstanceNodes.md +41 -0
- tccli/examples/cdwch/v20200915/DescribeSpec.md +27 -20
- tccli/examples/cwp/v20180228/CreateMalwareWhiteList.md +10 -4
- tccli/examples/cwp/v20180228/DescribeMachineFileTamperRules.md +9 -8
- tccli/examples/cwp/v20180228/ModifyLoginWhiteRecord.md +11 -10
- tccli/examples/hai/v20230812/DescribeApplications.md +6 -2
- tccli/examples/mrs/v20200910/ImageMaskAsync.md +25 -0
- tccli/examples/mrs/v20200910/ImageMaskAsyncGetResult.md +21 -0
- tccli/examples/tcss/v20201101/DescribeAssetSuperNodeList.md +41 -0
- tccli/examples/tcss/v20201101/DescribeClusterNodes.md +42 -0
- tccli/examples/tcss/v20201101/DescribeSuperNodePodList.md +41 -0
- tccli/examples/tcss/v20201101/DescribeUserPodList.md +56 -0
- tccli/services/aa/aa_client.py +2 -1
- tccli/services/aai/aai_client.py +5 -4
- tccli/services/acp/acp_client.py +9 -8
- tccli/services/advisor/advisor_client.py +3 -2
- tccli/services/af/af_client.py +4 -3
- tccli/services/afc/afc_client.py +4 -3
- tccli/services/aiart/aiart_client.py +3 -2
- tccli/services/aiart/v20221229/api.json +3 -3
- tccli/services/ame/ame_client.py +32 -31
- tccli/services/ams/ams_client.py +10 -9
- tccli/services/anicloud/anicloud_client.py +4 -3
- tccli/services/antiddos/antiddos_client.py +96 -95
- tccli/services/apcas/apcas_client.py +8 -7
- tccli/services/ape/ape_client.py +9 -8
- tccli/services/api/api_client.py +4 -3
- tccli/services/apigateway/apigateway_client.py +97 -96
- tccli/services/apm/apm_client.py +10 -9
- tccli/services/asr/asr_client.py +26 -25
- tccli/services/asw/asw_client.py +10 -9
- tccli/services/autoscaling/autoscaling_client.py +58 -57
- tccli/services/ba/ba_client.py +4 -3
- tccli/services/batch/batch_client.py +32 -31
- tccli/services/bda/bda_client.py +19 -18
- tccli/services/bi/bi_client.py +23 -22
- tccli/services/billing/billing_client.py +33 -32
- tccli/services/bizlive/bizlive_client.py +7 -6
- tccli/services/bm/bm_client.py +54 -53
- tccli/services/bma/bma_client.py +38 -37
- tccli/services/bmeip/bmeip_client.py +21 -20
- tccli/services/bmlb/bmlb_client.py +50 -49
- tccli/services/bmvpc/bmvpc_client.py +62 -61
- tccli/services/bpaas/bpaas_client.py +3 -2
- tccli/services/bri/bri_client.py +2 -1
- tccli/services/bsca/bsca_client.py +8 -7
- tccli/services/btoe/btoe_client.py +15 -14
- tccli/services/cam/cam_client.py +88 -87
- tccli/services/captcha/captcha_client.py +19 -18
- tccli/services/car/car_client.py +7 -6
- tccli/services/cat/cat_client.py +13 -12
- tccli/services/cbs/cbs_client.py +42 -41
- tccli/services/ccc/ccc_client.py +42 -41
- tccli/services/cdb/cdb_client.py +159 -158
- tccli/services/cdc/cdc_client.py +21 -20
- tccli/services/cdc/v20201214/api.json +110 -24
- tccli/services/cdc/v20201214/examples.json +2 -2
- tccli/services/cdn/cdn_client.py +82 -81
- tccli/services/cdn/v20180606/api.json +10 -1
- tccli/services/cds/cds_client.py +7 -6
- tccli/services/cdwch/cdwch_client.py +109 -55
- tccli/services/cdwch/v20200915/api.json +253 -3
- tccli/services/cdwch/v20200915/examples.json +10 -2
- tccli/services/cdwdoris/cdwdoris_client.py +18 -17
- tccli/services/cdwpg/cdwpg_client.py +9 -8
- tccli/services/cfg/cfg_client.py +13 -12
- tccli/services/cfs/cfs_client.py +44 -43
- tccli/services/cfw/cfw_client.py +112 -111
- tccli/services/chdfs/chdfs_client.py +30 -29
- tccli/services/ciam/ciam_client.py +24 -23
- tccli/services/cii/cii_client.py +14 -13
- tccli/services/cim/cim_client.py +2 -1
- tccli/services/cis/cis_client.py +8 -7
- tccli/services/ckafka/ckafka_client.py +82 -81
- tccli/services/clb/clb_client.py +86 -85
- tccli/services/cloudaudit/cloudaudit_client.py +20 -19
- tccli/services/cloudhsm/cloudhsm_client.py +15 -14
- tccli/services/cloudstudio/cloudstudio_client.py +10 -9
- tccli/services/cls/cls_client.py +90 -89
- tccli/services/cme/cme_client.py +51 -50
- tccli/services/cmq/cmq_client.py +18 -17
- tccli/services/cms/cms_client.py +7 -6
- tccli/services/config/config_client.py +4 -3
- tccli/services/cpdp/cpdp_client.py +220 -219
- tccli/services/cr/cr_client.py +29 -28
- tccli/services/csip/csip_client.py +35 -34
- tccli/services/csxg/csxg_client.py +6 -5
- tccli/services/cvm/cvm_client.py +95 -94
- tccli/services/cwp/cwp_client.py +519 -518
- tccli/services/cwp/v20180228/api.json +17 -16
- tccli/services/cwp/v20180228/examples.json +5 -5
- tccli/services/cws/cws_client.py +20 -19
- tccli/services/cynosdb/cynosdb_client.py +131 -130
- tccli/services/dasb/dasb_client.py +56 -55
- tccli/services/dataintegration/dataintegration_client.py +2 -1
- tccli/services/dayu/dayu_client.py +113 -112
- tccli/services/dbbrain/dbbrain_client.py +62 -61
- tccli/services/dbdc/dbdc_client.py +7 -6
- tccli/services/dc/dc_client.py +22 -21
- tccli/services/dcdb/dcdb_client.py +74 -73
- tccli/services/dlc/dlc_client.py +124 -123
- tccli/services/dnspod/dnspod_client.py +73 -72
- tccli/services/domain/domain_client.py +34 -33
- tccli/services/drm/drm_client.py +12 -11
- tccli/services/ds/ds_client.py +13 -12
- tccli/services/dsgc/dsgc_client.py +149 -148
- tccli/services/dtf/dtf_client.py +2 -1
- tccli/services/dts/dts_client.py +69 -68
- tccli/services/dts/v20211206/api.json +1 -0
- tccli/services/eb/eb_client.py +33 -32
- tccli/services/ecc/ecc_client.py +5 -4
- tccli/services/ecdn/ecdn_client.py +17 -16
- tccli/services/ecm/ecm_client.py +140 -139
- tccli/services/eiam/eiam_client.py +43 -42
- tccli/services/eis/eis_client.py +9 -8
- tccli/services/emr/emr_client.py +36 -35
- tccli/services/es/es_client.py +43 -42
- tccli/services/ess/ess_client.py +72 -71
- tccli/services/ess/v20201111/api.json +2 -2
- tccli/services/essbasic/essbasic_client.py +123 -122
- tccli/services/essbasic/v20210526/api.json +11 -11
- tccli/services/facefusion/facefusion_client.py +5 -4
- tccli/services/faceid/faceid_client.py +36 -35
- tccli/services/fmu/fmu_client.py +11 -10
- tccli/services/ft/ft_client.py +7 -6
- tccli/services/gaap/gaap_client.py +104 -103
- tccli/services/gme/gme_client.py +29 -28
- tccli/services/goosefs/goosefs_client.py +21 -20
- tccli/services/gpm/gpm_client.py +19 -18
- tccli/services/gs/gs_client.py +9 -8
- tccli/services/gse/gse_client.py +75 -74
- tccli/services/habo/habo_client.py +3 -2
- tccli/services/hai/hai_client.py +12 -11
- tccli/services/hai/v20230812/api.json +59 -1
- tccli/services/hai/v20230812/examples.json +1 -1
- tccli/services/hasim/hasim_client.py +23 -22
- tccli/services/hcm/hcm_client.py +2 -1
- tccli/services/hunyuan/hunyuan_client.py +4 -3
- tccli/services/iai/iai_client.py +36 -35
- tccli/services/ic/ic_client.py +10 -9
- tccli/services/icr/icr_client.py +2 -1
- tccli/services/ie/ie_client.py +11 -10
- tccli/services/iecp/iecp_client.py +103 -102
- tccli/services/iir/iir_client.py +2 -1
- tccli/services/ims/ims_client.py +3 -2
- tccli/services/ioa/ioa_client.py +2 -1
- tccli/services/iot/iot_client.py +46 -45
- tccli/services/iotcloud/iotcloud_client.py +86 -85
- tccli/services/iotexplorer/iotexplorer_client.py +93 -92
- tccli/services/iottid/iottid_client.py +10 -9
- tccli/services/iotvideo/iotvideo_client.py +158 -157
- tccli/services/iotvideoindustry/iotvideoindustry_client.py +105 -104
- tccli/services/irp/irp_client.py +12 -11
- tccli/services/iss/iss_client.py +83 -82
- tccli/services/ivld/ivld_client.py +26 -25
- tccli/services/keewidb/keewidb_client.py +39 -38
- tccli/services/kms/kms_client.py +54 -53
- tccli/services/lcic/lcic_client.py +61 -60
- tccli/services/lighthouse/lighthouse_client.py +108 -107
- tccli/services/lighthouse/v20200324/api.json +1 -1
- tccli/services/live/live_client.py +154 -153
- tccli/services/lowcode/lowcode_client.py +2 -1
- tccli/services/lp/lp_client.py +2 -1
- tccli/services/mall/mall_client.py +2 -1
- tccli/services/mariadb/mariadb_client.py +73 -72
- tccli/services/market/market_client.py +3 -2
- tccli/services/memcached/memcached_client.py +2 -1
- tccli/services/mgobe/mgobe_client.py +8 -7
- tccli/services/mmps/mmps_client.py +16 -15
- tccli/services/mna/mna_client.py +24 -23
- tccli/services/mongodb/mongodb_client.py +43 -42
- tccli/services/monitor/monitor_client.py +151 -150
- tccli/services/mps/mps_client.py +101 -100
- tccli/services/mrs/mrs_client.py +115 -8
- tccli/services/mrs/v20200910/api.json +97 -0
- tccli/services/mrs/v20200910/examples.json +16 -0
- tccli/services/ms/ms_client.py +24 -23
- tccli/services/msp/msp_client.py +8 -7
- tccli/services/mvj/mvj_client.py +2 -1
- tccli/services/nlp/nlp_client.py +13 -12
- tccli/services/npp/npp_client.py +9 -8
- tccli/services/oceanus/oceanus_client.py +39 -38
- tccli/services/oceanus/v20190422/api.json +4 -4
- tccli/services/ocr/ocr_client.py +82 -81
- tccli/services/omics/omics_client.py +16 -15
- tccli/services/organization/organization_client.py +48 -47
- tccli/services/partners/partners_client.py +20 -19
- tccli/services/pds/pds_client.py +3 -2
- tccli/services/postgres/postgres_client.py +91 -90
- tccli/services/privatedns/privatedns_client.py +26 -25
- tccli/services/pts/pts_client.py +45 -44
- tccli/services/rce/rce_client.py +4 -3
- tccli/services/redis/redis_client.py +96 -95
- tccli/services/region/region_client.py +4 -3
- tccli/services/rkp/rkp_client.py +4 -3
- tccli/services/rp/rp_client.py +2 -1
- tccli/services/rum/rum_client.py +66 -65
- tccli/services/scf/scf_client.py +47 -46
- tccli/services/ses/ses_client.py +28 -27
- tccli/services/smh/smh_client.py +11 -10
- tccli/services/smop/smop_client.py +2 -1
- tccli/services/smpn/smpn_client.py +6 -5
- tccli/services/sms/sms_client.py +19 -18
- tccli/services/soe/soe_client.py +5 -4
- tccli/services/solar/solar_client.py +18 -17
- tccli/services/sqlserver/sqlserver_client.py +145 -144
- tccli/services/ssa/ssa_client.py +24 -23
- tccli/services/ssl/ssl_client.py +58 -57
- tccli/services/sslpod/sslpod_client.py +11 -10
- tccli/services/ssm/ssm_client.py +25 -24
- tccli/services/sts/sts_client.py +7 -6
- tccli/services/taf/taf_client.py +4 -3
- tccli/services/tag/tag_client.py +32 -31
- tccli/services/tan/tan_client.py +2 -1
- tccli/services/tat/tat_client.py +29 -28
- tccli/services/tav/tav_client.py +5 -4
- tccli/services/tbaas/tbaas_client.py +26 -25
- tccli/services/tbm/tbm_client.py +10 -9
- tccli/services/tbp/tbp_client.py +5 -4
- tccli/services/tcaplusdb/tcaplusdb_client.py +54 -53
- tccli/services/tcb/tcb_client.py +90 -89
- tccli/services/tcbr/tcbr_client.py +11 -10
- tccli/services/tcex/tcex_client.py +3 -2
- tccli/services/tchd/tchd_client.py +2 -1
- tccli/services/tci/tci_client.py +42 -41
- tccli/services/tcm/tcm_client.py +13 -12
- tccli/services/tcr/tcr_client.py +110 -109
- tccli/services/tcss/tcss_client.py +558 -345
- tccli/services/tcss/v20201101/api.json +1200 -0
- tccli/services/tcss/v20201101/examples.json +32 -0
- tccli/services/tdcpg/tdcpg_client.py +26 -25
- tccli/services/tdid/tdid_client.py +14 -13
- tccli/services/tdmq/tdmq_client.py +128 -127
- tccli/services/tds/tds_client.py +5 -4
- tccli/services/tem/tem_client.py +61 -60
- tccli/services/teo/teo_client.py +79 -78
- tccli/services/thpc/thpc_client.py +19 -18
- tccli/services/tia/tia_client.py +11 -10
- tccli/services/tic/tic_client.py +14 -13
- tccli/services/ticm/ticm_client.py +4 -3
- tccli/services/tics/tics_client.py +5 -4
- tccli/services/tiems/tiems_client.py +26 -25
- tccli/services/tiia/tiia_client.py +24 -23
- tccli/services/tione/tione_client.py +98 -97
- tccli/services/tiw/tiw_client.py +61 -60
- tccli/services/tke/tke_client.py +219 -218
- tccli/services/tkgdq/tkgdq_client.py +4 -3
- tccli/services/tms/tms_client.py +6 -5
- tccli/services/tmt/tmt_client.py +8 -7
- tccli/services/tourism/tourism_client.py +2 -1
- tccli/services/trdp/trdp_client.py +2 -1
- tccli/services/trocket/trocket_client.py +23 -22
- tccli/services/trp/trp_client.py +54 -53
- tccli/services/trro/trro_client.py +24 -23
- tccli/services/trtc/trtc_client.py +44 -43
- tccli/services/tse/tse_client.py +66 -65
- tccli/services/tsf/tsf_client.py +220 -219
- tccli/services/tsw/tsw_client.py +5 -4
- tccli/services/tts/tts_client.py +4 -3
- tccli/services/ump/ump_client.py +18 -17
- tccli/services/vm/vm_client.py +7 -6
- tccli/services/vms/vms_client.py +3 -2
- tccli/services/vod/vod_client.py +169 -168
- tccli/services/vpc/vpc_client.py +317 -316
- tccli/services/vrs/vrs_client.py +8 -7
- tccli/services/waf/waf_client.py +133 -132
- tccli/services/wav/wav_client.py +27 -26
- tccli/services/wedata/wedata_client.py +319 -318
- tccli/services/weilingwith/weilingwith_client.py +58 -57
- tccli/services/wss/wss_client.py +4 -3
- tccli/services/yinsuda/yinsuda_client.py +21 -20
- tccli/services/youmall/youmall_client.py +32 -31
- tccli/services/yunjing/yunjing_client.py +101 -100
- tccli/services/yunsou/yunsou_client.py +3 -2
- {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/RECORD +282 -275
- {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/license_files/LICENSE +0 -0
@@ -29,7 +29,7 @@ def doDescribeOtaVersions(args, parsed_globals):
|
|
29
29
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
30
30
|
cred = credential.STSAssumeRoleCredential(
|
31
31
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
32
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
32
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
33
33
|
)
|
34
34
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
35
35
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -81,7 +81,7 @@ def doCallTRTCDevice(args, parsed_globals):
|
|
81
81
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
82
82
|
cred = credential.STSAssumeRoleCredential(
|
83
83
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
84
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
84
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
85
85
|
)
|
86
86
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
87
87
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -133,7 +133,7 @@ def doDescribeDevicePackages(args, parsed_globals):
|
|
133
133
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
134
134
|
cred = credential.STSAssumeRoleCredential(
|
135
135
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
136
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
136
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
137
137
|
)
|
138
138
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
139
139
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -185,7 +185,7 @@ def doDescribeIotDataType(args, parsed_globals):
|
|
185
185
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
186
186
|
cred = credential.STSAssumeRoleCredential(
|
187
187
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
188
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
188
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
189
189
|
)
|
190
190
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
191
191
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -237,7 +237,7 @@ def doCreateAIDetection(args, parsed_globals):
|
|
237
237
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
238
238
|
cred = credential.STSAssumeRoleCredential(
|
239
239
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
240
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
240
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
241
241
|
)
|
242
242
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
243
243
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -289,7 +289,7 @@ def doDeleteTraceIds(args, parsed_globals):
|
|
289
289
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
290
290
|
cred = credential.STSAssumeRoleCredential(
|
291
291
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
292
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
292
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
293
293
|
)
|
294
294
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
295
295
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -341,7 +341,7 @@ def doDescribeAIModels(args, parsed_globals):
|
|
341
341
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
342
342
|
cred = credential.STSAssumeRoleCredential(
|
343
343
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
344
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
344
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
345
345
|
)
|
346
346
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
347
347
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -393,7 +393,7 @@ def doDescribeAIModelApplications(args, parsed_globals):
|
|
393
393
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
394
394
|
cred = credential.STSAssumeRoleCredential(
|
395
395
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
396
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
396
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
397
397
|
)
|
398
398
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
399
399
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -445,7 +445,7 @@ def doDescribeProduct(args, parsed_globals):
|
|
445
445
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
446
446
|
cred = credential.STSAssumeRoleCredential(
|
447
447
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
448
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
448
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
449
449
|
)
|
450
450
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
451
451
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -497,7 +497,7 @@ def doGetAllFirmwareVersion(args, parsed_globals):
|
|
497
497
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
498
498
|
cred = credential.STSAssumeRoleCredential(
|
499
499
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
500
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
500
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
501
501
|
)
|
502
502
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
503
503
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -549,7 +549,7 @@ def doDescribeProducts(args, parsed_globals):
|
|
549
549
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
550
550
|
cred = credential.STSAssumeRoleCredential(
|
551
551
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
552
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
552
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
553
553
|
)
|
554
554
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
555
555
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -601,7 +601,7 @@ def doDescribeUser(args, parsed_globals):
|
|
601
601
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
602
602
|
cred = credential.STSAssumeRoleCredential(
|
603
603
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
604
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
604
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
605
605
|
)
|
606
606
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
607
607
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -653,7 +653,7 @@ def doDescribeFirmwareTaskStatistics(args, parsed_globals):
|
|
653
653
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
654
654
|
cred = credential.STSAssumeRoleCredential(
|
655
655
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
656
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
656
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
657
657
|
)
|
658
658
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
659
659
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -705,7 +705,7 @@ def doCreateAppUsr(args, parsed_globals):
|
|
705
705
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
706
706
|
cred = credential.STSAssumeRoleCredential(
|
707
707
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
708
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
708
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
709
709
|
)
|
710
710
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
711
711
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -757,7 +757,7 @@ def doCallDeviceActionSync(args, parsed_globals):
|
|
757
757
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
758
758
|
cred = credential.STSAssumeRoleCredential(
|
759
759
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
760
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
760
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
761
761
|
)
|
762
762
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
763
763
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -809,7 +809,7 @@ def doCreateDevToken(args, parsed_globals):
|
|
809
809
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
810
810
|
cred = credential.STSAssumeRoleCredential(
|
811
811
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
812
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
812
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
813
813
|
)
|
814
814
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
815
815
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -861,7 +861,7 @@ def doModifyPushChannel(args, parsed_globals):
|
|
861
861
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
862
862
|
cred = credential.STSAssumeRoleCredential(
|
863
863
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
864
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
864
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
865
865
|
)
|
866
866
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
867
867
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -913,7 +913,7 @@ def doGenerateSignedVideoURL(args, parsed_globals):
|
|
913
913
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
914
914
|
cred = credential.STSAssumeRoleCredential(
|
915
915
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
916
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
916
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
917
917
|
)
|
918
918
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
919
919
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -965,7 +965,7 @@ def doEditFirmware(args, parsed_globals):
|
|
965
965
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
966
966
|
cred = credential.STSAssumeRoleCredential(
|
967
967
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
968
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
968
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
969
969
|
)
|
970
970
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
971
971
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1017,7 +1017,7 @@ def doPublishMessage(args, parsed_globals):
|
|
1017
1017
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1018
1018
|
cred = credential.STSAssumeRoleCredential(
|
1019
1019
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1020
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1020
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1021
1021
|
)
|
1022
1022
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1023
1023
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1069,7 +1069,7 @@ def doDescribeDeviceEventHistory(args, parsed_globals):
|
|
1069
1069
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1070
1070
|
cred = credential.STSAssumeRoleCredential(
|
1071
1071
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1072
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1072
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1073
1073
|
)
|
1074
1074
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1075
1075
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1121,7 +1121,7 @@ def doDescribeBatch(args, parsed_globals):
|
|
1121
1121
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1122
1122
|
cred = credential.STSAssumeRoleCredential(
|
1123
1123
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1124
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1124
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1125
1125
|
)
|
1126
1126
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1127
1127
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1173,7 +1173,7 @@ def doImportModelDefinition(args, parsed_globals):
|
|
1173
1173
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1174
1174
|
cred = credential.STSAssumeRoleCredential(
|
1175
1175
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1176
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1176
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1177
1177
|
)
|
1178
1178
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1179
1179
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1225,7 +1225,7 @@ def doDescribeStream(args, parsed_globals):
|
|
1225
1225
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1226
1226
|
cred = credential.STSAssumeRoleCredential(
|
1227
1227
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1228
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1228
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1229
1229
|
)
|
1230
1230
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1231
1231
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1277,7 +1277,7 @@ def doDescribeCloudStorageThumbnailList(args, parsed_globals):
|
|
1277
1277
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1278
1278
|
cred = credential.STSAssumeRoleCredential(
|
1279
1279
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1280
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1280
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1281
1281
|
)
|
1282
1282
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1283
1283
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1329,7 +1329,7 @@ def doCancelDeviceFirmwareTask(args, parsed_globals):
|
|
1329
1329
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1330
1330
|
cred = credential.STSAssumeRoleCredential(
|
1331
1331
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1332
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1332
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1333
1333
|
)
|
1334
1334
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1335
1335
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1381,7 +1381,7 @@ def doReportAliveDevice(args, parsed_globals):
|
|
1381
1381
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1382
1382
|
cred = credential.STSAssumeRoleCredential(
|
1383
1383
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1384
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1384
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1385
1385
|
)
|
1386
1386
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1387
1387
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1433,7 +1433,7 @@ def doDescribeForwardRule(args, parsed_globals):
|
|
1433
1433
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1434
1434
|
cred = credential.STSAssumeRoleCredential(
|
1435
1435
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1436
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1436
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1437
1437
|
)
|
1438
1438
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1439
1439
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1485,7 +1485,7 @@ def doDescribePubVersions(args, parsed_globals):
|
|
1485
1485
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1486
1486
|
cred = credential.STSAssumeRoleCredential(
|
1487
1487
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1488
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1488
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1489
1489
|
)
|
1490
1490
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1491
1491
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1537,7 +1537,7 @@ def doRunDeviceStream(args, parsed_globals):
|
|
1537
1537
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1538
1538
|
cred = credential.STSAssumeRoleCredential(
|
1539
1539
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1540
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1540
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1541
1541
|
)
|
1542
1542
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1543
1543
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1589,7 +1589,7 @@ def doDescribePackageConsumeTasks(args, parsed_globals):
|
|
1589
1589
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1590
1590
|
cred = credential.STSAssumeRoleCredential(
|
1591
1591
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1592
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1592
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1593
1593
|
)
|
1594
1594
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1595
1595
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1641,7 +1641,7 @@ def doDescribeAccount(args, parsed_globals):
|
|
1641
1641
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1642
1642
|
cred = credential.STSAssumeRoleCredential(
|
1643
1643
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1644
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1644
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1645
1645
|
)
|
1646
1646
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1647
1647
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1693,7 +1693,7 @@ def doModifyVerContent(args, parsed_globals):
|
|
1693
1693
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1694
1694
|
cred = credential.STSAssumeRoleCredential(
|
1695
1695
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1696
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1696
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1697
1697
|
)
|
1698
1698
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1699
1699
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1745,7 +1745,7 @@ def doDescribeCloudStoragePackageConsumeStats(args, parsed_globals):
|
|
1745
1745
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1746
1746
|
cred = credential.STSAssumeRoleCredential(
|
1747
1747
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1748
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1748
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1749
1749
|
)
|
1750
1750
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1751
1751
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1797,7 +1797,7 @@ def doCreateGencode(args, parsed_globals):
|
|
1797
1797
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1798
1798
|
cred = credential.STSAssumeRoleCredential(
|
1799
1799
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1800
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1800
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1801
1801
|
)
|
1802
1802
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1803
1803
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1849,7 +1849,7 @@ def doDescribeDeviceModel(args, parsed_globals):
|
|
1849
1849
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1850
1850
|
cred = credential.STSAssumeRoleCredential(
|
1851
1851
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1852
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1852
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1853
1853
|
)
|
1854
1854
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1855
1855
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1901,7 +1901,7 @@ def doCreateStorage(args, parsed_globals):
|
|
1901
1901
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1902
1902
|
cred = credential.STSAssumeRoleCredential(
|
1903
1903
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1904
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1904
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1905
1905
|
)
|
1906
1906
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1907
1907
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -1953,7 +1953,7 @@ def doDescribeFirmwareTasks(args, parsed_globals):
|
|
1953
1953
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1954
1954
|
cred = credential.STSAssumeRoleCredential(
|
1955
1955
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1956
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1956
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1957
1957
|
)
|
1958
1958
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1959
1959
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2005,7 +2005,7 @@ def doDescribeTraceIds(args, parsed_globals):
|
|
2005
2005
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2006
2006
|
cred = credential.STSAssumeRoleCredential(
|
2007
2007
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2008
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2008
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2009
2009
|
)
|
2010
2010
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2011
2011
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2057,7 +2057,7 @@ def doDeleteMessageQueue(args, parsed_globals):
|
|
2057
2057
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2058
2058
|
cred = credential.STSAssumeRoleCredential(
|
2059
2059
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2060
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2060
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2061
2061
|
)
|
2062
2062
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2063
2063
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2109,7 +2109,7 @@ def doControlDeviceData(args, parsed_globals):
|
|
2109
2109
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2110
2110
|
cred = credential.STSAssumeRoleCredential(
|
2111
2111
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2112
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2112
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2113
2113
|
)
|
2114
2114
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2115
2115
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2161,7 +2161,7 @@ def doUpgradeDevice(args, parsed_globals):
|
|
2161
2161
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2162
2162
|
cred = credential.STSAssumeRoleCredential(
|
2163
2163
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2164
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2164
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2165
2165
|
)
|
2166
2166
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2167
2167
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2213,7 +2213,7 @@ def doModifyDeviceLogLevel(args, parsed_globals):
|
|
2213
2213
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2214
2214
|
cred = credential.STSAssumeRoleCredential(
|
2215
2215
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2216
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2216
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2217
2217
|
)
|
2218
2218
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2219
2219
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2265,7 +2265,7 @@ def doDescribeFirmware(args, parsed_globals):
|
|
2265
2265
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2266
2266
|
cred = credential.STSAssumeRoleCredential(
|
2267
2267
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2268
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2268
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2269
2269
|
)
|
2270
2270
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2271
2271
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2317,7 +2317,7 @@ def doDescribeCloudStorageDate(args, parsed_globals):
|
|
2317
2317
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2318
2318
|
cred = credential.STSAssumeRoleCredential(
|
2319
2319
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2320
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2320
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2321
2321
|
)
|
2322
2322
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2323
2323
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2369,7 +2369,7 @@ def doResetCloudStorageEvent(args, parsed_globals):
|
|
2369
2369
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2370
2370
|
cred = credential.STSAssumeRoleCredential(
|
2371
2371
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2372
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2372
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2373
2373
|
)
|
2374
2374
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2375
2375
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2421,7 +2421,7 @@ def doDescribeCloudStorageUsers(args, parsed_globals):
|
|
2421
2421
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2422
2422
|
cred = credential.STSAssumeRoleCredential(
|
2423
2423
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2424
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2424
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2425
2425
|
)
|
2426
2426
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2427
2427
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2473,7 +2473,7 @@ def doTransferCloudStorage(args, parsed_globals):
|
|
2473
2473
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2474
2474
|
cred = credential.STSAssumeRoleCredential(
|
2475
2475
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2476
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2476
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2477
2477
|
)
|
2478
2478
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2479
2479
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2525,7 +2525,7 @@ def doRetryDeviceFirmwareTask(args, parsed_globals):
|
|
2525
2525
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2526
2526
|
cred = credential.STSAssumeRoleCredential(
|
2527
2527
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2528
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2528
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2529
2529
|
)
|
2530
2530
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2531
2531
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2577,7 +2577,7 @@ def doModifyDevice(args, parsed_globals):
|
|
2577
2577
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2578
2578
|
cred = credential.STSAssumeRoleCredential(
|
2579
2579
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2580
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2580
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2581
2581
|
)
|
2582
2582
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2583
2583
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2629,7 +2629,7 @@ def doModifyDataForward(args, parsed_globals):
|
|
2629
2629
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2630
2630
|
cred = credential.STSAssumeRoleCredential(
|
2631
2631
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2632
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2632
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2633
2633
|
)
|
2634
2634
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2635
2635
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2681,7 +2681,7 @@ def doBatchUpdateFirmware(args, parsed_globals):
|
|
2681
2681
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2682
2682
|
cred = credential.STSAssumeRoleCredential(
|
2683
2683
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2684
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2684
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2685
2685
|
)
|
2686
2686
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2687
2687
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2733,7 +2733,7 @@ def doCreateProduct(args, parsed_globals):
|
|
2733
2733
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2734
2734
|
cred = credential.STSAssumeRoleCredential(
|
2735
2735
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2736
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2736
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2737
2737
|
)
|
2738
2738
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2739
2739
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2785,7 +2785,7 @@ def doSetMessageQueue(args, parsed_globals):
|
|
2785
2785
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2786
2786
|
cred = credential.STSAssumeRoleCredential(
|
2787
2787
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2788
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2788
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2789
2789
|
)
|
2790
2790
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2791
2791
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2837,7 +2837,7 @@ def doDeleteIotDataType(args, parsed_globals):
|
|
2837
2837
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2838
2838
|
cred = credential.STSAssumeRoleCredential(
|
2839
2839
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2840
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2840
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2841
2841
|
)
|
2842
2842
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2843
2843
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2889,7 +2889,7 @@ def doDisableOtaVersion(args, parsed_globals):
|
|
2889
2889
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2890
2890
|
cred = credential.STSAssumeRoleCredential(
|
2891
2891
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2892
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2892
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2893
2893
|
)
|
2894
2894
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2895
2895
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2941,7 +2941,7 @@ def doInheritCloudStorageUser(args, parsed_globals):
|
|
2941
2941
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2942
2942
|
cred = credential.STSAssumeRoleCredential(
|
2943
2943
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2944
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2944
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2945
2945
|
)
|
2946
2946
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2947
2947
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -2993,7 +2993,7 @@ def doDescribeBindUsr(args, parsed_globals):
|
|
2993
2993
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2994
2994
|
cred = credential.STSAssumeRoleCredential(
|
2995
2995
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2996
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2996
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2997
2997
|
)
|
2998
2998
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2999
2999
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3045,7 +3045,7 @@ def doGetFirmwareURL(args, parsed_globals):
|
|
3045
3045
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3046
3046
|
cred = credential.STSAssumeRoleCredential(
|
3047
3047
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3048
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3048
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3049
3049
|
)
|
3050
3050
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3051
3051
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3097,7 +3097,7 @@ def doDeleteOtaVersion(args, parsed_globals):
|
|
3097
3097
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3098
3098
|
cred = credential.STSAssumeRoleCredential(
|
3099
3099
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3100
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3100
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3101
3101
|
)
|
3102
3102
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3103
3103
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3149,7 +3149,7 @@ def doDescribeDeviceCommLog(args, parsed_globals):
|
|
3149
3149
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3150
3150
|
cred = credential.STSAssumeRoleCredential(
|
3151
3151
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3152
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3152
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3153
3153
|
)
|
3154
3154
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3155
3155
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3201,7 +3201,7 @@ def doListFirmwares(args, parsed_globals):
|
|
3201
3201
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3202
3202
|
cred = credential.STSAssumeRoleCredential(
|
3203
3203
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3204
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3204
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3205
3205
|
)
|
3206
3206
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3207
3207
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3253,7 +3253,7 @@ def doDescribeCategory(args, parsed_globals):
|
|
3253
3253
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3254
3254
|
cred = credential.STSAssumeRoleCredential(
|
3255
3255
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3256
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3256
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3257
3257
|
)
|
3258
3258
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3259
3259
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3305,7 +3305,7 @@ def doRefundStorageService(args, parsed_globals):
|
|
3305
3305
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3306
3306
|
cred = credential.STSAssumeRoleCredential(
|
3307
3307
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3308
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3308
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3309
3309
|
)
|
3310
3310
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3311
3311
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3357,7 +3357,7 @@ def doDeleteProduct(args, parsed_globals):
|
|
3357
3357
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3358
3358
|
cred = credential.STSAssumeRoleCredential(
|
3359
3359
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3360
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3360
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3361
3361
|
)
|
3362
3362
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3363
3363
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3409,7 +3409,7 @@ def doModifyDataForwardStatus(args, parsed_globals):
|
|
3409
3409
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3410
3410
|
cred = credential.STSAssumeRoleCredential(
|
3411
3411
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3412
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3412
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3413
3413
|
)
|
3414
3414
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3415
3415
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3461,7 +3461,7 @@ def doDescribeFirmwareTask(args, parsed_globals):
|
|
3461
3461
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3462
3462
|
cred = credential.STSAssumeRoleCredential(
|
3463
3463
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3464
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3464
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3465
3465
|
)
|
3466
3466
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3467
3467
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3513,7 +3513,7 @@ def doResetCloudStorage(args, parsed_globals):
|
|
3513
3513
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3514
3514
|
cred = credential.STSAssumeRoleCredential(
|
3515
3515
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3516
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3516
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3517
3517
|
)
|
3518
3518
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3519
3519
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3565,7 +3565,7 @@ def doDescribeRegistrationStatus(args, parsed_globals):
|
|
3565
3565
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3566
3566
|
cred = credential.STSAssumeRoleCredential(
|
3567
3567
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3568
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3568
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3569
3569
|
)
|
3570
3570
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3571
3571
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3617,7 +3617,7 @@ def doDescribeFirmwareTaskDevices(args, parsed_globals):
|
|
3617
3617
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3618
3618
|
cred = credential.STSAssumeRoleCredential(
|
3619
3619
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3620
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3620
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3621
3621
|
)
|
3622
3622
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3623
3623
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3669,7 +3669,7 @@ def doDescribeStorageService(args, parsed_globals):
|
|
3669
3669
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3670
3670
|
cred = credential.STSAssumeRoleCredential(
|
3671
3671
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3672
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3672
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3673
3673
|
)
|
3674
3674
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3675
3675
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3721,7 +3721,7 @@ def doDescribeDataForwardList(args, parsed_globals):
|
|
3721
3721
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3722
3722
|
cred = credential.STSAssumeRoleCredential(
|
3723
3723
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3724
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3724
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3725
3725
|
)
|
3726
3726
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3727
3727
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3773,7 +3773,7 @@ def doDescribeCloudStorageTime(args, parsed_globals):
|
|
3773
3773
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3774
3774
|
cred = credential.STSAssumeRoleCredential(
|
3775
3775
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3776
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3776
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3777
3777
|
)
|
3778
3778
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3779
3779
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3825,7 +3825,7 @@ def doUpdateAIModelChannel(args, parsed_globals):
|
|
3825
3825
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3826
3826
|
cred = credential.STSAssumeRoleCredential(
|
3827
3827
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3828
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3828
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3829
3829
|
)
|
3830
3830
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3831
3831
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3877,7 +3877,7 @@ def doDescribeCloudStorageThumbnail(args, parsed_globals):
|
|
3877
3877
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3878
3878
|
cred = credential.STSAssumeRoleCredential(
|
3879
3879
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3880
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3880
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3881
3881
|
)
|
3882
3882
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3883
3883
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3929,7 +3929,7 @@ def doDeleteFirmware(args, parsed_globals):
|
|
3929
3929
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3930
3930
|
cred = credential.STSAssumeRoleCredential(
|
3931
3931
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3932
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3932
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3933
3933
|
)
|
3934
3934
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3935
3935
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -3981,7 +3981,7 @@ def doCallDeviceActionAsync(args, parsed_globals):
|
|
3981
3981
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3982
3982
|
cred = credential.STSAssumeRoleCredential(
|
3983
3983
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3984
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
3984
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3985
3985
|
)
|
3986
3986
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
3987
3987
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4033,7 +4033,7 @@ def doRunDevice(args, parsed_globals):
|
|
4033
4033
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4034
4034
|
cred = credential.STSAssumeRoleCredential(
|
4035
4035
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4036
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4036
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4037
4037
|
)
|
4038
4038
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4039
4039
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4085,7 +4085,7 @@ def doUploadOtaVersion(args, parsed_globals):
|
|
4085
4085
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4086
4086
|
cred = credential.STSAssumeRoleCredential(
|
4087
4087
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4088
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4088
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4089
4089
|
)
|
4090
4090
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4091
4091
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4137,7 +4137,7 @@ def doCreateUsrToken(args, parsed_globals):
|
|
4137
4137
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4138
4138
|
cred = credential.STSAssumeRoleCredential(
|
4139
4139
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4140
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4140
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4141
4141
|
)
|
4142
4142
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4143
4143
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4189,7 +4189,7 @@ def doCheckForwardAuth(args, parsed_globals):
|
|
4189
4189
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4190
4190
|
cred = credential.STSAssumeRoleCredential(
|
4191
4191
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4192
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4192
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4193
4193
|
)
|
4194
4194
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4195
4195
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4241,7 +4241,7 @@ def doDescribeDeviceData(args, parsed_globals):
|
|
4241
4241
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4242
4242
|
cred = credential.STSAssumeRoleCredential(
|
4243
4243
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4244
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4244
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4245
4245
|
)
|
4246
4246
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4247
4247
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4293,7 +4293,7 @@ def doClearDeviceActiveCode(args, parsed_globals):
|
|
4293
4293
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4294
4294
|
cred = credential.STSAssumeRoleCredential(
|
4295
4295
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4296
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4296
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4297
4297
|
)
|
4298
4298
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4299
4299
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4345,7 +4345,7 @@ def doModifyProduct(args, parsed_globals):
|
|
4345
4345
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4346
4346
|
cred = credential.STSAssumeRoleCredential(
|
4347
4347
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4348
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4348
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4349
4349
|
)
|
4350
4350
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4351
4351
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4397,7 +4397,7 @@ def doDescribeAIModelUsage(args, parsed_globals):
|
|
4397
4397
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4398
4398
|
cred = credential.STSAssumeRoleCredential(
|
4399
4399
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4400
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4400
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4401
4401
|
)
|
4402
4402
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4403
4403
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4449,7 +4449,7 @@ def doRunIotModel(args, parsed_globals):
|
|
4449
4449
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4450
4450
|
cred = credential.STSAssumeRoleCredential(
|
4451
4451
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4452
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4452
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4453
4453
|
)
|
4454
4454
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4455
4455
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4501,7 +4501,7 @@ def doModifyDeviceAction(args, parsed_globals):
|
|
4501
4501
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4502
4502
|
cred = credential.STSAssumeRoleCredential(
|
4503
4503
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4504
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4504
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4505
4505
|
)
|
4506
4506
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4507
4507
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4553,7 +4553,7 @@ def doModifyForwardRule(args, parsed_globals):
|
|
4553
4553
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4554
4554
|
cred = credential.STSAssumeRoleCredential(
|
4555
4555
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4556
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4556
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4557
4557
|
)
|
4558
4558
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4559
4559
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4605,7 +4605,7 @@ def doCancelAIModelApplication(args, parsed_globals):
|
|
4605
4605
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4606
4606
|
cred = credential.STSAssumeRoleCredential(
|
4607
4607
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4608
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4608
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4609
4609
|
)
|
4610
4610
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4611
4611
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4657,7 +4657,7 @@ def doDescribeCloudStorage(args, parsed_globals):
|
|
4657
4657
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4658
4658
|
cred = credential.STSAssumeRoleCredential(
|
4659
4659
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4660
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4660
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4661
4661
|
)
|
4662
4662
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4663
4663
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4709,7 +4709,7 @@ def doDescribeBatchs(args, parsed_globals):
|
|
4709
4709
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4710
4710
|
cred = credential.STSAssumeRoleCredential(
|
4711
4711
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4712
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4712
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4713
4713
|
)
|
4714
4714
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4715
4715
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4761,7 +4761,7 @@ def doCreateIotModel(args, parsed_globals):
|
|
4761
4761
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4762
4762
|
cred = credential.STSAssumeRoleCredential(
|
4763
4763
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4764
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4764
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4765
4765
|
)
|
4766
4766
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4767
4767
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4813,7 +4813,7 @@ def doDescribeDeviceActionHistory(args, parsed_globals):
|
|
4813
4813
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4814
4814
|
cred = credential.STSAssumeRoleCredential(
|
4815
4815
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4816
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4816
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4817
4817
|
)
|
4818
4818
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4819
4819
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4865,7 +4865,7 @@ def doDescribeIotModel(args, parsed_globals):
|
|
4865
4865
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4866
4866
|
cred = credential.STSAssumeRoleCredential(
|
4867
4867
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4868
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4868
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4869
4869
|
)
|
4870
4870
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4871
4871
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4917,7 +4917,7 @@ def doCreateCOSCredentials(args, parsed_globals):
|
|
4917
4917
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4918
4918
|
cred = credential.STSAssumeRoleCredential(
|
4919
4919
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4920
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4920
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4921
4921
|
)
|
4922
4922
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4923
4923
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -4969,7 +4969,7 @@ def doSendOnlineMsg(args, parsed_globals):
|
|
4969
4969
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4970
4970
|
cred = credential.STSAssumeRoleCredential(
|
4971
4971
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4972
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
4972
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4973
4973
|
)
|
4974
4974
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
4975
4975
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5021,7 +5021,7 @@ def doCreateTraceIds(args, parsed_globals):
|
|
5021
5021
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5022
5022
|
cred = credential.STSAssumeRoleCredential(
|
5023
5023
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5024
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5024
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5025
5025
|
)
|
5026
5026
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5027
5027
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5073,7 +5073,7 @@ def doCreateBatch(args, parsed_globals):
|
|
5073
5073
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5074
5074
|
cred = credential.STSAssumeRoleCredential(
|
5075
5075
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5076
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5076
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5077
5077
|
)
|
5078
5078
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5079
5079
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5125,7 +5125,7 @@ def doDescribeMessageQueue(args, parsed_globals):
|
|
5125
5125
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5126
5126
|
cred = credential.STSAssumeRoleCredential(
|
5127
5127
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5128
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5128
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5129
5129
|
)
|
5130
5130
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5131
5131
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5177,7 +5177,7 @@ def doCreateBinding(args, parsed_globals):
|
|
5177
5177
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5178
5178
|
cred = credential.STSAssumeRoleCredential(
|
5179
5179
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5180
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5180
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5181
5181
|
)
|
5182
5182
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5183
5183
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5229,7 +5229,7 @@ def doDescribePushChannel(args, parsed_globals):
|
|
5229
5229
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5230
5230
|
cred = credential.STSAssumeRoleCredential(
|
5231
5231
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5232
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5232
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5233
5233
|
)
|
5234
5234
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5235
5235
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5281,7 +5281,7 @@ def doCreateCloudStorage(args, parsed_globals):
|
|
5281
5281
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5282
5282
|
cred = credential.STSAssumeRoleCredential(
|
5283
5283
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5284
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5284
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5285
5285
|
)
|
5286
5286
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5287
5287
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5333,7 +5333,7 @@ def doCreateStorageService(args, parsed_globals):
|
|
5333
5333
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5334
5334
|
cred = credential.STSAssumeRoleCredential(
|
5335
5335
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5336
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5336
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5337
5337
|
)
|
5338
5338
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5339
5339
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5385,7 +5385,7 @@ def doDescribeOsList(args, parsed_globals):
|
|
5385
5385
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5386
5386
|
cred = credential.STSAssumeRoleCredential(
|
5387
5387
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5388
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5388
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5389
5389
|
)
|
5390
5390
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5391
5391
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5437,7 +5437,7 @@ def doDescribeLogs(args, parsed_globals):
|
|
5437
5437
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5438
5438
|
cred = credential.STSAssumeRoleCredential(
|
5439
5439
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5440
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5440
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5441
5441
|
)
|
5442
5442
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5443
5443
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5489,7 +5489,7 @@ def doDescribeProductDynamicRegister(args, parsed_globals):
|
|
5489
5489
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5490
5490
|
cred = credential.STSAssumeRoleCredential(
|
5491
5491
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5492
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5492
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5493
5493
|
)
|
5494
5494
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5495
5495
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5541,7 +5541,7 @@ def doDeliverStorageService(args, parsed_globals):
|
|
5541
5541
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5542
5542
|
cred = credential.STSAssumeRoleCredential(
|
5543
5543
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5544
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5544
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5545
5545
|
)
|
5546
5546
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5547
5547
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5593,7 +5593,7 @@ def doDescribeTraceStatus(args, parsed_globals):
|
|
5593
5593
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5594
5594
|
cred = credential.STSAssumeRoleCredential(
|
5595
5595
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5596
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5596
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5597
5597
|
)
|
5598
5598
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5599
5599
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5645,7 +5645,7 @@ def doDescribeDeviceDataStats(args, parsed_globals):
|
|
5645
5645
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5646
5646
|
cred = credential.STSAssumeRoleCredential(
|
5647
5647
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5648
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5648
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5649
5649
|
)
|
5650
5650
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5651
5651
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5697,7 +5697,7 @@ def doWakeUpDevice(args, parsed_globals):
|
|
5697
5697
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5698
5698
|
cred = credential.STSAssumeRoleCredential(
|
5699
5699
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5700
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5700
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5701
5701
|
)
|
5702
5702
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5703
5703
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5749,7 +5749,7 @@ def doDescribeDeviceStatusLog(args, parsed_globals):
|
|
5749
5749
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5750
5750
|
cred = credential.STSAssumeRoleCredential(
|
5751
5751
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5752
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5752
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5753
5753
|
)
|
5754
5754
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5755
5755
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5801,7 +5801,7 @@ def doDescribeCloudStorageEvents(args, parsed_globals):
|
|
5801
5801
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5802
5802
|
cred = credential.STSAssumeRoleCredential(
|
5803
5803
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5804
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5804
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5805
5805
|
)
|
5806
5806
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5807
5807
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5853,7 +5853,7 @@ def doDescribeRunLog(args, parsed_globals):
|
|
5853
5853
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5854
5854
|
cred = credential.STSAssumeRoleCredential(
|
5855
5855
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5856
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5856
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5857
5857
|
)
|
5858
5858
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5859
5859
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5905,7 +5905,7 @@ def doDescribeAIModelChannel(args, parsed_globals):
|
|
5905
5905
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5906
5906
|
cred = credential.STSAssumeRoleCredential(
|
5907
5907
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5908
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5908
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5909
5909
|
)
|
5910
5910
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5911
5911
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -5957,7 +5957,7 @@ def doDescribeModelDataRet(args, parsed_globals):
|
|
5957
5957
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
5958
5958
|
cred = credential.STSAssumeRoleCredential(
|
5959
5959
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
5960
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
5960
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
5961
5961
|
)
|
5962
5962
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
5963
5963
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6009,7 +6009,7 @@ def doDescribeBalance(args, parsed_globals):
|
|
6009
6009
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6010
6010
|
cred = credential.STSAssumeRoleCredential(
|
6011
6011
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6012
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6012
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6013
6013
|
)
|
6014
6014
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6015
6015
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6061,7 +6061,7 @@ def doDescribeSDKLog(args, parsed_globals):
|
|
6061
6061
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6062
6062
|
cred = credential.STSAssumeRoleCredential(
|
6063
6063
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6064
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6064
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6065
6065
|
)
|
6066
6066
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6067
6067
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6113,7 +6113,7 @@ def doDescribeModelDefinition(args, parsed_globals):
|
|
6113
6113
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6114
6114
|
cred = credential.STSAssumeRoleCredential(
|
6115
6115
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6116
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6116
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6117
6117
|
)
|
6118
6118
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6119
6119
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6165,7 +6165,7 @@ def doDescribeDevice(args, parsed_globals):
|
|
6165
6165
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6166
6166
|
cred = credential.STSAssumeRoleCredential(
|
6167
6167
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6168
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6168
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6169
6169
|
)
|
6170
6170
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6171
6171
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6217,7 +6217,7 @@ def doDescribeMessageDataStats(args, parsed_globals):
|
|
6217
6217
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6218
6218
|
cred = credential.STSAssumeRoleCredential(
|
6219
6219
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6220
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6220
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6221
6221
|
)
|
6222
6222
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6223
6223
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6269,7 +6269,7 @@ def doDeleteCloudStorageEvent(args, parsed_globals):
|
|
6269
6269
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6270
6270
|
cred = credential.STSAssumeRoleCredential(
|
6271
6271
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6272
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6272
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6273
6273
|
)
|
6274
6274
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6275
6275
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6321,7 +6321,7 @@ def doDisableDevice(args, parsed_globals):
|
|
6321
6321
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6322
6322
|
cred = credential.STSAssumeRoleCredential(
|
6323
6323
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6324
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6324
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6325
6325
|
)
|
6326
6326
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6327
6327
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6373,7 +6373,7 @@ def doRunTestOtaVersion(args, parsed_globals):
|
|
6373
6373
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6374
6374
|
cred = credential.STSAssumeRoleCredential(
|
6375
6375
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6376
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6376
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6377
6377
|
)
|
6378
6378
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6379
6379
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6425,7 +6425,7 @@ def doCreateIotDataType(args, parsed_globals):
|
|
6425
6425
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6426
6426
|
cred = credential.STSAssumeRoleCredential(
|
6427
6427
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6428
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6428
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6429
6429
|
)
|
6430
6430
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6431
6431
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6477,7 +6477,7 @@ def doCreateAnonymousAccessToken(args, parsed_globals):
|
|
6477
6477
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6478
6478
|
cred = credential.STSAssumeRoleCredential(
|
6479
6479
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6480
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6480
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6481
6481
|
)
|
6482
6482
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6483
6483
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6529,7 +6529,7 @@ def doDescribeCloudStorageOrder(args, parsed_globals):
|
|
6529
6529
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6530
6530
|
cred = credential.STSAssumeRoleCredential(
|
6531
6531
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6532
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6532
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6533
6533
|
)
|
6534
6534
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6535
6535
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6581,7 +6581,7 @@ def doDeleteBinding(args, parsed_globals):
|
|
6581
6581
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6582
6582
|
cred = credential.STSAssumeRoleCredential(
|
6583
6583
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6584
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6584
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6585
6585
|
)
|
6586
6586
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6587
6587
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6633,7 +6633,7 @@ def doDescribeBalanceTransactions(args, parsed_globals):
|
|
6633
6633
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6634
6634
|
cred = credential.STSAssumeRoleCredential(
|
6635
6635
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6636
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6636
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6637
6637
|
)
|
6638
6638
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6639
6639
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6685,7 +6685,7 @@ def doDeleteForwardRule(args, parsed_globals):
|
|
6685
6685
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6686
6686
|
cred = credential.STSAssumeRoleCredential(
|
6687
6687
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6688
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6688
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6689
6689
|
)
|
6690
6690
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6691
6691
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6737,7 +6737,7 @@ def doModifyProductDynamicRegister(args, parsed_globals):
|
|
6737
6737
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6738
6738
|
cred = credential.STSAssumeRoleCredential(
|
6739
6739
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6740
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6740
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6741
6741
|
)
|
6742
6742
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6743
6743
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6789,7 +6789,7 @@ def doDescribeDeviceDataHistory(args, parsed_globals):
|
|
6789
6789
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6790
6790
|
cred = credential.STSAssumeRoleCredential(
|
6791
6791
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6792
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6792
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6793
6793
|
)
|
6794
6794
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6795
6795
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6841,7 +6841,7 @@ def doDeleteDevice(args, parsed_globals):
|
|
6841
6841
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6842
6842
|
cred = credential.STSAssumeRoleCredential(
|
6843
6843
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6844
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6844
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6845
6845
|
)
|
6846
6846
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6847
6847
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6893,7 +6893,7 @@ def doDeleteAppUsr(args, parsed_globals):
|
|
6893
6893
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6894
6894
|
cred = credential.STSAssumeRoleCredential(
|
6895
6895
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6896
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6896
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6897
6897
|
)
|
6898
6898
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6899
6899
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6945,7 +6945,7 @@ def doDescribeRechargeRecords(args, parsed_globals):
|
|
6945
6945
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6946
6946
|
cred = credential.STSAssumeRoleCredential(
|
6947
6947
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
6948
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
6948
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
6949
6949
|
)
|
6950
6950
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
6951
6951
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -6997,7 +6997,7 @@ def doDescribePackageConsumeTask(args, parsed_globals):
|
|
6997
6997
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
6998
6998
|
cred = credential.STSAssumeRoleCredential(
|
6999
6999
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7000
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7000
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7001
7001
|
)
|
7002
7002
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7003
7003
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7049,7 +7049,7 @@ def doCreateDevices(args, parsed_globals):
|
|
7049
7049
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7050
7050
|
cred = credential.STSAssumeRoleCredential(
|
7051
7051
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7052
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7052
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7053
7053
|
)
|
7054
7054
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7055
7055
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7101,7 +7101,7 @@ def doDescribeAccountBalance(args, parsed_globals):
|
|
7101
7101
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7102
7102
|
cred = credential.STSAssumeRoleCredential(
|
7103
7103
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7104
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7104
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7105
7105
|
)
|
7106
7106
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7107
7107
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7153,7 +7153,7 @@ def doSetForwardAuth(args, parsed_globals):
|
|
7153
7153
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7154
7154
|
cred = credential.STSAssumeRoleCredential(
|
7155
7155
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7156
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7156
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7157
7157
|
)
|
7158
7158
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7159
7159
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7205,7 +7205,7 @@ def doDescribeFirmwareTaskDistribution(args, parsed_globals):
|
|
7205
7205
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7206
7206
|
cred = credential.STSAssumeRoleCredential(
|
7207
7207
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7208
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7208
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7209
7209
|
)
|
7210
7210
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7211
7211
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7257,7 +7257,7 @@ def doDescribeIotModels(args, parsed_globals):
|
|
7257
7257
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7258
7258
|
cred = credential.STSAssumeRoleCredential(
|
7259
7259
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7260
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7260
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7261
7261
|
)
|
7262
7262
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7263
7263
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7309,7 +7309,7 @@ def doGenSingleDeviceSignatureOfPublic(args, parsed_globals):
|
|
7309
7309
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7310
7310
|
cred = credential.STSAssumeRoleCredential(
|
7311
7311
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7312
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7312
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7313
7313
|
)
|
7314
7314
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7315
7315
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7361,7 +7361,7 @@ def doCreateTaskFileUrl(args, parsed_globals):
|
|
7361
7361
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7362
7362
|
cred = credential.STSAssumeRoleCredential(
|
7363
7363
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7364
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7364
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7365
7365
|
)
|
7366
7366
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7367
7367
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7413,7 +7413,7 @@ def doDescribeCloudStorageStreamData(args, parsed_globals):
|
|
7413
7413
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7414
7414
|
cred = credential.STSAssumeRoleCredential(
|
7415
7415
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7416
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7416
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7417
7417
|
)
|
7418
7418
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7419
7419
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7465,7 +7465,7 @@ def doUploadFirmware(args, parsed_globals):
|
|
7465
7465
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7466
7466
|
cred = credential.STSAssumeRoleCredential(
|
7467
7467
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7468
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7468
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7469
7469
|
)
|
7470
7470
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7471
7471
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7517,7 +7517,7 @@ def doRunOtaVersion(args, parsed_globals):
|
|
7517
7517
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7518
7518
|
cred = credential.STSAssumeRoleCredential(
|
7519
7519
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7520
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7520
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7521
7521
|
)
|
7522
7522
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7523
7523
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7569,7 +7569,7 @@ def doCreateDataForward(args, parsed_globals):
|
|
7569
7569
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7570
7570
|
cred = credential.STSAssumeRoleCredential(
|
7571
7571
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7572
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7572
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7573
7573
|
)
|
7574
7574
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7575
7575
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7621,7 +7621,7 @@ def doDescribeBonuses(args, parsed_globals):
|
|
7621
7621
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7622
7622
|
cred = credential.STSAssumeRoleCredential(
|
7623
7623
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7624
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7624
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7625
7625
|
)
|
7626
7626
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7627
7627
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7673,7 +7673,7 @@ def doDisableDeviceStream(args, parsed_globals):
|
|
7673
7673
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7674
7674
|
cred = credential.STSAssumeRoleCredential(
|
7675
7675
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7676
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7676
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7677
7677
|
)
|
7678
7678
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7679
7679
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7725,7 +7725,7 @@ def doCreateUploadPath(args, parsed_globals):
|
|
7725
7725
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7726
7726
|
cred = credential.STSAssumeRoleCredential(
|
7727
7727
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7728
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7728
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7729
7729
|
)
|
7730
7730
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7731
7731
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7777,7 +7777,7 @@ def doCreateForwardRule(args, parsed_globals):
|
|
7777
7777
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7778
7778
|
cred = credential.STSAssumeRoleCredential(
|
7779
7779
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7780
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7780
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7781
7781
|
)
|
7782
7782
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7783
7783
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7829,7 +7829,7 @@ def doModifyModelDefinition(args, parsed_globals):
|
|
7829
7829
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7830
7830
|
cred = credential.STSAssumeRoleCredential(
|
7831
7831
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7832
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7832
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7833
7833
|
)
|
7834
7834
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7835
7835
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7881,7 +7881,7 @@ def doApplyAIModel(args, parsed_globals):
|
|
7881
7881
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7882
7882
|
cred = credential.STSAssumeRoleCredential(
|
7883
7883
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7884
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7884
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7885
7885
|
)
|
7886
7886
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7887
7887
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7933,7 +7933,7 @@ def doBindCloudStorageUser(args, parsed_globals):
|
|
7933
7933
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7934
7934
|
cred = credential.STSAssumeRoleCredential(
|
7935
7935
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7936
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7936
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7937
7937
|
)
|
7938
7938
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7939
7939
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -7985,7 +7985,7 @@ def doDescribeDevices(args, parsed_globals):
|
|
7985
7985
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7986
7986
|
cred = credential.STSAssumeRoleCredential(
|
7987
7987
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7988
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
7988
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7989
7989
|
)
|
7990
7990
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7991
7991
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -8037,7 +8037,7 @@ def doDescribeBindDev(args, parsed_globals):
|
|
8037
8037
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
8038
8038
|
cred = credential.STSAssumeRoleCredential(
|
8039
8039
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
8040
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
8040
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
8041
8041
|
)
|
8042
8042
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
8043
8043
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -8089,7 +8089,7 @@ def doModifyDeviceProperty(args, parsed_globals):
|
|
8089
8089
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
8090
8090
|
cred = credential.STSAssumeRoleCredential(
|
8091
8091
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
8092
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
8092
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
8093
8093
|
)
|
8094
8094
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
8095
8095
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -8141,7 +8141,7 @@ def doDescribeCloudStoragePackageConsumeDetails(args, parsed_globals):
|
|
8141
8141
|
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
8142
8142
|
cred = credential.STSAssumeRoleCredential(
|
8143
8143
|
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
8144
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
8144
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
8145
8145
|
)
|
8146
8146
|
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
8147
8147
|
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
@@ -8439,6 +8439,7 @@ def parse_global_arg(parsed_globals):
|
|
8439
8439
|
|
8440
8440
|
if g_param[OptionsDefine.Endpoint] is None:
|
8441
8441
|
g_param[OptionsDefine.Endpoint] = conf["iotvideo"][OptionsDefine.Endpoint]
|
8442
|
+
g_param["sts_cred_endpoint"] = conf.get("sts", {}).get("endpoint")
|
8442
8443
|
except Exception as err:
|
8443
8444
|
raise ConfigurationError("config file:%s error, %s" % (conf_path, str(err)))
|
8444
8445
|
|