Skip to content

Instantly share code, notes, and snippets.

@dizz
Created July 1, 2016 12:15
Show Gist options
  • Save dizz/a8ab789430e70345758a2c5e1ab790c7 to your computer and use it in GitHub Desktop.
Save dizz/a8ab789430e70345758a2c5e1ab790c7 to your computer and use it in GitHub Desktop.
orchestration template
heat_template_version: 2013-05-23
description: >
This template sets up a 2 node wordpress installation
parameters:
key_name:
type: string
description: Name of keypair to assign to servers
default: YOUR_KEY_NAME # FILL HERE: Name of your ssh key
image:
type: string
description: Name of image to use for servers
default: ubuntu-14.04
flavor:
type: string
description: Flavor to use for servers
default: m1.small
public_net:
type: string
description: >
ID of public network for which floating IP addresses will be allocated
default: 77e659dd-f1b4-430c-ac6f-d92ec0137c85
# Example of a resource declaration
# resources:
# example-network:
# type: OS::Neutron::Net
# properties:
# name: an-example-network
resources:
secgrp:
type: OS::Neutron::SecurityGroup
properties:
# FILL HERE
wordpress:
type: OS::Nova::Server
depends_on: mysql
properties:
name: wordpress
# FILL HERE
wordpress-port:
type: OS::Neutron::Port
properties:
# FILL HERE
wordpress-floating-ip:
type: OS::Neutron::FloatingIP
properties:
# FILL HERE
mysql:
type: OS::Nova::Server
properties:
name: mysql
# FILL HERE
mysql-port:
type: OS::Neutron::Port
properties:
# FILL HERE
outputs:
pub_addr:
description: public address of the frontend
value: { get_attr: [ wordpress-floating-ip, floating_ip_address ] }
priv_addr:
description: private address of the frontend
value: { get_attr: [ wordpress, first_address ] }
priv_addr_db:
description: private address of the db
value: { get_attr: [ mysql, first_address ] }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment