找回密码
 注册
查看: 4449|回复: 1

Heat 模板测试

[复制链接]

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
发表于 2017-11-10 21:15:12 | 显示全部楼层 |阅读模式
购买主题 本主题需向作者支付 6 金钱 才能浏览

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2017-11-20 15:55:50 | 显示全部楼层
使用下面的内容创建``demo-template.yml``文件:7 g- u9 A' {' n, z
- X8 i& e3 G) G- J1 I
heat_template_version: 2015-10-15
- N2 v9 n8 T( Q+ Y! [description: Launch a basic instance using the ``m1.tiny`` flavor and one network.
4 d4 i) \" T& W& U! @. G
6 Q: B, N  k/ l( m% Bparameters:6 ?0 p0 Z* F' F0 u
  ImageID:0 J7 b* ]8 }; G( p- D0 P4 u
    type: string( b1 i( u# E3 E. o
    description: Image to use for the instance.3 W5 e) q: _0 T5 k+ O
  NetID:8 o( v* U* Z  |$ k3 s; y% ]
    type: string
: Z1 ]/ I* c. G; V    description: Network ID to use for the instance.
. e3 I3 S" N, U9 x" _5 `2 c& J0 [! D/ k4 B) b& M
resources:
/ b; a  N( x: j1 ^" w- w* D$ f% k  server:
+ h* p+ ?9 G8 x4 j8 G. t    type: OS::Nova::Server3 j: F( c) B- G
    properties:
) @  X) j2 r9 |0 N      image: { get_param: ImageID }( d2 G. d* t) \5 k
      flavor: m1.tiny
5 |2 a+ f% o( N& p& w: ]" d      networks:
9 j- l3 G0 M1 V& _+ i      - network: { get_param: NetID }
$ f' @/ `. D/ S3 G9 C
7 R8 y9 h. e" E4 R6 u4 Foutputs:
1 W& F3 c  Y. b; ^. L$ E+ e, y3 M  instance_name:$ t+ [  R+ n5 Y8 s  c6 e; A
    description: Name of the instance.3 C  e& y4 z- @& K. G; y
    value: { get_attr: [ server, name ] }
* S8 f; I" Z3 C) q2 Y5 O7 [  instance_ip:; O7 j$ l. O4 c# G! R6 q" E# G
    description: IP address of the instance.
0 s  |5 Q9 t" ^  r    value: { get_attr: [ server, first_address ] }
您需要登录后才可以回帖 登录 | 注册

本版积分规则

返回首页|Archiver|手机版|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )

GMT+8, 2026-6-12 02:01 , Processed in 0.016371 second(s), 25 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表