上一主题: config 方法(template 对象)

下一主题: lock 方法(template 对象)


config_boundary 方法(template 对象)

注意:此方法现已弃用,此处的介绍供已经使用它的老用户使用。 新用户应使用带有 &boundary 选项标志的 config 命令。

说明

检索应用模板边界

语法
/api/v1/template/config_boundary?template=template&vdc=controller-name 
参数
template

应用模板的名称

vdc

目标虚拟数据中心的名称

事务类型

同步

请求类型

GET

示例

检索应用模板 VDS_CentOS51_r15 的边界。

GET http://192.168.123.200/api/v1/template/config_boundary?template=VDS_CentOS51_r15&vdc=mygrid 

样例输出

XML:
<boundary> 
   <name>main</name> 
   <property dns1> 
      <mandatory>1</mandatory> 
      <type>string</type> 
   </property dns1> 
   <property dns2> 
      <dflt></dflt> 
      <type>string</type> 
   </property dns2> 
   。
   。  
   。  
   <resource bw> 
      <dflt>1000K</dflt> 
      <max>2G</max> 
      <min>1000K</min> 
   </resource bw> 
   。  
   。  
</boundary>
JSON:
{ 
   "property dns1" : { 
      "type" : "string", 
      "mandatory" : 1 
   }, 
   "property hostname" : { 
      "type" : "string", 
      "mandatory" : 1 
   }, 
   。  
   。  
   。  
   "resource mem" : { 
      "min" : "128M", 
      "max" : "32G", 
      "dflt" : "256M" 
   }, 
   。  
   。  
} 
HTTP 错误代码
404

未找到实体 vdc mygrid-WS_API 应用中没有配置指定的 VDC 名称。

400.4

缺少必需参数 (template)。 -请求中缺少参数 template=template

404.1

未找到实体-权限被拒绝-应用 VDS_CentOS_r1 不存在。