tccli 3.0.1217.1__py2.py3-none-any.whl → 3.0.1219.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/command.py +0 -1
- tccli/configure.py +11 -1
- tccli/services/__init__.py +3 -0
- tccli/services/aa/aa_client.py +13 -1
- tccli/services/aai/aai_client.py +13 -1
- tccli/services/acp/acp_client.py +13 -1
- tccli/services/advisor/advisor_client.py +13 -1
- tccli/services/af/af_client.py +13 -1
- tccli/services/af/v20200226/api.json +2 -2
- tccli/services/afc/afc_client.py +13 -1
- tccli/services/aiart/aiart_client.py +13 -1
- tccli/services/ame/ame_client.py +13 -1
- tccli/services/ams/ams_client.py +13 -1
- tccli/services/anicloud/anicloud_client.py +13 -1
- tccli/services/antiddos/antiddos_client.py +13 -1
- tccli/services/apcas/apcas_client.py +13 -1
- tccli/services/ape/ape_client.py +13 -1
- tccli/services/api/api_client.py +13 -1
- tccli/services/apigateway/apigateway_client.py +13 -1
- tccli/services/apm/apm_client.py +13 -1
- tccli/services/asr/asr_client.py +13 -1
- tccli/services/asw/asw_client.py +13 -1
- tccli/services/autoscaling/autoscaling_client.py +13 -1
- tccli/services/ba/ba_client.py +13 -1
- tccli/services/batch/batch_client.py +13 -1
- tccli/services/bda/bda_client.py +13 -1
- tccli/services/bh/bh_client.py +13 -1
- tccli/services/bi/bi_client.py +13 -1
- tccli/services/billing/billing_client.py +13 -1
- tccli/services/billing/v20180709/api.json +176 -181
- tccli/services/billing/v20180709/examples.json +7 -7
- tccli/services/bizlive/bizlive_client.py +13 -1
- tccli/services/bm/bm_client.py +13 -1
- tccli/services/bma/bma_client.py +13 -1
- tccli/services/bmeip/bmeip_client.py +13 -1
- tccli/services/bmlb/bmlb_client.py +13 -1
- tccli/services/bmvpc/bmvpc_client.py +13 -1
- tccli/services/bpaas/bpaas_client.py +13 -1
- tccli/services/bri/bri_client.py +13 -1
- tccli/services/bsca/bsca_client.py +13 -1
- tccli/services/btoe/btoe_client.py +13 -1
- tccli/services/ca/ca_client.py +13 -1
- tccli/services/cam/cam_client.py +13 -1
- tccli/services/captcha/captcha_client.py +13 -1
- tccli/services/car/car_client.py +13 -1
- tccli/services/cat/cat_client.py +13 -1
- tccli/services/cbs/cbs_client.py +13 -1
- tccli/services/ccc/ccc_client.py +13 -1
- tccli/services/cdb/cdb_client.py +13 -1
- tccli/services/cdc/cdc_client.py +13 -1
- tccli/services/cdn/cdn_client.py +13 -1
- tccli/services/cds/cds_client.py +13 -1
- tccli/services/cdwch/cdwch_client.py +13 -1
- tccli/services/cdwdoris/cdwdoris_client.py +13 -1
- tccli/services/cdwpg/cdwpg_client.py +13 -1
- tccli/services/cdz/cdz_client.py +13 -1
- tccli/services/cfg/cfg_client.py +13 -1
- tccli/services/cfs/cfs_client.py +13 -1
- tccli/services/cfw/cfw_client.py +13 -1
- tccli/services/chdfs/chdfs_client.py +13 -1
- tccli/services/ciam/ciam_client.py +13 -1
- tccli/services/cii/cii_client.py +13 -1
- tccli/services/cim/cim_client.py +13 -1
- tccli/services/cis/cis_client.py +13 -1
- tccli/services/ckafka/ckafka_client.py +13 -1
- tccli/services/ckafka/v20190819/api.json +7 -7
- tccli/services/clb/clb_client.py +13 -1
- tccli/services/clb/v20180317/api.json +12 -12
- tccli/services/cloudapp/cloudapp_client.py +13 -1
- tccli/services/cloudaudit/cloudaudit_client.py +13 -1
- tccli/services/cloudhsm/cloudhsm_client.py +13 -1
- tccli/services/cloudstudio/cloudstudio_client.py +13 -1
- tccli/services/cls/cls_client.py +13 -1
- tccli/services/cme/cme_client.py +13 -1
- tccli/services/cmq/cmq_client.py +13 -1
- tccli/services/cms/cms_client.py +13 -1
- tccli/services/config/config_client.py +13 -1
- tccli/services/controlcenter/controlcenter_client.py +13 -1
- tccli/services/cpdp/cpdp_client.py +13 -1
- tccli/services/csip/csip_client.py +13 -1
- tccli/services/csxg/csxg_client.py +13 -1
- tccli/services/cvm/cvm_client.py +13 -1
- tccli/services/cwp/cwp_client.py +13 -1
- tccli/services/cwp/v20180228/api.json +1 -1
- tccli/services/cws/cws_client.py +13 -1
- tccli/services/cynosdb/cynosdb_client.py +13 -1
- tccli/services/dasb/dasb_client.py +13 -1
- tccli/services/dataintegration/dataintegration_client.py +13 -1
- tccli/services/dayu/dayu_client.py +13 -1
- tccli/services/dbbrain/dbbrain_client.py +13 -1
- tccli/services/dbdc/dbdc_client.py +13 -1
- tccli/services/dc/dc_client.py +13 -1
- tccli/services/dcdb/dcdb_client.py +13 -1
- tccli/services/dlc/dlc_client.py +13 -1
- tccli/services/dnspod/dnspod_client.py +13 -1
- tccli/services/domain/domain_client.py +13 -1
- tccli/services/drm/drm_client.py +13 -1
- tccli/services/ds/ds_client.py +13 -1
- tccli/services/dsgc/dsgc_client.py +13 -1
- tccli/services/dtf/dtf_client.py +13 -1
- tccli/services/dts/dts_client.py +13 -1
- tccli/services/eb/eb_client.py +13 -1
- tccli/services/ecc/ecc_client.py +13 -1
- tccli/services/ecdn/ecdn_client.py +13 -1
- tccli/services/ecm/ecm_client.py +13 -1
- tccli/services/eiam/eiam_client.py +13 -1
- tccli/services/eis/eis_client.py +13 -1
- tccli/services/emr/emr_client.py +13 -1
- tccli/services/es/es_client.py +13 -1
- tccli/services/es/v20180416/examples.json +2 -2
- tccli/services/ess/ess_client.py +13 -1
- tccli/services/ess/v20201111/api.json +9 -0
- tccli/services/essbasic/essbasic_client.py +13 -1
- tccli/services/essbasic/v20210526/api.json +9 -0
- tccli/services/facefusion/facefusion_client.py +13 -1
- tccli/services/faceid/faceid_client.py +13 -1
- tccli/services/faceid/v20180301/api.json +2 -2
- tccli/services/fmu/fmu_client.py +13 -1
- tccli/services/ft/ft_client.py +13 -1
- tccli/services/gaap/gaap_client.py +13 -1
- tccli/services/gme/gme_client.py +13 -1
- tccli/services/goosefs/goosefs_client.py +13 -1
- tccli/services/gpm/gpm_client.py +13 -1
- tccli/services/gs/gs_client.py +13 -1
- tccli/services/gse/gse_client.py +13 -1
- tccli/services/gwlb/gwlb_client.py +13 -1
- tccli/services/habo/habo_client.py +13 -1
- tccli/services/hai/hai_client.py +13 -1
- tccli/services/hasim/hasim_client.py +13 -1
- tccli/services/hcm/hcm_client.py +13 -1
- tccli/services/hunyuan/hunyuan_client.py +13 -1
- tccli/services/iai/iai_client.py +13 -1
- tccli/services/iai/v20180301/api.json +17 -13
- tccli/services/iai/v20200303/examples.json +200 -200
- tccli/services/iap/__init__.py +4 -0
- tccli/services/iap/iap_client.py +472 -0
- tccli/services/iap/v20240713/api.json +471 -0
- tccli/services/iap/v20240713/examples.json +59 -0
- tccli/services/ic/ic_client.py +13 -1
- tccli/services/icr/icr_client.py +13 -1
- tccli/services/ie/ie_client.py +13 -1
- tccli/services/iecp/iecp_client.py +13 -1
- tccli/services/ig/ig_client.py +13 -1
- tccli/services/iir/iir_client.py +13 -1
- tccli/services/ims/ims_client.py +13 -1
- tccli/services/ioa/ioa_client.py +13 -1
- tccli/services/iot/iot_client.py +13 -1
- tccli/services/iotcloud/iotcloud_client.py +13 -1
- tccli/services/iotexplorer/iotexplorer_client.py +13 -1
- tccli/services/iottid/iottid_client.py +13 -1
- tccli/services/iotvideo/iotvideo_client.py +13 -1
- tccli/services/iotvideoindustry/iotvideoindustry_client.py +13 -1
- tccli/services/irp/irp_client.py +13 -1
- tccli/services/iss/iss_client.py +13 -1
- tccli/services/ivld/ivld_client.py +13 -1
- tccli/services/keewidb/keewidb_client.py +13 -1
- tccli/services/kms/kms_client.py +13 -1
- tccli/services/lcic/lcic_client.py +13 -1
- tccli/services/lcic/v20220817/api.json +3 -3
- tccli/services/lighthouse/lighthouse_client.py +13 -1
- tccli/services/live/live_client.py +441 -5
- tccli/services/live/v20180801/api.json +1070 -68
- tccli/services/live/v20180801/examples.json +64 -0
- tccli/services/lke/lke_client.py +13 -1
- tccli/services/lowcode/lowcode_client.py +13 -1
- tccli/services/lp/lp_client.py +13 -1
- tccli/services/mall/mall_client.py +13 -1
- tccli/services/mariadb/mariadb_client.py +13 -1
- tccli/services/market/market_client.py +13 -1
- tccli/services/market/v20191010/api.json +4 -4
- tccli/services/market/v20191010/examples.json +2 -2
- tccli/services/memcached/memcached_client.py +13 -1
- tccli/services/mgobe/mgobe_client.py +13 -1
- tccli/services/mmps/mmps_client.py +13 -1
- tccli/services/mna/mna_client.py +13 -1
- tccli/services/mongodb/mongodb_client.py +13 -1
- tccli/services/monitor/monitor_client.py +13 -1
- tccli/services/mps/mps_client.py +13 -1
- tccli/services/mps/v20190612/api.json +20 -0
- tccli/services/mqtt/mqtt_client.py +13 -1
- tccli/services/mrs/mrs_client.py +13 -1
- tccli/services/ms/ms_client.py +13 -1
- tccli/services/msp/msp_client.py +13 -1
- tccli/services/mvj/mvj_client.py +13 -1
- tccli/services/nlp/nlp_client.py +13 -1
- tccli/services/npp/npp_client.py +13 -1
- tccli/services/oceanus/oceanus_client.py +13 -1
- tccli/services/ocr/ocr_client.py +13 -1
- tccli/services/omics/omics_client.py +13 -1
- tccli/services/organization/organization_client.py +13 -1
- tccli/services/partners/partners_client.py +13 -1
- tccli/services/partners/v20180321/api.json +4 -4
- tccli/services/pds/pds_client.py +13 -1
- tccli/services/postgres/postgres_client.py +13 -1
- tccli/services/privatedns/privatedns_client.py +13 -1
- tccli/services/pts/pts_client.py +13 -1
- tccli/services/pts/v20210728/api.json +3 -0
- tccli/services/rce/rce_client.py +13 -1
- tccli/services/redis/redis_client.py +13 -1
- tccli/services/redis/v20180412/api.json +169 -163
- tccli/services/redis/v20180412/examples.json +3 -3
- tccli/services/region/region_client.py +13 -1
- tccli/services/rkp/rkp_client.py +13 -1
- tccli/services/rp/rp_client.py +13 -1
- tccli/services/rum/rum_client.py +13 -1
- tccli/services/scf/scf_client.py +13 -1
- tccli/services/ses/ses_client.py +13 -1
- tccli/services/smh/smh_client.py +13 -1
- tccli/services/smop/smop_client.py +13 -1
- tccli/services/smpn/smpn_client.py +13 -1
- tccli/services/sms/sms_client.py +13 -1
- tccli/services/soe/soe_client.py +13 -1
- tccli/services/solar/solar_client.py +13 -1
- tccli/services/sqlserver/sqlserver_client.py +13 -1
- tccli/services/ssa/ssa_client.py +13 -1
- tccli/services/ssl/ssl_client.py +13 -1
- tccli/services/sslpod/sslpod_client.py +13 -1
- tccli/services/ssm/ssm_client.py +13 -1
- tccli/services/sts/sts_client.py +13 -1
- tccli/services/svp/svp_client.py +13 -1
- tccli/services/svp/v20240125/api.json +27 -27
- tccli/services/svp/v20240125/examples.json +1 -1
- tccli/services/taf/taf_client.py +13 -1
- tccli/services/tag/tag_client.py +13 -1
- tccli/services/tan/tan_client.py +13 -1
- tccli/services/tat/tat_client.py +13 -1
- tccli/services/tat/v20201028/api.json +5 -5
- tccli/services/tav/tav_client.py +13 -1
- tccli/services/tbaas/tbaas_client.py +13 -1
- tccli/services/tbm/tbm_client.py +13 -1
- tccli/services/tbp/tbp_client.py +13 -1
- tccli/services/tcaplusdb/tcaplusdb_client.py +13 -1
- tccli/services/tcb/tcb_client.py +13 -1
- tccli/services/tcbr/tcbr_client.py +13 -1
- tccli/services/tcex/tcex_client.py +13 -1
- tccli/services/tchd/tchd_client.py +13 -1
- tccli/services/tci/tci_client.py +13 -1
- tccli/services/tcm/tcm_client.py +13 -1
- tccli/services/tcr/tcr_client.py +13 -1
- tccli/services/tcss/tcss_client.py +13 -1
- tccli/services/tdcpg/tdcpg_client.py +13 -1
- tccli/services/tdid/tdid_client.py +13 -1
- tccli/services/tdmq/tdmq_client.py +13 -1
- tccli/services/tdmq/v20200217/api.json +1 -1
- tccli/services/tds/tds_client.py +13 -1
- tccli/services/tem/tem_client.py +13 -1
- tccli/services/teo/teo_client.py +13 -1
- tccli/services/thpc/thpc_client.py +13 -1
- tccli/services/tia/tia_client.py +13 -1
- tccli/services/tic/tic_client.py +13 -1
- tccli/services/ticm/ticm_client.py +13 -1
- tccli/services/tics/tics_client.py +13 -1
- tccli/services/tiems/tiems_client.py +13 -1
- tccli/services/tiia/tiia_client.py +13 -1
- tccli/services/tione/tione_client.py +13 -1
- tccli/services/tiw/tiw_client.py +13 -1
- tccli/services/tke/tke_client.py +13 -1
- tccli/services/tke/v20220501/api.json +2 -2
- tccli/services/tkgdq/tkgdq_client.py +13 -1
- tccli/services/tms/tms_client.py +13 -1
- tccli/services/tmt/tmt_client.py +13 -1
- tccli/services/tourism/tourism_client.py +13 -1
- tccli/services/trdp/trdp_client.py +13 -1
- tccli/services/trocket/trocket_client.py +13 -1
- tccli/services/trp/trp_client.py +13 -1
- tccli/services/trro/trro_client.py +13 -1
- tccli/services/trtc/trtc_client.py +13 -1
- tccli/services/tse/tse_client.py +13 -1
- tccli/services/tse/v20201207/api.json +199 -12
- tccli/services/tsf/tsf_client.py +13 -1
- tccli/services/tsi/tsi_client.py +13 -1
- tccli/services/tsw/tsw_client.py +13 -1
- tccli/services/tts/tts_client.py +13 -1
- tccli/services/ump/ump_client.py +13 -1
- tccli/services/vcg/v20240404/api.json +1 -1
- tccli/services/vcg/v20240404/examples.json +4 -4
- tccli/services/vcg/vcg_client.py +13 -1
- tccli/services/vclm/vclm_client.py +13 -1
- tccli/services/vdb/vdb_client.py +13 -1
- tccli/services/vm/vm_client.py +13 -1
- tccli/services/vms/vms_client.py +13 -1
- tccli/services/vod/vod_client.py +13 -1
- tccli/services/vpc/v20170312/api.json +492 -66
- tccli/services/vpc/v20170312/examples.json +59 -21
- tccli/services/vpc/vpc_client.py +225 -1
- tccli/services/vrs/vrs_client.py +13 -1
- tccli/services/vtc/vtc_client.py +13 -1
- tccli/services/waf/waf_client.py +13 -1
- tccli/services/wav/wav_client.py +13 -1
- tccli/services/wedata/wedata_client.py +13 -1
- tccli/services/weilingwith/weilingwith_client.py +13 -1
- tccli/services/wss/wss_client.py +13 -1
- tccli/services/yinsuda/yinsuda_client.py +13 -1
- tccli/services/youmall/youmall_client.py +13 -1
- tccli/services/yunjing/yunjing_client.py +13 -1
- tccli/services/yunsou/yunsou_client.py +13 -1
- tccli/utils.py +8 -0
- {tccli-3.0.1217.1.dist-info → tccli-3.0.1219.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1217.1.dist-info → tccli-3.0.1219.1.dist-info}/RECORD +303 -299
- {tccli-3.0.1217.1.dist-info → tccli-3.0.1219.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1217.1.dist-info → tccli-3.0.1219.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1217.1.dist-info → tccli-3.0.1219.1.dist-info}/license_files/LICENSE +0 -0
tccli/services/ig/ig_client.py
CHANGED
@@ -96,7 +96,13 @@ def action_caller():
|
|
96
96
|
|
97
97
|
def parse_global_arg(parsed_globals):
|
98
98
|
g_param = parsed_globals
|
99
|
-
|
99
|
+
cvm_role_flag = True
|
100
|
+
for param in parsed_globals.keys():
|
101
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
102
|
+
OptionsDefine.RoleSessionName]:
|
103
|
+
if parsed_globals[param] is not None:
|
104
|
+
cvm_role_flag = False
|
105
|
+
break
|
100
106
|
is_exist_profile = True
|
101
107
|
if not parsed_globals["profile"]:
|
102
108
|
is_exist_profile = False
|
@@ -127,6 +133,7 @@ def parse_global_arg(parsed_globals):
|
|
127
133
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
128
134
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
129
135
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
136
|
+
cvm_role_flag = False
|
130
137
|
|
131
138
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
132
139
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -134,6 +141,11 @@ def parse_global_arg(parsed_globals):
|
|
134
141
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
135
142
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
136
143
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
144
|
+
cvm_role_flag = False
|
145
|
+
|
146
|
+
if cvm_role_flag:
|
147
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
148
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
137
149
|
|
138
150
|
for param in g_param.keys():
|
139
151
|
if g_param[param] is None:
|
tccli/services/iir/iir_client.py
CHANGED
@@ -96,7 +96,13 @@ def action_caller():
|
|
96
96
|
|
97
97
|
def parse_global_arg(parsed_globals):
|
98
98
|
g_param = parsed_globals
|
99
|
-
|
99
|
+
cvm_role_flag = True
|
100
|
+
for param in parsed_globals.keys():
|
101
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
102
|
+
OptionsDefine.RoleSessionName]:
|
103
|
+
if parsed_globals[param] is not None:
|
104
|
+
cvm_role_flag = False
|
105
|
+
break
|
100
106
|
is_exist_profile = True
|
101
107
|
if not parsed_globals["profile"]:
|
102
108
|
is_exist_profile = False
|
@@ -127,6 +133,7 @@ def parse_global_arg(parsed_globals):
|
|
127
133
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
128
134
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
129
135
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
136
|
+
cvm_role_flag = False
|
130
137
|
|
131
138
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
132
139
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -134,6 +141,11 @@ def parse_global_arg(parsed_globals):
|
|
134
141
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
135
142
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
136
143
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
144
|
+
cvm_role_flag = False
|
145
|
+
|
146
|
+
if cvm_role_flag:
|
147
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
148
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
137
149
|
|
138
150
|
for param in g_param.keys():
|
139
151
|
if g_param[param] is None:
|
tccli/services/ims/ims_client.py
CHANGED
@@ -154,7 +154,13 @@ def action_caller():
|
|
154
154
|
|
155
155
|
def parse_global_arg(parsed_globals):
|
156
156
|
g_param = parsed_globals
|
157
|
-
|
157
|
+
cvm_role_flag = True
|
158
|
+
for param in parsed_globals.keys():
|
159
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
160
|
+
OptionsDefine.RoleSessionName]:
|
161
|
+
if parsed_globals[param] is not None:
|
162
|
+
cvm_role_flag = False
|
163
|
+
break
|
158
164
|
is_exist_profile = True
|
159
165
|
if not parsed_globals["profile"]:
|
160
166
|
is_exist_profile = False
|
@@ -185,6 +191,7 @@ def parse_global_arg(parsed_globals):
|
|
185
191
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
186
192
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
187
193
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
194
|
+
cvm_role_flag = False
|
188
195
|
|
189
196
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
190
197
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -192,6 +199,11 @@ def parse_global_arg(parsed_globals):
|
|
192
199
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
193
200
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
194
201
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
202
|
+
cvm_role_flag = False
|
203
|
+
|
204
|
+
if cvm_role_flag:
|
205
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
206
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
195
207
|
|
196
208
|
for param in g_param.keys():
|
197
209
|
if g_param[param] is None:
|
tccli/services/ioa/ioa_client.py
CHANGED
@@ -308,7 +308,13 @@ def action_caller():
|
|
308
308
|
|
309
309
|
def parse_global_arg(parsed_globals):
|
310
310
|
g_param = parsed_globals
|
311
|
-
|
311
|
+
cvm_role_flag = True
|
312
|
+
for param in parsed_globals.keys():
|
313
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
314
|
+
OptionsDefine.RoleSessionName]:
|
315
|
+
if parsed_globals[param] is not None:
|
316
|
+
cvm_role_flag = False
|
317
|
+
break
|
312
318
|
is_exist_profile = True
|
313
319
|
if not parsed_globals["profile"]:
|
314
320
|
is_exist_profile = False
|
@@ -339,6 +345,7 @@ def parse_global_arg(parsed_globals):
|
|
339
345
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
340
346
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
341
347
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
348
|
+
cvm_role_flag = False
|
342
349
|
|
343
350
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
344
351
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -346,6 +353,11 @@ def parse_global_arg(parsed_globals):
|
|
346
353
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
347
354
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
348
355
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
356
|
+
cvm_role_flag = False
|
357
|
+
|
358
|
+
if cvm_role_flag:
|
359
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
360
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
349
361
|
|
350
362
|
for param in g_param.keys():
|
351
363
|
if g_param[param] is None:
|
tccli/services/iot/iot_client.py
CHANGED
@@ -2428,7 +2428,13 @@ def action_caller():
|
|
2428
2428
|
|
2429
2429
|
def parse_global_arg(parsed_globals):
|
2430
2430
|
g_param = parsed_globals
|
2431
|
-
|
2431
|
+
cvm_role_flag = True
|
2432
|
+
for param in parsed_globals.keys():
|
2433
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
2434
|
+
OptionsDefine.RoleSessionName]:
|
2435
|
+
if parsed_globals[param] is not None:
|
2436
|
+
cvm_role_flag = False
|
2437
|
+
break
|
2432
2438
|
is_exist_profile = True
|
2433
2439
|
if not parsed_globals["profile"]:
|
2434
2440
|
is_exist_profile = False
|
@@ -2459,6 +2465,7 @@ def parse_global_arg(parsed_globals):
|
|
2459
2465
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
2460
2466
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
2461
2467
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
2468
|
+
cvm_role_flag = False
|
2462
2469
|
|
2463
2470
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
2464
2471
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -2466,6 +2473,11 @@ def parse_global_arg(parsed_globals):
|
|
2466
2473
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
2467
2474
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
2468
2475
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
2476
|
+
cvm_role_flag = False
|
2477
|
+
|
2478
|
+
if cvm_role_flag:
|
2479
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
2480
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
2469
2481
|
|
2470
2482
|
for param in g_param.keys():
|
2471
2483
|
if g_param[param] is None:
|
@@ -4606,7 +4606,13 @@ def action_caller():
|
|
4606
4606
|
|
4607
4607
|
def parse_global_arg(parsed_globals):
|
4608
4608
|
g_param = parsed_globals
|
4609
|
-
|
4609
|
+
cvm_role_flag = True
|
4610
|
+
for param in parsed_globals.keys():
|
4611
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
4612
|
+
OptionsDefine.RoleSessionName]:
|
4613
|
+
if parsed_globals[param] is not None:
|
4614
|
+
cvm_role_flag = False
|
4615
|
+
break
|
4610
4616
|
is_exist_profile = True
|
4611
4617
|
if not parsed_globals["profile"]:
|
4612
4618
|
is_exist_profile = False
|
@@ -4637,6 +4643,7 @@ def parse_global_arg(parsed_globals):
|
|
4637
4643
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
4638
4644
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
4639
4645
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
4646
|
+
cvm_role_flag = False
|
4640
4647
|
|
4641
4648
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
4642
4649
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -4644,6 +4651,11 @@ def parse_global_arg(parsed_globals):
|
|
4644
4651
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
4645
4652
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
4646
4653
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
4654
|
+
cvm_role_flag = False
|
4655
|
+
|
4656
|
+
if cvm_role_flag:
|
4657
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
4658
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
4647
4659
|
|
4648
4660
|
for param in g_param.keys():
|
4649
4661
|
if g_param[param] is None:
|
@@ -7728,7 +7728,13 @@ def action_caller():
|
|
7728
7728
|
|
7729
7729
|
def parse_global_arg(parsed_globals):
|
7730
7730
|
g_param = parsed_globals
|
7731
|
-
|
7731
|
+
cvm_role_flag = True
|
7732
|
+
for param in parsed_globals.keys():
|
7733
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
7734
|
+
OptionsDefine.RoleSessionName]:
|
7735
|
+
if parsed_globals[param] is not None:
|
7736
|
+
cvm_role_flag = False
|
7737
|
+
break
|
7732
7738
|
is_exist_profile = True
|
7733
7739
|
if not parsed_globals["profile"]:
|
7734
7740
|
is_exist_profile = False
|
@@ -7759,6 +7765,7 @@ def parse_global_arg(parsed_globals):
|
|
7759
7765
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
7760
7766
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
7761
7767
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
7768
|
+
cvm_role_flag = False
|
7762
7769
|
|
7763
7770
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
7764
7771
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -7766,6 +7773,11 @@ def parse_global_arg(parsed_globals):
|
|
7766
7773
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
7767
7774
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
7768
7775
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
7776
|
+
cvm_role_flag = False
|
7777
|
+
|
7778
|
+
if cvm_role_flag:
|
7779
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
7780
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
7769
7781
|
|
7770
7782
|
for param in g_param.keys():
|
7771
7783
|
if g_param[param] is None:
|
@@ -520,7 +520,13 @@ def action_caller():
|
|
520
520
|
|
521
521
|
def parse_global_arg(parsed_globals):
|
522
522
|
g_param = parsed_globals
|
523
|
-
|
523
|
+
cvm_role_flag = True
|
524
|
+
for param in parsed_globals.keys():
|
525
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
526
|
+
OptionsDefine.RoleSessionName]:
|
527
|
+
if parsed_globals[param] is not None:
|
528
|
+
cvm_role_flag = False
|
529
|
+
break
|
524
530
|
is_exist_profile = True
|
525
531
|
if not parsed_globals["profile"]:
|
526
532
|
is_exist_profile = False
|
@@ -551,6 +557,7 @@ def parse_global_arg(parsed_globals):
|
|
551
557
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
552
558
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
553
559
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
560
|
+
cvm_role_flag = False
|
554
561
|
|
555
562
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
556
563
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -558,6 +565,11 @@ def parse_global_arg(parsed_globals):
|
|
558
565
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
559
566
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
560
567
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
568
|
+
cvm_role_flag = False
|
569
|
+
|
570
|
+
if cvm_role_flag:
|
571
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
572
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
561
573
|
|
562
574
|
for param in g_param.keys():
|
563
575
|
if g_param[param] is None:
|
@@ -8586,7 +8586,13 @@ def action_caller():
|
|
8586
8586
|
|
8587
8587
|
def parse_global_arg(parsed_globals):
|
8588
8588
|
g_param = parsed_globals
|
8589
|
-
|
8589
|
+
cvm_role_flag = True
|
8590
|
+
for param in parsed_globals.keys():
|
8591
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
8592
|
+
OptionsDefine.RoleSessionName]:
|
8593
|
+
if parsed_globals[param] is not None:
|
8594
|
+
cvm_role_flag = False
|
8595
|
+
break
|
8590
8596
|
is_exist_profile = True
|
8591
8597
|
if not parsed_globals["profile"]:
|
8592
8598
|
is_exist_profile = False
|
@@ -8617,6 +8623,7 @@ def parse_global_arg(parsed_globals):
|
|
8617
8623
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
8618
8624
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
8619
8625
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
8626
|
+
cvm_role_flag = False
|
8620
8627
|
|
8621
8628
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
8622
8629
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -8624,6 +8631,11 @@ def parse_global_arg(parsed_globals):
|
|
8624
8631
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
8625
8632
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
8626
8633
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
8634
|
+
cvm_role_flag = False
|
8635
|
+
|
8636
|
+
if cvm_role_flag:
|
8637
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
8638
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
8627
8639
|
|
8628
8640
|
for param in g_param.keys():
|
8629
8641
|
if g_param[param] is None:
|
@@ -5555,7 +5555,13 @@ def action_caller():
|
|
5555
5555
|
|
5556
5556
|
def parse_global_arg(parsed_globals):
|
5557
5557
|
g_param = parsed_globals
|
5558
|
-
|
5558
|
+
cvm_role_flag = True
|
5559
|
+
for param in parsed_globals.keys():
|
5560
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
5561
|
+
OptionsDefine.RoleSessionName]:
|
5562
|
+
if parsed_globals[param] is not None:
|
5563
|
+
cvm_role_flag = False
|
5564
|
+
break
|
5559
5565
|
is_exist_profile = True
|
5560
5566
|
if not parsed_globals["profile"]:
|
5561
5567
|
is_exist_profile = False
|
@@ -5586,6 +5592,7 @@ def parse_global_arg(parsed_globals):
|
|
5586
5592
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
5587
5593
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
5588
5594
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
5595
|
+
cvm_role_flag = False
|
5589
5596
|
|
5590
5597
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
5591
5598
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -5593,6 +5600,11 @@ def parse_global_arg(parsed_globals):
|
|
5593
5600
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
5594
5601
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
5595
5602
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
5603
|
+
cvm_role_flag = False
|
5604
|
+
|
5605
|
+
if cvm_role_flag:
|
5606
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
5607
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
5596
5608
|
|
5597
5609
|
for param in g_param.keys():
|
5598
5610
|
if g_param[param] is None:
|
tccli/services/irp/irp_client.py
CHANGED
@@ -631,7 +631,13 @@ def action_caller():
|
|
631
631
|
|
632
632
|
def parse_global_arg(parsed_globals):
|
633
633
|
g_param = parsed_globals
|
634
|
-
|
634
|
+
cvm_role_flag = True
|
635
|
+
for param in parsed_globals.keys():
|
636
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
637
|
+
OptionsDefine.RoleSessionName]:
|
638
|
+
if parsed_globals[param] is not None:
|
639
|
+
cvm_role_flag = False
|
640
|
+
break
|
635
641
|
is_exist_profile = True
|
636
642
|
if not parsed_globals["profile"]:
|
637
643
|
is_exist_profile = False
|
@@ -662,6 +668,7 @@ def parse_global_arg(parsed_globals):
|
|
662
668
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
663
669
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
664
670
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
671
|
+
cvm_role_flag = False
|
665
672
|
|
666
673
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
667
674
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -669,6 +676,11 @@ def parse_global_arg(parsed_globals):
|
|
669
676
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
670
677
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
671
678
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
679
|
+
cvm_role_flag = False
|
680
|
+
|
681
|
+
if cvm_role_flag:
|
682
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
683
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
672
684
|
|
673
685
|
for param in g_param.keys():
|
674
686
|
if g_param[param] is None:
|
tccli/services/iss/iss_client.py
CHANGED
@@ -4495,7 +4495,13 @@ def action_caller():
|
|
4495
4495
|
|
4496
4496
|
def parse_global_arg(parsed_globals):
|
4497
4497
|
g_param = parsed_globals
|
4498
|
-
|
4498
|
+
cvm_role_flag = True
|
4499
|
+
for param in parsed_globals.keys():
|
4500
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
4501
|
+
OptionsDefine.RoleSessionName]:
|
4502
|
+
if parsed_globals[param] is not None:
|
4503
|
+
cvm_role_flag = False
|
4504
|
+
break
|
4499
4505
|
is_exist_profile = True
|
4500
4506
|
if not parsed_globals["profile"]:
|
4501
4507
|
is_exist_profile = False
|
@@ -4526,6 +4532,7 @@ def parse_global_arg(parsed_globals):
|
|
4526
4532
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
4527
4533
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
4528
4534
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
4535
|
+
cvm_role_flag = False
|
4529
4536
|
|
4530
4537
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
4531
4538
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -4533,6 +4540,11 @@ def parse_global_arg(parsed_globals):
|
|
4533
4540
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
4534
4541
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
4535
4542
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
4543
|
+
cvm_role_flag = False
|
4544
|
+
|
4545
|
+
if cvm_role_flag:
|
4546
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
4547
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
4536
4548
|
|
4537
4549
|
for param in g_param.keys():
|
4538
4550
|
if g_param[param] is None:
|
@@ -1527,7 +1527,13 @@ def action_caller():
|
|
1527
1527
|
|
1528
1528
|
def parse_global_arg(parsed_globals):
|
1529
1529
|
g_param = parsed_globals
|
1530
|
-
|
1530
|
+
cvm_role_flag = True
|
1531
|
+
for param in parsed_globals.keys():
|
1532
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
1533
|
+
OptionsDefine.RoleSessionName]:
|
1534
|
+
if parsed_globals[param] is not None:
|
1535
|
+
cvm_role_flag = False
|
1536
|
+
break
|
1531
1537
|
is_exist_profile = True
|
1532
1538
|
if not parsed_globals["profile"]:
|
1533
1539
|
is_exist_profile = False
|
@@ -1558,6 +1564,7 @@ def parse_global_arg(parsed_globals):
|
|
1558
1564
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
1559
1565
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
1560
1566
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
1567
|
+
cvm_role_flag = False
|
1561
1568
|
|
1562
1569
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
1563
1570
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -1565,6 +1572,11 @@ def parse_global_arg(parsed_globals):
|
|
1565
1572
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
1566
1573
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
1567
1574
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
1575
|
+
cvm_role_flag = False
|
1576
|
+
|
1577
|
+
if cvm_role_flag:
|
1578
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
1579
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
1568
1580
|
|
1569
1581
|
for param in g_param.keys():
|
1570
1582
|
if g_param[param] is None:
|
@@ -2057,7 +2057,13 @@ def action_caller():
|
|
2057
2057
|
|
2058
2058
|
def parse_global_arg(parsed_globals):
|
2059
2059
|
g_param = parsed_globals
|
2060
|
-
|
2060
|
+
cvm_role_flag = True
|
2061
|
+
for param in parsed_globals.keys():
|
2062
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
2063
|
+
OptionsDefine.RoleSessionName]:
|
2064
|
+
if parsed_globals[param] is not None:
|
2065
|
+
cvm_role_flag = False
|
2066
|
+
break
|
2061
2067
|
is_exist_profile = True
|
2062
2068
|
if not parsed_globals["profile"]:
|
2063
2069
|
is_exist_profile = False
|
@@ -2088,6 +2094,7 @@ def parse_global_arg(parsed_globals):
|
|
2088
2094
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
2089
2095
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
2090
2096
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
2097
|
+
cvm_role_flag = False
|
2091
2098
|
|
2092
2099
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
2093
2100
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -2095,6 +2102,11 @@ def parse_global_arg(parsed_globals):
|
|
2095
2102
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
2096
2103
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
2097
2104
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
2105
|
+
cvm_role_flag = False
|
2106
|
+
|
2107
|
+
if cvm_role_flag:
|
2108
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
2109
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
2098
2110
|
|
2099
2111
|
for param in g_param.keys():
|
2100
2112
|
if g_param[param] is None:
|
tccli/services/kms/kms_client.py
CHANGED
@@ -2852,7 +2852,13 @@ def action_caller():
|
|
2852
2852
|
|
2853
2853
|
def parse_global_arg(parsed_globals):
|
2854
2854
|
g_param = parsed_globals
|
2855
|
-
|
2855
|
+
cvm_role_flag = True
|
2856
|
+
for param in parsed_globals.keys():
|
2857
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
2858
|
+
OptionsDefine.RoleSessionName]:
|
2859
|
+
if parsed_globals[param] is not None:
|
2860
|
+
cvm_role_flag = False
|
2861
|
+
break
|
2856
2862
|
is_exist_profile = True
|
2857
2863
|
if not parsed_globals["profile"]:
|
2858
2864
|
is_exist_profile = False
|
@@ -2883,6 +2889,7 @@ def parse_global_arg(parsed_globals):
|
|
2883
2889
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
2884
2890
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
2885
2891
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
2892
|
+
cvm_role_flag = False
|
2886
2893
|
|
2887
2894
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
2888
2895
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -2890,6 +2897,11 @@ def parse_global_arg(parsed_globals):
|
|
2890
2897
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
2891
2898
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
2892
2899
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
2900
|
+
cvm_role_flag = False
|
2901
|
+
|
2902
|
+
if cvm_role_flag:
|
2903
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
2904
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
2893
2905
|
|
2894
2906
|
for param in g_param.keys():
|
2895
2907
|
if g_param[param] is None:
|
@@ -3488,7 +3488,13 @@ def action_caller():
|
|
3488
3488
|
|
3489
3489
|
def parse_global_arg(parsed_globals):
|
3490
3490
|
g_param = parsed_globals
|
3491
|
-
|
3491
|
+
cvm_role_flag = True
|
3492
|
+
for param in parsed_globals.keys():
|
3493
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
3494
|
+
OptionsDefine.RoleSessionName]:
|
3495
|
+
if parsed_globals[param] is not None:
|
3496
|
+
cvm_role_flag = False
|
3497
|
+
break
|
3492
3498
|
is_exist_profile = True
|
3493
3499
|
if not parsed_globals["profile"]:
|
3494
3500
|
is_exist_profile = False
|
@@ -3519,6 +3525,7 @@ def parse_global_arg(parsed_globals):
|
|
3519
3525
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
3520
3526
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
3521
3527
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
3528
|
+
cvm_role_flag = False
|
3522
3529
|
|
3523
3530
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
3524
3531
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -3526,6 +3533,11 @@ def parse_global_arg(parsed_globals):
|
|
3526
3533
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
3527
3534
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
3528
3535
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
3536
|
+
cvm_role_flag = False
|
3537
|
+
|
3538
|
+
if cvm_role_flag:
|
3539
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
3540
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
3529
3541
|
|
3530
3542
|
for param in g_param.keys():
|
3531
3543
|
if g_param[param] is None:
|
@@ -1579,7 +1579,7 @@
|
|
1579
1579
|
},
|
1580
1580
|
{
|
1581
1581
|
"disabled": false,
|
1582
|
-
"document": "
|
1582
|
+
"document": "头像区域,摄像头视频画面的分辨率。可以有如下取值:\n1 标清\n2 高清\n3 全高清",
|
1583
1583
|
"example": "1",
|
1584
1584
|
"member": "uint64",
|
1585
1585
|
"name": "Resolution",
|
@@ -3488,7 +3488,7 @@
|
|
3488
3488
|
},
|
3489
3489
|
{
|
3490
3490
|
"disabled": false,
|
3491
|
-
"document": "
|
3491
|
+
"document": "头像区域,摄像头视频画面的分辨率。可以有如下取值:\n1 标清\n2 高清\n3 全高清",
|
3492
3492
|
"example": "1",
|
3493
3493
|
"member": "uint64",
|
3494
3494
|
"name": "Resolution",
|
@@ -6194,7 +6194,7 @@
|
|
6194
6194
|
},
|
6195
6195
|
{
|
6196
6196
|
"disabled": false,
|
6197
|
-
"document": "
|
6197
|
+
"document": "头像区域,摄像头视频画面的分辨率。可以有如下取值:\n1 标清\n2 高清\n3 全高清",
|
6198
6198
|
"example": "1",
|
6199
6199
|
"member": "uint64",
|
6200
6200
|
"name": "Resolution",
|
@@ -5820,7 +5820,13 @@ def action_caller():
|
|
5820
5820
|
|
5821
5821
|
def parse_global_arg(parsed_globals):
|
5822
5822
|
g_param = parsed_globals
|
5823
|
-
|
5823
|
+
cvm_role_flag = True
|
5824
|
+
for param in parsed_globals.keys():
|
5825
|
+
if param in [OptionsDefine.SecretKey, OptionsDefine.SecretId, OptionsDefine.RoleArn,
|
5826
|
+
OptionsDefine.RoleSessionName]:
|
5827
|
+
if parsed_globals[param] is not None:
|
5828
|
+
cvm_role_flag = False
|
5829
|
+
break
|
5824
5830
|
is_exist_profile = True
|
5825
5831
|
if not parsed_globals["profile"]:
|
5826
5832
|
is_exist_profile = False
|
@@ -5851,6 +5857,7 @@ def parse_global_arg(parsed_globals):
|
|
5851
5857
|
cred[OptionsDefine.SecretId] = os.environ.get(OptionsDefine.ENV_SECRET_ID)
|
5852
5858
|
cred[OptionsDefine.SecretKey] = os.environ.get(OptionsDefine.ENV_SECRET_KEY)
|
5853
5859
|
cred[OptionsDefine.Token] = os.environ.get(OptionsDefine.ENV_TOKEN)
|
5860
|
+
cvm_role_flag = False
|
5854
5861
|
|
5855
5862
|
if os.environ.get(OptionsDefine.ENV_REGION):
|
5856
5863
|
conf[OptionsDefine.SysParam][OptionsDefine.Region] = os.environ.get(OptionsDefine.ENV_REGION)
|
@@ -5858,6 +5865,11 @@ def parse_global_arg(parsed_globals):
|
|
5858
5865
|
if os.environ.get(OptionsDefine.ENV_ROLE_ARN) and os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME):
|
5859
5866
|
cred[OptionsDefine.RoleArn] = os.environ.get(OptionsDefine.ENV_ROLE_ARN)
|
5860
5867
|
cred[OptionsDefine.RoleSessionName] = os.environ.get(OptionsDefine.ENV_ROLE_SESSION_NAME)
|
5868
|
+
cvm_role_flag = False
|
5869
|
+
|
5870
|
+
if cvm_role_flag:
|
5871
|
+
if "type" in cred and cred["type"] == "cvm-role":
|
5872
|
+
g_param[OptionsDefine.UseCVMRole.replace('-', '_')] = True
|
5861
5873
|
|
5862
5874
|
for param in g_param.keys():
|
5863
5875
|
if g_param[param] is None:
|