Created
March 24, 2016 21:02
-
-
Save mcallaway/620b59b9ececdd3f1ca7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
heat_template_version: 2013-05-23 | |
description: Template that installs a CoreOS server. | |
parameters: | |
image: | |
type: string | |
label: Image name or ID | |
description: Image to be used for server. Please use an Ubuntu based image. | |
default: CoreOS-835.9.0 | |
flavor: | |
type: string | |
label: Flavor | |
description: Type of instance (flavor) to be used on the compute instance. | |
default: m1.small | |
key: | |
type: string | |
label: Key name | |
description: Name of key-pair to be installed on the compute instance. | |
default: mcallawa-ostack | |
private_network: | |
type: string | |
label: Private network name or ID | |
description: Network to attach server to. | |
default: systems | |
public_network: | |
type: string | |
label: Public network name or ID | |
description: Public network with floating IP addresses. | |
default: external | |
#ssh_pool_id: | |
# type: string | |
ssh_port: | |
type: number | |
default: 22 | |
resources: | |
security_group: | |
type: OS::Neutron::SecurityGroup | |
properties: | |
name: coreos_security_group | |
rules: | |
- protocol: tcp | |
port_range_min: 80 | |
port_range_max: 80 | |
- protocol: tcp | |
port_range_min: 22 | |
port_range_max: 22 | |
- protocol: icmp | |
port: | |
type: OS::Neutron::Port | |
properties: | |
network: { get_param: private_network } | |
security_groups: | |
- { get_resource: security_group } | |
floating_ip: | |
type: OS::Neutron::FloatingIP | |
properties: | |
floating_network: { get_param: public_network } | |
floating_ip_assoc: | |
type: OS::Neutron::FloatingIPAssociation | |
properties: | |
floatingip_id: { get_resource: floating_ip } | |
port_id: { get_resource: port } | |
#ssh_pool_member: | |
# type: OS::Neutron::PoolMember | |
# properties: | |
# pool_id: {get_param: ssh_pool_id} | |
# address: {get_attr: [server, first_address]} | |
# protocol_port: {get_param: ssh_port} | |
server: | |
type: OS::Nova::Server | |
properties: | |
image: { get_param: image } | |
flavor: { get_param: flavor } | |
key_name: { get_param: key } | |
networks: | |
- port: { get_resource: port } | |
# admin_user: core | |
# user_data_format: RAW | |
# user_data: | | |
# #cloud-config | |
# | |
# users: | |
# - name: "core" | |
# passwd: password | |
# - name: "root" | |
# passwd: password | |
# final_message: "The system is finally up, after $UPTIME seconds" | |
outputs: | |
name: | |
description: Name of the cluster instance. | |
value: { get_attr: [server, name] } | |
ip: | |
description: The IP address of the cluster instance. | |
value: { get_attr: [floating_ip, floating_ip_address] } | |
port: | |
description: The network port of the cluster instance. | |
value: { get_resource: port } | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment