Skip to content

Instantly share code, notes, and snippets.

@cryptickp
Created July 28, 2015 14:11
Show Gist options
  • Save cryptickp/b460409cc97a64cf7e89 to your computer and use it in GitHub Desktop.
Save cryptickp/b460409cc97a64cf7e89 to your computer and use it in GitHub Desktop.
heat_template_version: 2015-10-15
description: |
This is a Heat template to deploy single Linux server running a cloud
big data cloud cluster
parameter_groups:
- label: Cluster Settings
parameters:
- clusterName
- region
- label: Cluster Login
parameters:
- clusterLogin
- ssh
- label: Cluster Configuration
parameters:
- flavors
- slaves
parameters:
# Cluster settings
clusterName:
label: Cluster Name
description: Specify a name to identify and distinguish the cluster
type: string
default: cbd_heat_cluster
constraints:
- allowed_pattern: "^[a-zA-Z][a-zA-Z0-9-]*$"
description: Must begin with a letter and contain only alphanumeric characters.
region:
label: Cluster Region
description: Specify the region in which to create the cluster
type: string
default: DFW
constraints:
- allowed_values:
- DFW
- ORD
- SYD
- HKG
- IAD
- LON
description: Must be a valid data center.
# Cluster login
clusterLogin:
label: Cluster Username
description: |
Specify a user that will be created on all nodes for access to and administration of the cluster.
type: string
default: cbd_heat_user
constraints:
- allowed_pattern: "^[a-zA-Z][a-zA-Z]*$"
description: |
Must only contain alphabets.
ssh:
label: SSH key
description: |
Optional: Allows login using SSH key, provide only already created SSH key name .
type: string
default: ''
#Cluster Configuration
flavors:
label: Storage
type: string
default: 2 vCPU(s), 7.5 GB RAM, 1.25 TB Disk
description: |
Cluster flavors specification
constraints:
- allowed_values:
- 2 vCPU(s), 7.5 GB RAM, 1.25 TB Disk
- 4 vCPU(s), 15 GB RAM, 2.5 TB Disk
- 8 vCPU(s), 30 GB RAM, 5.0 TB Disk
- 18 vCPU(s), 60 GB RAM, 10.0 TB Disk
description: |
Must be a valid flavor type.
slaves:
label: Number of slave Nodes
description: |
Number of nodes(datanode, gateway and namenode) within cluster to be created.
type: number
default: 2
constraints:
- range:
min: 1
max: 8
description: Must be between 1 and 8 nodes.
resources:
cbd_cluster:
type: "Rackspace::Cloud::BigData"
properties:
clusterName: CLUSTER_NAME
stackId: HADOOP_HDP2_2
flavor: FLAVOR
numSlaveNodes: SLAVE_NODES
publicKeyName: [public key name]
publicKey: [public key goes here]
params:
SLAVE_NODES: {get_param: slaves}
CLUSTER_NAME: {get_param: clusterName}
FLAVOR: {get_param: flavors}
outputs:
cluster_id:
value: { get_attr: [cbd_cluster, clusterId] }
description: Cloud Big Data Cluster ID
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment