# 安装模块
pip install aliyun-python-sdk-core
pip install aliyun-python-sdk-ecs
# 代码
#!/usr/bin/env python
#coding=utf-8
import sys
import json
import redis
import time
from aliyunsdkcore.client import AcsClient
from aliyunsdkcore.acs_exception.exceptions import ClientException
from aliyunsdkcore.acs_exception.exceptions import ServerException
from aliyunsdkecs.request.v20140526.RunInstancesRequest import RunInstancesRequest
from aliyunsdkecs.request.v20140526.DescribeInstancesRequest import DescribeInstancesRequest
from aliyunsdkecs.request.v20140526.DescribeInstancesFullStatusRequest import DescribeInstancesFullStatusRequest
#读取参数
accessKeyId = "your_key_id"
accessSecret = "your_secret"
templateId = sys.argv[1] #启动模板id
templateName = sys.argv[2] #启动模板名字
templateVersion = sys.argv[3] #启动模板版本
number = sy