<commit_before>from flask import Blueprint
from flask import render_template, request, redirect
#from cloudmesh.provisioner.cm_launcher import cm_launcher

launch_module = Blueprint('launch  _module', __name__)

#
# ROUTE: launch  
#

# fake list of recipies which we need to get from cm_launcher

launch_recipies = {"india-openstack-essex":
                   [
                    {"name": "Slurm Cluster",
                     "types": ["VM", "baremetal"],
                     "description": "Deploys a Slurm cluster. One of the Vms is the Master, "
                                    "while the others register with the master as worker nodes"
                                    " The master will be the first node in the list"},
                    {"name": "Hadoop",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a haddop cluster on the VMs specified"},
                    {"name": "Ganglia",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Ganglia service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    {"name": "Nagios",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Nagios service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    ],
                   "sierra-openstack-grizzly": 
                   [
                    {"name": "Slurm Cluster",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Slurm cluster. One of the Vms is the Master, "
                                    "while the others register with the master as worker nodes"
                                    " The master will be the first node in the list"},
                    {"name": "Hadoop",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a haddop cluster on the VMs specified"},
                    {"name": "Ganglia",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Ganglia service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    {"name": "Nagios",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Nagios service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    ],
                   }


@launch_module.route('/cm/launch/<host>/<recipie>')
def launch_run ():
    print "implement"
    pass

@launch_module.route('/cm/launch/launch_servers', methods = ["POST"])
def launch_servers():
    <commit_msg>adding different recepy list between clusters<commit_after>from flask import Blueprint
from flask import render_template, request, redirect
#from cloudmesh.provisioner.cm_launcher import cm_launcher

launch_module = Blueprint('launch  _module', __name__)

#
# ROUTE: launch  
#

# fake list of recipies which we need to get from cm_launcher

launch_recipies = {"india-openstack-essex":
                   [
                    {"name": "Slurm Cluster",
                     "types": ["VM", "baremetal"],
                     "description": "Deploys a Slurm cluster. One of the Vms is the Master, "
                                    "while the others register with the master as worker nodes"
                                    " The master will be the first node in the list"},
                    {"name": "Hadoop",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a haddop cluster on the VMs specified"},
                    {"name": "Ganglia",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Ganglia service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    {"name": "Nagios",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Nagios service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    ],
                   "sierra-openstack-grizzly": 
                   [
                    {"name": "Slurm Cluster",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Slurm cluster. One of the Vms is the Master, "
                                    "while the others register with the master as worker nodes"
                                    " The master will be the first node in the list"},
                    {"name": "Hadoop",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a haddop cluster on the VMs specified"},
                    {"name": "Ganglia",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Ganglia service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    {"name": "Nagios",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys a Nagios service for the vms specified. "
                                    "The ganglia server will be the first node in the list"},
                    {"name": "R",
                     "types": ["VM", "baremetal"],                     
                     "description": "Deploys R. Demonstrating different recipies for different clusters."},
                    ],
                   }


@launch_module.route('/cm/launch/<host>/<recipie>')
def launch_run ():
    print "implement"
    pass

@launch_module.route('/cm/launch/launch_servers', methods = ["POST"])
def launch_servers():
    
{'fraction_non_alphanumeric': 0.09858044164037855, 'fraction_numerical': 0.0, 'mean_word_length': 1.2430137955429785, 'pattern_counts': {'":': 55, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 24, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '627242', 'n_tokens_mistral': 1587, 'n_tokens_neox': 1417, 'n_words': 517}