jsPerf.app is an online JavaScript performance benchmark test runner & jsperf.com mirror. It is a complete rewrite in homage to the once excellent jsperf.com now with hopefully a more modern & maintainable codebase.
jsperf.com URLs are mirrored at the same path, e.g:
https://jsperf.com/negative-modulo/2
Can be accessed at:
https://jsperf.app/negative-modulo/2
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<header>
<nav class="navbar navbar-default" role="navigation">
<div class="container-fluid">
<!-- Mobile navigation burger -->
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="/" data-event-category="Navigation" data-event="Banner" title="Cloudera Director">
<img src="/img/cloudera_director.png" alt="Cloudera Director">
</a>
</div><!-- .navbar-header -->
<!-- Collect the nav links, forms, and other content for toggling -->
<div class="collapse navbar-collapse" id="navbar-collapse">
<ul class="nav navbar-nav navbar-right">
<!-- ko if: currentUser -->
<li class="dropdown" data-bind="visible: currentUser.username">
<a href="#" class="btn btn-default navbar-btn" data-toggle="dropdown">
<span data-bind="text: currentUser.username">admin</span>
<span class="caret"></span>
</a>
<ul class="dropdown-menu" role="menu">
<li><a href="#" data-event-category="Navigation" data-event="Change Password" data-bind="click: currentUser.onChangePassword">Change password</a></li>
<!-- ko if: currentUser.isAdmin -->
<li><a href="/users.html" data-event-category="Navigation" data-event="Manage Users">Manage Users</a></li>
<!-- /ko -->
<li role="presentation" class="divider"></li>
<li><a href="/login.html" data-event-category="Navigation" data-event="Logout">Logout</a></li>
</ul>
</li>
<!-- /ko -->
<li class="">
<a href="#" class="btn btn-link navbar-btn" title="Help" data-toggle="dropdown">
<span class="icon circle-question-mark small gray-dark"></span>
</a>
<ul class="dropdown-menu" role="menu">
<li><a href="/api-console" data-event-category="Navigation" data-event="API Console" target="_blank">API Console</a></li>
<li><a href="http://tiny.cloudera.com/director-intro-1.5" data-event-category="Navigation" data-event="Documentation" target="_blank">Documentation</a></li>
<li><a href="#about" data-toggle="modal" data-event-category="Navigation" data-event="About">About</a></li>
</ul>
</li>
</ul>
</div><!-- /.navbar-collapse -->
</div><!-- /.container-fluid -->
</nav>
</header>
<div id="about" class="modal fade" tabindex="-1" role="dialog">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title">About</h4>
</div>
<div class="modal-body">
<!-- ko if: currentVersion -->
<p><strong>Version</strong>: Cloudera Director <span data-bind="text: currentVersion.productVersion">1.5.0-SNAPSHOT</span></p>
<p><strong>Server time</strong>: <span data-bind="text: currentVersion.currentServerTime">2015-Apr-21 19:03:57 UTC</span></p>
<!-- /ko -->
<p>Copyright © 2014 Cloudera, Inc. All rights reserved.</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
</div>
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div><!-- /.modal -->
<!-- ko if: currentUser -->
<!-- ko with: currentUser.passwordModal -->
<div class="modal fade" tabindex="-1" role="dialog" aria-labelledby="Change password" aria-hidden="true" data-bind="modal: showDialog">
<div class="modal-dialog modal-md form-horizontal">
<div class="modal-content">
<form>
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<!-- ko if: isChangingOwn --><!-- /ko -->
<!-- ko ifnot: isChangingOwn -->
<h4 class="modal-title">Change password for <span data-bind="text: username"></span></h4>
<!-- /ko -->
</div>
<div class="modal-body">
<div class="alert alert-danger" role="alert" data-bind="visible: error" style="display: none;">
<span data-bind="text: error"></span>
</div>
<!-- ko if: isChangingOwn --><!-- /ko -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !password.isValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Password</label>
<div class="col-md-5 col-sm-6 col-xs-7">
<input type="password" class="form-control" data-bind="textInput: password">
<p class="help-block" data-bind="visible: highlightErrors" style="display: none;">
<span class="small text-danger" data-bind="text: password.error"></span>
</p>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !confirmPassword.isValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Confirm password</label>
<div class="col-md-5 col-sm-6 col-xs-7">
<input type="password" class="form-control" data-bind="textInput: confirmPassword">
<p class="help-block" data-bind="visible: highlightErrors" style="display: none;">
<span class="small text-danger" data-bind="text: confirmPassword.error"></span>
</p>
</div>
</div>
</div>
<div class="modal-footer">
<span data-bind="if: isPasswordChanged" class="text-success"></span>
<button type="button" class="btn btn-link" data-dismiss="modal">Cancel</button>
<button type="submit" class="btn btn-primary" data-bind="click: save, enable: enableSave">Save changes<span data-bind="visible: isSaving" style="display: none;">...</span></button>
</div>
</form>
</div>
</div>
</div>
<!-- /ko -->
<!-- /ko -->
<section class="container wizard form-horizontal" data-bind="with: wizard">
<div data-bind="visible: $root.currentUser.isAdmin()">
<!-- ko with: steps[0] -->
<section data-bind="visible: isStepSelected" style="display: none;">
<h2>Add Cloudera Manager</h2>
<fieldset class="well well-sm">
<div class="form-horizontal row" role="form">
<div class="col-xs-6">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Environment</label>
<div class="col-md-8 col-sm-7 col-xs-7" data-bind="if: !showEnvironmentSelection()"></div>
<div data-bind="if: showEnvironmentSelection()">
<div class="col-md-5 col-sm-5 col-xs-5">
<select class="form-control" data-bind="value: environmentName">
<option value="">Select an Environment</option>
<!-- ko if: environmentSources().length > 0 -->
<optgroup label="All Environments" data-bind="foreach: environmentSources">
<option data-bind="value: $data, text: $data" value="myenv">myenv</option>
</optgroup>
<!-- /ko -->
<option data-bind="value: ADD_NEW" value="__ADD_NEW__">Add Environment</option>
</select>
</div>
<div class="col-md-1 col-sm-2 col-xs-2">
<ko-help-icon data-title="Environment"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Environment">
<span class="help-content" data-bind="template: { nodes: content }">
Select an Environment in which you want to add a cluster. If there are no available Environments you can select the option 'Add Environment' and create one.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
</div><!-- .col -->
</div><!-- .form-horizontal -->
</fieldset>
<div data-bind="if: !_.isEmpty(environmentName())">
<div class="panel panel-default">
<div class="panel-body">
<!-- ko with: deployment -->
<div class="form-group" data-bind="css: { 'has-error' : highlightErrors() && !isNameValid() }">
<label class="col-md-3 col-sm-4 col-xs-5 control-label">Cloudera Manager name</label>
<div class="col-md-3 col-sm-4 col-xs-5">
<input type="text" class="form-control" data-bind="textInput: name">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Cloudera Manager name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Cloudera Manager name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error' : highlightErrors() && !isTemplateValid() }">
<label class="col-md-3 col-sm-4 col-xs-5 control-label">Instance Template</label>
<div class="col-md-3 col-sm-4 col-xs-5">
<span class="select-with-button">
<select class="form-control" data-bind="options: instanceTemplateList._allTemplates, optionsCaption: 'Select a Template', value: selectedTemplateName"><option value="">Select a Template</option><option value="atemplate">atemplate</option><option value="Create New Instance Template">Create New Instance Template</option></select>
<button class="btn btn-default" data-bind="visible: selectedTemplateName, click: viewCurrentTemplate" style="display: none;">Edit</button>
</span>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Instance Template"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Instance Template">
<span class="help-content" data-bind="template: { nodes: content }">
Instance type to use for this Cloudera Manager.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<fieldset class="form-section">
<!-- ko with: $parent.databaseSelector -->
<h4>Database Server</h4>
<div class="form-group">
<label class="col-md-3 col-sm-4 col-xs-5 control-label">
</label>
<div class="col-md-3 col-sm-4 col-xs-5">
<span class="select-with-button">
<select class="form-control" data-width="75%" data-bind="dropdown: true,
dropdownOptions: {values: databaseServers, value: selected},
value: selected" style="display: none;">
<optgroup label="">
<option value="CREATE_NEW">Create New RDS Server</option>
<option value="USE_EXISTING">Register Existing DB Server</option>
</optgroup>
<optgroup label="">
<option data-subtext="(default)" value="USE_EMBEDDED">Embedded DB</option>
<!-- ko foreach: databaseServers --><!-- /ko -->
</optgroup>
</select><div class="btn-group bootstrap-select form-control" style="width: 75%;"><button type="button" class="btn dropdown-toggle selectpicker btn-default" data-toggle="dropdown" title="Embedded DB"><span class="filter-option pull-left">Embedded DB</span> <span class="caret"></span></button><div class="dropdown-menu open"><ul class="dropdown-menu inner selectpicker" role="menu"><li class="dropdown-header" data-original-index="null"><span class="text"></span></li><li data-original-index="0"><a tabindex="0" class="opt " data-optgroup="1" data-normalized-text="<span class="text">Create New RDS Server</span>"><span class="text">Create New RDS Server</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="1"><a tabindex="0" class="opt " data-optgroup="1" data-normalized-text="<span class="text">Register Existing DB Server</span>"><span class="text">Register Existing DB Server</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li class="divider" data-original-index="null"></li><li class="dropdown-header" data-original-index="null"><span class="text"></span></li><li data-original-index="2" class="selected"><a tabindex="0" class="opt " data-optgroup="2" data-normalized-text="<span class="text">Embedded DB<small class="muted text-muted">(default)</small></span>"><span class="text">Embedded DB<small class="muted text-muted">(default)</small></span><span class="glyphicon glyphicon-ok check-mark"></span></a></li></ul></div></div>
<span class="action-buttons">
<a class="btn btn-link" data-bind="visible: viewEnabled, click: editDB" style="display: none;">View</a>
<a class="btn btn-default" data-bind="visible: editEnabled, click: editDB" style="display: none;">Edit</a>
</span>
</span>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Database Server"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Database Server">
<span class="help-content" data-bind="template: { nodes: content }">
External database server to use for this Cloudera Manager.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
<ko-modal params="showDialog: showDialog,
okButtonText: 'OK',
title: 'Database Server',
viewModel: currentDatabase,
closeVisible: viewing,
okVisible: editing,
cancelVisible: editing,
onOK: onOK,
onDismiss: onDismiss"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<div class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" data-bind="modal: show, attr: { 'aria-labelledby': title }" aria-labelledby="Database Server">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<form data-bind="submit: onOK">
<div class="modal-header">
<button type="button" class="close" data-bind="click: onDismiss"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title" data-bind="text: title">Database Server</h4>
</div>
<div class="modal-body form-horizontal" data-bind="template: { nodes: content, data: viewModel }">
<form data-bind="submit: $parent.onOK">
<!-- name -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isNameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Name</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: editable, textInput: name" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="html: nameErrorMessage">This name is not valid. Click ? for more details.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="Name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- hostname -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isHostnameValid() },
visible: !newHostMode()">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Hostname</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: editable, textInput: hostname" placeholder="1.2.3.4" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isHostnameValid()" style="display: none;">
<span class="small text-danger" data-bind="html: 'Please enter a hostname or an ip address. Hostnames are alphanumeric words separated by dots. Valid ip addresses have four numbers.'">Please enter a hostname or an ip address. Hostnames are alphanumeric words separated by dots. Valid ip addresses have four numbers.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="Hostname"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Hostname">
<span class="help-content" data-bind="template: { nodes: content }">
The fully qualified domain name, or IP address of the database server.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- port -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isPortValid() },
visible: !newHostMode()">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">DB Port</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="number" min="1" max="65535" class="form-control" data-bind="enable: editable, textInput: port" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isPortValid()" style="display: none;">
<span class="small text-danger" data-bind="html: 'This must be an integer number greater than 0.'">This must be an integer number greater than 0.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="DB Port"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="DB Port">
<span class="help-content" data-bind="template: { nodes: content }">
The TC/IP port to connect to the database server.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- username -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isUsernameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">DB Username</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: editable, textInput: username" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isUsernameValid()" style="display: none;">
<span class="small text-danger" data-bind="html: '<p>The following characters are allowed:</p><p>a-z, 0-9, _</p><p>The following character(s) are allowed except at the beginning:</p><p>hyphen (-)</p><p>Should be between 1 and 32 characters in length.</p>'"><p>The following characters are allowed:</p><p>a-z, 0-9, _</p><p>The following character(s) are allowed except at the beginning:</p><p>hyphen (-)</p><p>Should be between 1 and 32 characters in length.</p></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="DB Username"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="DB Username">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>a-z, 0-9, _</p><p>The following character(s) are allowed except at the beginning:</p><p>hyphen (-)</p><p>Should be between 1 and 32 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- password -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isPasswordValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">DB Password</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="password" class="form-control" data-bind="enable: editable, textInput: password" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isPasswordValid()" style="display: none;">
<span class="small text-danger" data-bind="html: 'Database Password must contain 8-30 alphanumeric characters.'">Database Password must contain 8-30 alphanumeric characters.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="DB Password"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="DB Password">
<span class="help-content" data-bind="template: { nodes: content }">
Password must contain 8-30 alphanumeric characters.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- type -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Type</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<select class="form-control" data-bind="enable: editable,
options: databaseTypes,
optionsText: optionsText,
optionsValue: optionsValue,
value: type" disabled=""><option value="MYSQL">MySQL</option><option value="POSTGRESQL">PostgreSQL</option><option value="ORACLE">Oracle</option></select>
</div>
</div>
<!-- rds only stuff -->
<div data-bind="visible: showConfigSection" style="display: none;">
<!-- config -->
<div data-bind="with: config">
<!-- engine version -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">
Engine Version
</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(),
textInput: engineVersion" disabled="">
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: $parent.editable()" style="display: none;">
<ko-help-icon data-title="Name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- instanceClass -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isInstanceClassValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Instance Class</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<div class="input-group">
<input type="text" class="form-control" data-bind="enable: $parent.editable(),
textInput: instanceClass,
typeahead: { source: allInstanceClasses, minLength: 0 }" disabled="" autocomplete="off">
<div class="input-group-btn" data-bind="if: $parent.editable()"></div>
</div>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && instanceClassErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: instanceClassErrorMessage">Instance Class cannot be empty.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Type"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Type">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Select an instance type as per the needs of the processes to be run on this instance.</p>
<p><a data-bind="urlByKey: 'awsRdsInstanceClass'" target="_blank" href="http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- allocated storage -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isAllocatedStorageValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Allocated Storage</label>
<div class="col-md-2 col-sm-3 col-xs-3 text-nowrap">
<div class="input-group">
<input type="number" class="form-control text-right" data-bind="enable: $parent.editable(),
textInput: allocatedStorage,
attr: {min: MIN_ALLOCATED_STORAGE_SIZE_GB}" disabled="" min="5">
<span class="input-group-addon">GB</span>
</div>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && allocatedStorageErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: allocatedStorageErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1 col-md-offset-1 col-sm-offset-1">
<ko-help-icon data-title="Allocated Storage"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Allocated Storage">
<span class="help-content" data-bind="template: { nodes: content }">
<p>How much storage, in gigabytes, to allocate for your DB instance.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- vpc security group ids -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isVpcSecurityGroupIdsValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">VPC Security Groups</label>
<div class="col-md-5 col-sm-6 col-xs-7" data-bind="css: {'col-md-3 col-sm-3 col-xs-3': _vpcSecurityGroupIds().length === 0}">
<ko-add-remove-list params="list: _vpcSecurityGroupIds,
editable: $parent.editable,
placeholder: VPC_SECURITY_GROUP_PREFIX + '...'"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<ul class="list-unstyled">
<li class="row" data-bind="visible: list().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button type="button" class="btn btn-default" data-bind="click: function() { addItem({}, $element); }">+</button>
</div>
</li>
<li class="row" data-bind="foreach: list">
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()},
enable: $parent.editable(),
textInput: value,
attr: {placeholder: $parent.placeholder}" disabled="" placeholder="sg-...">
</div>
<div class="col-md-3 col-sm-3 col-xs-3 text-nowrap" data-bind="visible: $parent.editable()" style="display: none;">
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.removeItem($data, $element); }">-</button>
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.addItem($data, $element); }">+</button>
</div>
</li>
</ul>
</ko-add-remove-list>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && vpcSecurityGroupIdsErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: vpcSecurityGroupIdsErrorMessage">This value must begin with 'sg-'.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Security groups IDs"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Security groups IDs">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Specify the list of security group IDs. Must begin with 'sg-'.</p>
<p><a data-bind="urlByKey: 'awsRdsSecurityGroups'" target="_blank" href="http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Overview.RDSSecurityGroups.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- db subnet group name -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isSubnetGroupNameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Subnet Group</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(), textInput: dbSubnetGroupName" disabled="">
<p class="help-block" data-bind="visible: $parent.highlightErrors() && subnetGroupNameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: subnetGroupNameErrorMessage">Database Subnet Group name cannot be empty.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: $parent.editable()" style="display: none;">
<ko-help-icon data-title="Subnet Group"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Subnet Group">
<span class="help-content" data-bind="template: { nodes: content }">
A DB subnet group is a collection of subnets (typically private) that you create for a VPC and that you then designate for your DB instances. A DB subnet group allows you to specify a particular VPC when you create DB instances.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
</div>
<!-- tags -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Tags</label>
<div class="col-md-8 col-sm-8 col-xs-6">
<ul class="list-unstyled">
<li class="row" data-bind="visible: _tags().length !== 0" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Name</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Value</p>
</div>
</li>
<li class="row" data-bind="visible: _tags().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button type="button" class="btn btn-default" data-bind="click: function() { _tags.insertAfter({}, $element); }">+</button>
</div>
</li>
<!-- ko foreach: _tags --><!-- /ko -->
</ul>
</div>
</div>
</div>
<!-- This button makes it so if a user hits enter while in a text box-->
<!-- the button performs the onsubmit, to the outer <form> -->
<button style="display: none;"></button>
</form>
</div>
<div class="modal-footer">
<button name="close" type="button" class="btn btn-primary" data-bind="visible: closeVisible, click: onDismiss">Close</button>
<button name="cancel" type="button" class="btn btn-link" data-bind="visible: cancelVisible, click: onDismiss" style="display: none;">Cancel</button>
<button name="reset" type="reset" class="btn btn-link" data-bind="visible: resetVisible, click: onReset" style="display: none;">Reset</button>
<button name="ok" type="submit" data-bind="visible: okVisible, click: onOK, attr: { class : okButtonClass }" class="btn btn-primary" style="display: none;">
<span data-bind="text: okButtonText">OK</span>
<span data-bind="visible: isSaving" style="display: none;">...</span>
</button>
</div>
</form>
</div>
</div>
</div>
</ko-modal>
</div>
<!-- /ko -->
</fieldset>
<fieldset class="form-section">
<h4>Configurations (optional)</h4>
<div class="form-group">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-3 col-sm-4 col-xs-5">
<button type="button" class="btn btn-default" data-bind="click: configure">
Cloudera Manager Configuration
</button>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="">
<span class="help-content" data-bind="template: { nodes: content }">Configuration for the Cloudera Manager services & hosts.</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-3 col-sm-4 col-xs-5">
<div class="checkbox">
<label>
<input type="checkbox" data-bind="checked: enableEnterpriseTrial"> Enable Cloudera Enterprise trial
</label>
</div>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="">
<span class="help-content" data-bind="template: { nodes: content }">This activates the 60-Day Cloudera Enterprise Trial. Once the trial has concluded, the Cloudera Enterprise features in Cloudera Manager will be disabled until you obtain and upload a license.</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error' : highlightErrors() && !isRepositoryValid() }">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-3 col-sm-4 col-xs-5">
<div class="checkbox">
<label>
<input type="checkbox" data-bind="checked: overrideDefaultRepos"> Override default Cloudera Manager repository
</label>
</div>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="">
<span class="help-content" data-bind="template: { nodes: content }">Override default Cloudera Manager package repositories.</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="visible: overrideDefaultRepos, css: { 'has-error' : highlightErrors() && !isRepositoryValid() }" style="display: none;">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-7 col-sm-6 col-xs-5">
<input type="text" class="form-control" data-bind="textInput: _repository" placeholder="">
<p class="help-block"><small><b>Example</b> http://archive.cloudera.com/cm5/redhat/6/x86_64/cm/5/</small></p>
</div>
</div>
</fieldset>
<!-- ko with: configurationModal -->
<ko-modal params="showDialog: showDialog,
okButtonText: 'Save changes',
title: title,
viewModel: $data,
closeVisible: viewing,
okVisible: editable,
resetVisible: editable,
cancelVisible: editable,
onOK: apply,
onReset: reset,
onDismiss: hide"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<div class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" data-bind="modal: show, attr: { 'aria-labelledby': title }" aria-labelledby="Roles Configuration" style="display: none;">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<form data-bind="submit: onOK">
<div class="modal-header">
<button type="button" class="close" data-bind="click: onDismiss"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title" data-bind="text: title">Roles Configuration</h4>
</div>
<div class="modal-body form-horizontal" data-bind="template: { nodes: content, data: viewModel }">
<!-- ko foreach: filters -->
<div class="form-group">
<label class="col-md-1 col-sm-2 col-xs-3 control-label text-left" data-bind="text: label">Service</label>
<div class="col-md-5 col-sm-6 col-xs-7">
<select class="form-control" data-bind="options: availableValues,
optionsText: 'label',
optionsValue: 'name',
value: selectedValue"><option value="HDFS">HDFS</option><option value="HIVE">Hive</option><option value="HUE">Hue</option><option value="OOZIE">Oozie</option><option value="SQOOP">Sqoop 2</option><option value="YARN">YARN</option><option value="ZOOKEEPER">ZooKeeper (modified)</option></select>
</div>
<div class="col-md-1 col-sm-2 col-xs-2">
<ko-help-icon data-bind="attr: { 'data-title': label }" data-title="Service"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Service">
<span class="help-content" data-bind="template: { nodes: content }">
<p data-bind="text: $parent.description">Select a cluster service to filter roles.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<label class="col-md-1 col-sm-2 col-xs-3 control-label text-left" data-bind="text: label">Role</label>
<div class="col-md-5 col-sm-6 col-xs-7">
<select class="form-control" data-bind="options: availableValues,
optionsText: 'label',
optionsValue: 'name',
value: selectedValue"><option value="SERVER">Server (modified)</option></select>
</div>
<div class="col-md-1 col-sm-2 col-xs-2">
<ko-help-icon data-bind="attr: { 'data-title': label }" data-title="Role"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Role">
<span class="help-content" data-bind="template: { nodes: content }">
<p data-bind="text: $parent.description">Select a cluster service role to configure.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- /ko-->
<hr>
<!-- ko if: selectedConfigurations().length -->
<!-- ko foreach: selectedConfigurations -->
<!-- ko if: configurations().length -->
<!-- ko if: title -->
<a class="collapsible-section-header" data-toggle="collapse" aria-expanded="false" data-bind="attr: {href: '.role-configuration-' + $index()}, click: function() { configurationSectionCollapsed(!configurationSectionCollapsed()) }" href=".role-configuration-0">
<h4><span class="glyphicon small glyphicon-chevron-down" aria-hidden="true" data-bind="css: { 'glyphicon-chevron-right': configurationSectionCollapsed, 'glyphicon-chevron-down': !configurationSectionCollapsed() }">
</span> <span data-bind="text: title">masters</span></h4>
</a>
<!-- /ko -->
<div class="collapse in role-configuration-0" data-bind="css: 'role-configuration-' + $index()">
<ul data-bind="foreach: configurations" class="list-unstyled">
<li>
<!-- ko if: widget === 'CUSTOM' -->
<div class="form-group">
<div class="col-md-4 col-sm-4 col-xs-4" data-bind="css: { 'has-error' : highlightErrors() && nameErrorMessage() }">
<input type="text" class="form-control" placeholder="Name" data-bind="textInput: proposedName">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4" data-bind="css: { 'has-error' : highlightErrors() && valueErrorMessage() }">
<input type="text" class="form-control" placeholder="Value" data-bind="textInput: proposedValue">
<p class="help-block" data-bind="visible: highlightErrors() && valueErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: valueErrorMessage"></span>
</p>
</div>
<div class="col-md-2 col-sm-2 col-xs-2 text-nowrap">
<button tabindex="-1" class="btn btn-default" type="button" data-bind="disable: $parent.removeConfigurationDisabled,
click: function() { $parent.configurations.removeItem($data, $element); }" disabled="">-</button>
<button tabindex="-1" class="btn btn-default" type="button" data-bind="click: function() { $parent.configurations.insertAfter($data, $element); }">+</button>
</div>
</div>
<!-- /ko -->
</li>
</ul>
</div>
<!-- /ko --><!-- title -->
<!-- ko if: configurations().length -->
<!-- ko if: title -->
<a class="collapsible-section-header" data-toggle="collapse" aria-expanded="false" data-bind="attr: {href: '.role-configuration-' + $index()}, click: function() { configurationSectionCollapsed(!configurationSectionCollapsed()) }" href=".role-configuration-1">
<h4><span class="glyphicon small glyphicon-chevron-down" aria-hidden="true" data-bind="css: { 'glyphicon-chevron-right': configurationSectionCollapsed, 'glyphicon-chevron-down': !configurationSectionCollapsed() }">
</span> <span data-bind="text: title">workers</span></h4>
</a>
<!-- /ko -->
<div class="collapse in role-configuration-1" data-bind="css: 'role-configuration-' + $index()">
<ul data-bind="foreach: configurations" class="list-unstyled">
<li>
<!-- ko if: widget === 'CUSTOM' -->
<div class="form-group">
<div class="col-md-4 col-sm-4 col-xs-4" data-bind="css: { 'has-error' : highlightErrors() && nameErrorMessage() }">
<input type="text" class="form-control" placeholder="Name" data-bind="textInput: proposedName">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4 has-error" data-bind="css: { 'has-error' : highlightErrors() && valueErrorMessage() }">
<input type="text" class="form-control" placeholder="Value" data-bind="textInput: proposedValue">
<p class="help-block" data-bind="visible: highlightErrors() && valueErrorMessage()">
<span class="small text-danger" data-bind="text: valueErrorMessage">The value is missing.</span>
</p>
</div>
<div class="col-md-2 col-sm-2 col-xs-2 text-nowrap">
<button tabindex="-1" class="btn btn-default" type="button" data-bind="disable: $parent.removeConfigurationDisabled,
click: function() { $parent.configurations.removeItem($data, $element); }" disabled="">-</button>
<button tabindex="-1" class="btn btn-default" type="button" data-bind="click: function() { $parent.configurations.insertAfter($data, $element); }">+</button>
</div>
</div>
<!-- /ko -->
</li>
</ul>
</div>
<!-- /ko --><!-- title -->
<!-- /ko --><!-- foreach -->
<!-- /ko --><!-- selectedConfigurations().length -->
</div>
<div class="modal-footer">
<button name="close" type="button" class="btn btn-primary" data-bind="visible: closeVisible, click: onDismiss" style="display: none;">Close</button>
<button name="cancel" type="button" class="btn btn-link" data-bind="visible: cancelVisible, click: onDismiss">Cancel</button>
<button name="reset" type="reset" class="btn btn-link" data-bind="visible: resetVisible, click: onReset">Reset</button>
<button name="ok" type="submit" data-bind="visible: okVisible, click: onOK, attr: { class : okButtonClass }" class="btn btn-primary">
<span data-bind="text: okButtonText">Save changes</span>
<span data-bind="visible: isSaving" style="display: none;">...</span>
</button>
</div>
</form>
</div>
</div>
</div>
</ko-modal>
<!-- /ko -->
<!-- ko with: instanceTemplateList.templateModal -->
<div class="modal fade" tabindex="-1" role="dialog" aria-labelledby="Instance Template" aria-hidden="true" data-bind="modal:showDialog" style="display: none;">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title">Instance Template</h4>
</div>
<div class="modal-body form-horizontal">
<!-- ko with: instanceTemplate -->
<div class="form-group" data-bind="visible: !isTemplateApplied(), css: { 'has-error': highlightErrors() && !isNameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Instance Template name</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: isNewMode, textInput: name" placeholder="">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: isNewMode">
<ko-help-icon data-title="Instance Template name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Instance Template name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isTypeValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Type</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<div class="input-group">
<input type="text" class="form-control" data-bind="enable: editable,
textInput: type,
typeahead: {
source: allTypes,
minLength: 0,
items: 'all' }" autocomplete="off"><ul class="typeahead dropdown-menu" role="listbox" style="top: 32px; left: 0px; display: none;"><li class=""><a href="#" role="option">t2.<strong>me</strong>dium</a></li><li class="active"><a href="#" role="option">m3.<strong>me</strong>dium</a></li></ul>
<div class="input-group-btn" data-bind="if: editable">
<button tabindex="-1" type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
<span class="caret"></span>
</button>
<ul class="dropdown-menu pull-right typeahead" role="menu">
<!-- ko foreach: allTypes -->
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">t2.micro</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">t2.small</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">t2.medium</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.medium</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">g2.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">hs1.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.8xlarge</a></li>
<!-- /ko -->
</ul>
</div>
</div>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Type"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Type">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Select an instance type as per the needs of the processes to be run on this instance.</p>
<p><a data-bind="urlByKey: 'awsInstType'" target="_blank" href="http://aws.amazon.com/ec2/instance-types/">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isImageValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Amazon Machine Image (AMI)</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()}, enable: editable, textInput: image" placeholder="ami-...">
<p class="help-block" data-bind="visible: highlightErrors() && imageErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: imageErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Amazon Machine Image (AMI)"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Amazon Machine Image (AMI)">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Red Hat Enterprise Linux 6.4 (64bit) 64bit PV or HVM AMIs are supported. Must begin with 'ami-'.</p><p>
</p><p><a data-bind="urlByKey: 'awsAmi'" target="_blank" href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AMIs.html">More information</a></p>
<p><a data-bind="urlByKey: 'awsAmiInstMatrix'" target="_blank" href="https://aws.amazon.com/amazon-linux-ami/instance-type-matrix/">Compatibility matrix</a></p>
<p><a data-bind="urlByKey: 'redHatPartners'" target="_blank" href="http://aws.amazon.com/partners/redhat/">Red Hat Enterprise Linux AMI IDs</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Tags</label>
<div class="col-md-8 col-sm-8 col-xs-6">
<ul class="list-unstyled">
<li class="row" data-bind="visible: _tags().length !== 0">
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Name</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Value</p>
</div>
</li>
<li class="row" data-bind="visible: _tags().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button class="btn btn-default" data-bind="click: function() { _tags.insertAfter({}, $element); }">+</button>
</div>
</li>
<!-- ko foreach: _tags -->
<li class="row" data-bind="css: { 'has-error': $parent.highlightErrors() && !isValid() }">
<div class="col-md-4 col-sm-4 col-xs-4">
<input type="text" class="form-control" data-bind="textInput: name, enable: $parent.editable()">
</div>
<div class="col-md-4 col-sm-4 col-xs-4">
<input type="text" class="form-control" data-bind="textInput: value, enable: $parent.editable()">
</div>
<div class="col-md-2 col-sm-2 col-xs-2 text-nowrap" data-bind="visible: $parent.editable()">
<button class="btn btn-default" data-bind="click: function() { $parent._tags.removeItem($data, $element); }">-</button>
<button class="btn btn-default" data-bind="click: function() { $parent._tags.insertAfter($data, $element); }">+</button>
</div>
</li>
<!-- /ko -->
</ul>
</div>
</div>
<!-- ko with: config -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">IAM Profile Name</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(), textInput: iamProfileName" placeholder="">
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="IAM Profile Name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="IAM Profile Name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>IAM roles help with key distribution. This role is optional and is used when launching a new instance.</p>
<a data-bind="urlByKey: 'awsIamRole'" target="_blank" href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html">More information</a>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Instance name prefix</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(), textInput: instanceNamePrefix" placeholder="">
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Instance name prefix"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Instance name prefix">
<span class="help-content" data-bind="template: { nodes: content }">
Prefix that Cloudera Director should use when naming the instances (this is not part of the hostname).
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isRootVolumeValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Root volume size</label>
<div class="col-md-2 col-sm-3 col-xs-3 text-nowrap">
<div class="input-group">
<input type="number" min="0" class="form-control text-right" data-bind="enable: $parent.editable(), textInput: rootVolumeSizeGB" placeholder="">
<span class="input-group-addon">GB</span>
</div>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && rootVolumeErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: rootVolumeErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1 col-md-offset-1 col-sm-offset-1">
<ko-help-icon data-title="Root volume size"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Root volume size">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Specify a size for the root volume (in GB). Cloudera Director will automatically expand the filesystem so that you can use all the available disk space for your application.</p>
<p><a data-bind="urlByKey: 'awsExpandPartition'" target="_blank" href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/storage_expand_partition.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isSubnetIdValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">VPC subnet ID</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()}, enable: $parent.editable(), textInput: subnetId" placeholder="subnet-...">
<p class="help-block" data-bind="visible: $parent.highlightErrors() && subnetIdErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: subnetIdErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="VPC subnet ID"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="VPC subnet ID">
<span class="help-content" data-bind="template: { nodes: content }">
<p>ID of the VPC subnet. Must begin with 'subnet-'.</p>
<p><a data-bind="urlByKey: 'awsSubId'" target="_blank" href="http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Subnets.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isSecurityGroupsIdsValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Security groups IDs</label>
<div class="col-md-5 col-sm-6 col-xs-7" data-bind="css: {'col-md-3 col-sm-3 col-xs-3': _securityGroupsIds().length === 0}">
<ko-add-remove-list params="list: _securityGroupsIds,
editable: $parent.editable,
placeholder: 'sg-...'"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<ul class="list-unstyled">
<li class="row" data-bind="visible: list().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button type="button" class="btn btn-default" data-bind="click: function() { addItem({}, $element); }">+</button>
</div>
</li>
<li class="row" data-bind="foreach: list">
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()},
enable: $parent.editable(),
textInput: value,
attr: {placeholder: $parent.placeholder}" placeholder="sg-...">
</div>
<div class="col-md-3 col-sm-3 col-xs-3 text-nowrap" data-bind="visible: $parent.editable()">
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.removeItem($data, $element); }">-</button>
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.addItem($data, $element); }">+</button>
</div>
</li>
</ul>
</ko-add-remove-list>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && securityGroupsIdsErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: securityGroupsIdsErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Security groups IDs"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Security groups IDs">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Specify the list of security group IDs. Must begin with 'sg-'.</p>
<p><a data-bind="urlByKey: 'awsSecGrp'" target="_blank" href="http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_SecurityGroups.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- /ko -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Bootstrap script</label>
<div class="col-md-5 col-sm-5 col-xs-5">
<ko-file-text-chooser params="valueAccessor: bootstrapScript, editable: editable">
<div class="fileTextChooser" data-bind="css: {'has_error': errorMessage}">
<div class="radio">
<label class="radio-inline">
<input value="fileMode" type="radio" name="fileInput" data-bind="disable: disableComponent, checked: mode">
File Upload
</label>
<label class="radio-inline" data-bind="visible: canFileUpload">
<input value="textMode" type="radio" name="fileInput" data-bind="disable: disableComponent, checked: mode, visible: canFileUpload">
Direct Input
</label>
</div>
<div class="file-controls" data-bind="visible: fileMode">
<input type="text" class="form-control" disabled="disableComponent" data-bind="textInput: fileName, css: { 'has-error' : false }">
<span role="button" class="btn btn-default" tabindex="-1" data-bind="enable: fileMode, disable: disableComponent">
<input type="file" data-bind="event: {change: extractFile},
disable: disableComponent">Choose File
</span>
</div>
<textarea rows="5" class="form-control code" data-bind="event: {focus: $element.select()},
visible: textMode,
textInput: data,
enable: textMode,
attr: {placeholder: placeholder}" spellcheck="false" disabled="" placeholder="" style="display: none;"></textarea>
<p class="help-block" data-bind="visible: errorMessage" style="display: none;">
<span class="small text-danger" data-bind="html: errorMessage">false</span>
</p>
</div>
</ko-file-text-chooser>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Bootstrap script"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Bootstrap script">
<span class="help-content" data-bind="template: { nodes: content }">
Embedded bootstrap script that runs as root and can be used to customize instances immediately after boot. Cloudera Director will automatically retry if the exit code is not 0.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- /ko -->
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary" data-bind="visible: !instanceTemplate.editable()" data-dismiss="modal" style="display: none;">Close</button>
<button type="button" class="btn btn-link" data-bind="visible: instanceTemplate.editable()" data-dismiss="modal">Cancel</button>
<button type="button" class="btn btn-primary" data-bind="visible: instanceTemplate.editable(), click: save, enable: enableSave() && !isSaving()">Save changes<span data-bind="visible: isSaving" style="display: none;">...</span></button>
</div>
</div>
</div>
</div>
<!-- /ko -->
<!-- /ko --> <!-- deployment -->
</div>
</div>
</div>
</section>
<!-- /ko -->
<!-- ko with: steps[1] -->
<section data-bind="visible: isStepSelected">
<h2>Add Cluster</h2>
<fieldset class="well well-sm">
<div class="form-horizontal row" role="form">
<div class="col-xs-6">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Environment</label>
<div class="col-md-8 col-sm-8 col-xs-8" data-bind="visible: options.getEnvironmentName() !== ''">
<p class="form-control-static truncate" data-bind="text: options.getEnvironmentName()">myenv</p>
</div>
<div data-bind="if: showEnvironmentSelection()"></div>
</div><!-- .col -->
</div>
<div class="form-horizontal row" role="form">
<div class="col-xs-6">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Cloudera Manager</label>
<div class="col-md-8 col-sm-8 col-xs-8" data-bind="visible: options.getDeploymentName() !== ''" style="">
<p class="form-control-static truncate" data-bind="text: options.getDeploymentName()">cm1</p>
</div>
<div data-bind="if: showDeploymentSelection()"></div>
</div><!-- .col -->
</div><!-- .form-horizontal -->
</fieldset><!-- .well -->
<!-- ko if: !populatingAllClusterSources() && hasClustersToClone() && showMode() --><!-- /ko -->
<div class="panel panel-default" data-bind="visible: showCluster">
<div class="panel-body">
<fieldset data-bind="with: cluster">
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isNameValid() }">
<label class="col-md-3 col-sm-4 col-xs-5 control-label">Cluster name</label>
<div class="col-md-4 col-sm-5 col-xs-6">
<!-- ko if: isGrowAndShrinkMode --><!-- /ko -->
<!-- ko ifnot: isGrowAndShrinkMode -->
<input type="text" class="form-control" data-bind="textInput: name">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
<!-- /ko -->
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: isNewMode">
<ko-help-icon data-title="Cluster name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Cluster name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<label class="col-md-3 col-sm-4 col-xs-5 control-label">Products</label>
<div class="col-md-4 col-sm-5 col-xs-6">
<ul class="list-unstyled">
<li class="row" data-bind="visible: _productVersions().length !== 0">
<div class="col-md-5 col-sm-5 col-xs-5">
<span class="small form-control-static">Name</span>
</div>
<div class="col-md-3 col-sm-3 col-xs-3">
<span class="small form-control-static">Version</span>
</div>
</li>
<li class="row" data-bind="visible: _productVersions().length === 0" style="display: none;">
<div class="col-md-2 col-sm-2 col-xs-2">
<button class="btn btn-default" data-bind="click: function() { _productVersions.insertAfter({}, element); }">+</button>
</div>
</li>
<!-- ko foreach: _productVersions -->
<li class="row" data-bind="css: { 'has-error': $parent.highlightErrors() && !isValid() }">
<div class="col-md-5 col-sm-5 col-xs-5">
<p class="form-control-static" data-bind="text: name">CDH</p>
</div>
<div class="col-md-3 col-sm-3 col-xs-3">
<!-- ko if: $parent.isNewMode() -->
<input type="text" class="form-control text-right" data-bind="textInput: value">
<!-- /ko -->
<!-- ko ifnot: $parent.isNewMode() --><!-- /ko -->
</div>
<div class="col-md-4 col-sm-4 col-xs-4" data-bind="visible: false" style="display: none;">
<button class="btn btn-default" data-bind="click: function() { $parent._productVersions.removeItem($data, $element); }">-</button>
<button class="btn btn-default" data-bind="click: function() { $parent._productVersions.insertAfter($data, $element); }">+</button>
</div>
</li>
<!-- /ko -->
</ul>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: isNewMode">
<ko-help-icon data-title="Products"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Products">
<span class="help-content" data-bind="template: { nodes: content }">
List the products and their versions that need to be installed. These products must have a corresponding parcel in the Parcel Repositories configured below. The specified version will be used to find a suitable parcel. Specifying a version that points to more than one parcel among those available will result in a configuration error. Specify more granular versions to avoid conflicts.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error' : highlightErrors() && !isServicesValid() }">
<label class="col-md-3 col-sm-4 control-label">Services</label>
<div class="col-md-9 col-sm-8">
<!-- ko ifnot: isGrowAndShrinkMode -->
<div class="radio">
<label>
<input type="radio" name="services" value="coreHadoop" data-bind="enable: isNewMode, checked: _services"> Core Hadoop
</label>
<p class="small help-block" data-bind="text: $data.humanizeServiceTypes($data.servicesByGroupName()['coreHadoop'])">HDFS, Hive, Hue, Oozie, Sqoop 2, YARN, ZooKeeper</p>
</div>
<div class="radio">
<label>
<input type="radio" name="services" value="coreHadoopAndHBase" data-bind="enable: isNewMode, checked: _services"> Core Hadoop with HBase
</label>
<p class="small help-block" data-bind="text: $data.humanizeServiceTypes($data.servicesByGroupName()['coreHadoopAndHBase'])">HBase, HDFS, Hive, Hue, Oozie, Sqoop 2, YARN, ZooKeeper</p>
</div>
<div class="radio">
<label>
<input type="radio" name="services" value="coreHadoopAndImpala" data-bind="enable: isNewMode, checked: _services"> Core Hadoop with Impala
</label>
<p class="small help-block" data-bind="text: $data.humanizeServiceTypes($data.servicesByGroupName()['coreHadoopAndImpala'])">HDFS, Hive, Hue, Impala, Oozie, Sqoop 2, YARN, ZooKeeper</p>
</div>
<div class="radio">
<label>
<input type="radio" name="services" value="coreHadoopAndSearch" data-bind="enable: isNewMode, checked: _services"> Core Hadoop with Search
</label>
<p class="small help-block" data-bind="text: $data.humanizeServiceTypes($data.servicesByGroupName()['coreHadoopAndSearch'])">HDFS, Hive, Hue, Oozie, Solr, Sqoop 2, YARN, ZooKeeper</p>
</div>
<div class="radio" data-bind="visible: cdhMajorVersion() >= 5">
<label>
<input type="radio" name="services" value="coreHadoopAndSpark" data-bind="enable: isNewMode, checked: _services"> Core Hadoop with Spark on YARN
</label>
<p class="small help-block" data-bind="text: $data.humanizeServiceTypes($data.servicesByGroupName()['coreHadoopAndSpark'])">HDFS, Hive, Hue, Oozie, Spark on YARN, Sqoop 2, YARN, ZooKeeper</p>
</div>
<div class="radio">
<label>
<input type="radio" name="services" value="all" data-bind="enable: isNewMode, checked: _services"> All Services
</label>
<p class="small help-block" data-bind="text: $data.humanizeServiceTypes($data.servicesByGroupName()['all'])">Flume, HBase, HDFS, Hive, Hue, Impala, Key-Value Store Indexer, Oozie, Solr, Spark on YARN, Sqoop 2, YARN, ZooKeeper</p>
</div>
<div class="radio" data-bind="visible: isCloneMode() && _services() === 'other'" style="display: none;">
<label>
<input type="radio" name="services" value="other" data-bind="enable: isNewMode, checked: _services"> Other
</label>
<p class="small help-block" data-bind="text: $data.humanizeServiceTypes(services())">HDFS, Hive, Hue, Oozie, Sqoop 2, YARN, ZooKeeper</p>
</div>
<!-- /ko -->
<!-- ko if: isGrowAndShrinkMode --><!-- /ko -->
</div>
</div>
<br>
<!-- this has to be data bound to a ClusterTemplate view model. -->
<div class="col-md-12 col-sm-12 col-xs-12 form-group virtual-instance-groups">
<h4>Instance groups</h4>
<div class="table-bordered">
<table class="table virtual-instance-groups-table">
<thead>
<tr>
<th class="col-md-3 col-sm-3 col-xs-3">
<span>Name</span>
<ko-help-icon data-bind="visible: isNewMode()" params="{ buttonClass: 'btn-xs', iconClass: 'x-small'}" data-title="Name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help btn-xs" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Name">
<span class="help-content" data-bind="template: { nodes: content }"><p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p></span>
<span class="icon circle-question-mark gray x-small" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</th>
<th class="col-md-3 col-sm-3 col-xs-3">
<span>Roles</span>
</th>
<th class="col-md-3 col-sm-3 col-xs-3">
<span>Instance Template</span>
</th>
<th class="col-md-3 col-sm-3 col-xs-3 text-right" colspan="3">
<span>Instance Count</span>
</th>
<!-- instance count edit button -->
<th data-bind="visible: !isViewOnlyMode()" class="col-md-1 col-sm-1 col-xs-1"></th>
<!-- remove/restore button -->
<th data-bind="visible: !isViewOnlyMode()" class="col-md-2 col-sm-2 col-xs-2"></th>
</tr>
</thead>
<tbody>
<!-- ko foreach: _virtualInstanceGroups -->
<tr data-bind="css: { 'deleting-mode': isDeletingMode }">
<td data-bind="css: { 'has-error': !isNameValid() }">
<!-- ko ifnot: isNewMode() --><!-- /ko -->
<!-- ko if: isNewMode() -->
<input type="text" class="form-control" data-bind="hasFocus: newlyAdded(),textInput: name" placeholder="Enter Group name">
<p class="help-block" data-bind="visible: $parent.highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
<!-- /ko -->
<span class="small disabled" data-bind="visible: isDeletingMode" style="display: none;">(To be deleted)</span>
<span class="small disabled" data-bind="visible: isNewMode() && $parent.isGrowAndShrinkMode()" style="display: none;">(To be added)</span>
</td>
<td>
<!-- ko ifnot: isNewMode() || isDeletingMode() --><!-- /ko -->
<!-- ko if: isNewMode() -->
<button type="button" class="btn btn-default" data-bind="visible: newlyAdded(), click: function() { $parent.viewRoleAssignment($data); }" style="display: none;">Assign Roles
</button>
<button type="button" class="btn btn-default" data-bind="visible: !newlyAdded(), click: function() { $parent.viewRoleAssignment($data); }">Edit Roles
</button>
<!-- /ko -->
</td>
<td data-bind="css: { 'has-error': $parent.highlightErrors() && !isTemplateValid() }">
<span data-bind="if: isNewMode() && !isCloned()">
<span class="select-with-button">
<select class="form-control" data-bind="options: instanceTemplateList._allTemplates, optionsCaption: 'Select a Template', value: selectedTemplateName"><option value="">Select a Template</option><option value="atemplate">atemplate</option><option value="Create New Instance Template">Create New Instance Template</option></select>
<button class="btn btn-default" data-bind="visible: selectedTemplateName, click: viewCurrentTemplate">Edit</button>
</span>
</span>
<span data-bind="visible: (!isNewMode() || isCloned()) && !isDeletingMode()" class="text-nowrap" style="display: none;">
<label class="form-control-static">
<a href="#" data-bind="click: viewCurrentTemplate">View Template</a>
</label>
</span>
</td>
<td class="text-right">
<p class="form-control-static" data-bind="visible: !$parent.isViewOnlyMode() && existingInstanceCountModified()" style="display: none;">
New total:</p>
</td>
<td data-bind="css: { 'has-error': $parent.highlightErrors() && !isNewCountValid() }" colspan="2">
<div class="col-md-offset-6 col-sm-offset-6 col-xs-offset-6" data-bind="visible: isNewMode">
<input type="number" min="0" class="form-control text-right" data-bind="textInput: newInstanceCount, disable: name() === 'masters'" disabled="">
</div>
<div data-bind="visible: !isNewMode()" class="text-right" style="display: none;">
<label class="form-control-static" data-bind="visible: !isNewMode(), text: virtualInstances().length" style="display: none;">1</label>
</div>
</td>
<td data-bind="visible: !$parent.isViewOnlyMode()">
<button type="button" class="btn btn-default" data-bind="visible: !isNewMode() && !isDeletingMode(), click: editInstances" style="display: none;">Edit</button>
</td>
<td data-bind="visible: !$parent.isViewOnlyMode()" class="text-right">
<button type="button" class="btn btn-default" data-bind="visible: isDeletingMode, click: undoRemove" style="display: none;">Restore Group</button>
<button type="button" class="btn btn-default" data-bind="visible: !isDeletingMode(), click: function() { $parent.removeVirtualInstanceGroup($data); }">Delete Group</button>
</td>
</tr>
<tr class="extra-information" data-bind="visible: !$parent.isViewOnlyMode() && existingInstancesModified()" style="display: none;">
<td colspan="2"></td>
<td class="text-right">
<p class="disabled small" data-bind="visible: virtualInstancesAdded().length > 0">To be added:</p>
<p class="disabled small" data-bind="visible: virtualInstancesDeleting().length > 0" style="display: none;">To be deleted:</p>
<p class="disabled small" data-bind="visible: virtualInstancesRepairing().length > 0" style="display: none;">To be repaired:</p>
</td>
<td class="text-right">
<p class="small" data-bind="visible: virtualInstancesAdded().length > 0, text: virtualInstancesAdded().length">1</p>
<b><p class="small text-danger" data-bind="visible: virtualInstancesDeleting().length > 0, text: virtualInstancesDeleting().length" style="display: none;">0</p></b>
<p class="small" data-bind="visible: virtualInstancesRepairing().length > 0, text: virtualInstancesRepairing().length" style="display: none;">0</p>
</td>
<td colspan="3"></td>
</tr>
<tr class="extra-information" data-bind="visible : $parent.highlightErrors() && errorMessage()" style="display: none;">
<td colspan="2"></td>
<td colspan="6">
<span class="small text-danger" data-bind="text: errorMessage"></span>
</td>
</tr>
<tr data-bind="css: { 'deleting-mode': isDeletingMode }">
<td data-bind="css: { 'has-error': !isNameValid() }">
<!-- ko ifnot: isNewMode() --><!-- /ko -->
<!-- ko if: isNewMode() -->
<input type="text" class="form-control" data-bind="hasFocus: newlyAdded(),textInput: name" placeholder="Enter Group name">
<p class="help-block" data-bind="visible: $parent.highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
<!-- /ko -->
<span class="small disabled" data-bind="visible: isDeletingMode" style="display: none;">(To be deleted)</span>
<span class="small disabled" data-bind="visible: isNewMode() && $parent.isGrowAndShrinkMode()" style="display: none;">(To be added)</span>
</td>
<td>
<!-- ko ifnot: isNewMode() || isDeletingMode() --><!-- /ko -->
<!-- ko if: isNewMode() -->
<button type="button" class="btn btn-default" data-bind="visible: newlyAdded(), click: function() { $parent.viewRoleAssignment($data); }" style="display: none;">Assign Roles
</button>
<button type="button" class="btn btn-default" data-bind="visible: !newlyAdded(), click: function() { $parent.viewRoleAssignment($data); }">Edit Roles
</button>
<!-- /ko -->
</td>
<td data-bind="css: { 'has-error': $parent.highlightErrors() && !isTemplateValid() }">
<span data-bind="if: isNewMode() && !isCloned()">
<span class="select-with-button">
<select class="form-control" data-bind="options: instanceTemplateList._allTemplates, optionsCaption: 'Select a Template', value: selectedTemplateName"><option value="">Select a Template</option><option value="atemplate">atemplate</option><option value="Create New Instance Template">Create New Instance Template</option></select>
<button class="btn btn-default" data-bind="visible: selectedTemplateName, click: viewCurrentTemplate">Edit</button>
</span>
</span>
<span data-bind="visible: (!isNewMode() || isCloned()) && !isDeletingMode()" class="text-nowrap" style="display: none;">
<label class="form-control-static">
<a href="#" data-bind="click: viewCurrentTemplate">View Template</a>
</label>
</span>
</td>
<td class="text-right">
<p class="form-control-static" data-bind="visible: !$parent.isViewOnlyMode() && existingInstanceCountModified()" style="display: none;">
New total:</p>
</td>
<td data-bind="css: { 'has-error': $parent.highlightErrors() && !isNewCountValid() }" colspan="2">
<div class="col-md-offset-6 col-sm-offset-6 col-xs-offset-6" data-bind="visible: isNewMode">
<input type="number" min="0" class="form-control text-right" data-bind="textInput: newInstanceCount, disable: name() === 'masters'">
</div>
<div data-bind="visible: !isNewMode()" class="text-right" style="display: none;">
<label class="form-control-static" data-bind="visible: !isNewMode(), text: virtualInstances().length" style="display: none;">10</label>
</div>
</td>
<td data-bind="visible: !$parent.isViewOnlyMode()">
<button type="button" class="btn btn-default" data-bind="visible: !isNewMode() && !isDeletingMode(), click: editInstances" style="display: none;">Edit</button>
</td>
<td data-bind="visible: !$parent.isViewOnlyMode()" class="text-right">
<button type="button" class="btn btn-default" data-bind="visible: isDeletingMode, click: undoRemove" style="display: none;">Restore Group</button>
<button type="button" class="btn btn-default" data-bind="visible: !isDeletingMode(), click: function() { $parent.removeVirtualInstanceGroup($data); }">Delete Group</button>
</td>
</tr>
<tr class="extra-information" data-bind="visible: !$parent.isViewOnlyMode() && existingInstancesModified()" style="display: none;">
<td colspan="2"></td>
<td class="text-right">
<p class="disabled small" data-bind="visible: virtualInstancesAdded().length > 0">To be added:</p>
<p class="disabled small" data-bind="visible: virtualInstancesDeleting().length > 0" style="display: none;">To be deleted:</p>
<p class="disabled small" data-bind="visible: virtualInstancesRepairing().length > 0" style="display: none;">To be repaired:</p>
</td>
<td class="text-right">
<p class="small" data-bind="visible: virtualInstancesAdded().length > 0, text: virtualInstancesAdded().length">10</p>
<b><p class="small text-danger" data-bind="visible: virtualInstancesDeleting().length > 0, text: virtualInstancesDeleting().length" style="display: none;">0</p></b>
<p class="small" data-bind="visible: virtualInstancesRepairing().length > 0, text: virtualInstancesRepairing().length" style="display: none;">0</p>
</td>
<td colspan="3"></td>
</tr>
<tr class="extra-information" data-bind="visible : $parent.highlightErrors() && errorMessage()" style="display: none;">
<td colspan="2"></td>
<td colspan="6">
<span class="small text-danger" data-bind="text: errorMessage"></span>
</td>
</tr>
<!-- /ko -->
<tr data-bind="visible: !isViewOnlyMode()">
<td colspan="8">
<button class="btn btn-default" data-bind="click: newVirtualInstanceGroup">Add Group</button>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<!-- ko if: isGrowAndShrinkMode --><!-- /ko -->
<br>
<!-- ko if: isGrowAndShrinkMode --><!-- /ko -->
<div class="col-md-12 col-sm-12 col-xs-12 form-group">
<fieldset class="form-section">
<!-- ko with: $parent.databaseSelector -->
<h4>Database Server</h4>
<div class="form-group">
<label class="col-md-3 col-sm-4 col-xs-5 control-label">
</label>
<div class="col-md-3 col-sm-4 col-xs-5">
<span class="select-with-button">
<select class="form-control" data-width="75%" data-bind="dropdown: true,
dropdownOptions: {values: databaseServers, value: selected},
value: selected" style="display: none;">
<optgroup label="">
<option value="CREATE_NEW">Create New RDS Server</option>
<option value="USE_EXISTING">Register Existing DB Server</option>
</optgroup>
<optgroup label="">
<option data-subtext="(default)" value="USE_EMBEDDED">Embedded DB</option>
<!-- ko foreach: databaseServers --><!-- /ko -->
</optgroup>
</select><div class="btn-group bootstrap-select form-control" style="width: 75%;"><button type="button" class="btn dropdown-toggle selectpicker btn-default" data-toggle="dropdown" title="Embedded DB"><span class="filter-option pull-left">Embedded DB</span> <span class="caret"></span></button><div class="dropdown-menu open"><ul class="dropdown-menu inner selectpicker" role="menu"><li class="dropdown-header" data-original-index="null"><span class="text"></span></li><li data-original-index="0"><a tabindex="0" class="opt " data-optgroup="1" data-normalized-text="<span class="text">Create New RDS Server</span>"><span class="text">Create New RDS Server</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="1"><a tabindex="0" class="opt " data-optgroup="1" data-normalized-text="<span class="text">Register Existing DB Server</span>"><span class="text">Register Existing DB Server</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li class="divider" data-original-index="null"></li><li class="dropdown-header" data-original-index="null"><span class="text"></span></li><li data-original-index="2" class="selected"><a tabindex="0" class="opt " data-optgroup="2" data-normalized-text="<span class="text">Embedded DB<small class="muted text-muted">(default)</small></span>"><span class="text">Embedded DB<small class="muted text-muted">(default)</small></span><span class="glyphicon glyphicon-ok check-mark"></span></a></li></ul></div></div>
<span class="action-buttons">
<a class="btn btn-link" data-bind="visible: viewEnabled, click: editDB" style="display: none;">View</a>
<a class="btn btn-default" data-bind="visible: editEnabled, click: editDB" style="display: none;">Edit</a>
</span>
</span>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Database Server"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Database Server">
<span class="help-content" data-bind="template: { nodes: content }">
External database server to use for this Cloudera Manager.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
<ko-modal params="showDialog: showDialog,
okButtonText: 'OK',
title: 'Database Server',
viewModel: currentDatabase,
closeVisible: viewing,
okVisible: editing,
cancelVisible: editing,
onOK: onOK,
onDismiss: onDismiss"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<div class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" data-bind="modal: show, attr: { 'aria-labelledby': title }" aria-labelledby="Database Server">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<form data-bind="submit: onOK">
<div class="modal-header">
<button type="button" class="close" data-bind="click: onDismiss"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title" data-bind="text: title">Database Server</h4>
</div>
<div class="modal-body form-horizontal" data-bind="template: { nodes: content, data: viewModel }">
<form data-bind="submit: $parent.onOK">
<!-- name -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isNameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Name</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: editable, textInput: name" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="html: nameErrorMessage">This name is not valid. Click ? for more details.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="Name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- hostname -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isHostnameValid() },
visible: !newHostMode()">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Hostname</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: editable, textInput: hostname" placeholder="1.2.3.4" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isHostnameValid()" style="display: none;">
<span class="small text-danger" data-bind="html: 'Please enter a hostname or an ip address. Hostnames are alphanumeric words separated by dots. Valid ip addresses have four numbers.'">Please enter a hostname or an ip address. Hostnames are alphanumeric words separated by dots. Valid ip addresses have four numbers.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="Hostname"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Hostname">
<span class="help-content" data-bind="template: { nodes: content }">
The fully qualified domain name, or IP address of the database server.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- port -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isPortValid() },
visible: !newHostMode()">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">DB Port</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="number" min="1" max="65535" class="form-control" data-bind="enable: editable, textInput: port" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isPortValid()" style="display: none;">
<span class="small text-danger" data-bind="html: 'This must be an integer number greater than 0.'">This must be an integer number greater than 0.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="DB Port"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="DB Port">
<span class="help-content" data-bind="template: { nodes: content }">
The TC/IP port to connect to the database server.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- username -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isUsernameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">DB Username</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: editable, textInput: username" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isUsernameValid()" style="display: none;">
<span class="small text-danger" data-bind="html: '<p>The following characters are allowed:</p><p>a-z, 0-9, _</p><p>The following character(s) are allowed except at the beginning:</p><p>hyphen (-)</p><p>Should be between 1 and 32 characters in length.</p>'"><p>The following characters are allowed:</p><p>a-z, 0-9, _</p><p>The following character(s) are allowed except at the beginning:</p><p>hyphen (-)</p><p>Should be between 1 and 32 characters in length.</p></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="DB Username"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="DB Username">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>a-z, 0-9, _</p><p>The following character(s) are allowed except at the beginning:</p><p>hyphen (-)</p><p>Should be between 1 and 32 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- password -->
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isPasswordValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">DB Password</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="password" class="form-control" data-bind="enable: editable, textInput: password" disabled="">
<p class="help-block" data-bind="visible: highlightErrors() && !isPasswordValid()" style="display: none;">
<span class="small text-danger" data-bind="html: 'Database Password must contain 8-30 alphanumeric characters.'">Database Password must contain 8-30 alphanumeric characters.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: editable" style="display: none;">
<ko-help-icon data-title="DB Password"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="DB Password">
<span class="help-content" data-bind="template: { nodes: content }">
Password must contain 8-30 alphanumeric characters.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- type -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Type</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<select class="form-control" data-bind="enable: editable,
options: databaseTypes,
optionsText: optionsText,
optionsValue: optionsValue,
value: type" disabled=""><option value="MYSQL">MySQL</option><option value="POSTGRESQL">PostgreSQL</option><option value="ORACLE">Oracle</option></select>
</div>
</div>
<!-- rds only stuff -->
<div data-bind="visible: showConfigSection" style="display: none;">
<!-- config -->
<div data-bind="with: config">
<!-- engine version -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">
Engine Version
</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(),
textInput: engineVersion" disabled="">
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: $parent.editable()" style="display: none;">
<ko-help-icon data-title="Name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- instanceClass -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isInstanceClassValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Instance Class</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<div class="input-group">
<input type="text" class="form-control" data-bind="enable: $parent.editable(),
textInput: instanceClass,
typeahead: { source: allInstanceClasses, minLength: 0 }" disabled="" autocomplete="off">
<div class="input-group-btn" data-bind="if: $parent.editable()"></div>
</div>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && instanceClassErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: instanceClassErrorMessage">Instance Class cannot be empty.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Type"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Type">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Select an instance type as per the needs of the processes to be run on this instance.</p>
<p><a data-bind="urlByKey: 'awsRdsInstanceClass'" target="_blank" href="http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- allocated storage -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isAllocatedStorageValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Allocated Storage</label>
<div class="col-md-2 col-sm-3 col-xs-3 text-nowrap">
<div class="input-group">
<input type="number" class="form-control text-right" data-bind="enable: $parent.editable(),
textInput: allocatedStorage,
attr: {min: MIN_ALLOCATED_STORAGE_SIZE_GB}" disabled="" min="5">
<span class="input-group-addon">GB</span>
</div>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && allocatedStorageErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: allocatedStorageErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1 col-md-offset-1 col-sm-offset-1">
<ko-help-icon data-title="Allocated Storage"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Allocated Storage">
<span class="help-content" data-bind="template: { nodes: content }">
<p>How much storage, in gigabytes, to allocate for your DB instance.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- vpc security group ids -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isVpcSecurityGroupIdsValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">VPC Security Groups</label>
<div class="col-md-5 col-sm-6 col-xs-7" data-bind="css: {'col-md-3 col-sm-3 col-xs-3': _vpcSecurityGroupIds().length === 0}">
<ko-add-remove-list params="list: _vpcSecurityGroupIds,
editable: $parent.editable,
placeholder: VPC_SECURITY_GROUP_PREFIX + '...'"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<ul class="list-unstyled">
<li class="row" data-bind="visible: list().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button type="button" class="btn btn-default" data-bind="click: function() { addItem({}, $element); }">+</button>
</div>
</li>
<li class="row" data-bind="foreach: list">
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()},
enable: $parent.editable(),
textInput: value,
attr: {placeholder: $parent.placeholder}" disabled="" placeholder="sg-...">
</div>
<div class="col-md-3 col-sm-3 col-xs-3 text-nowrap" data-bind="visible: $parent.editable()" style="display: none;">
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.removeItem($data, $element); }">-</button>
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.addItem($data, $element); }">+</button>
</div>
</li>
</ul>
</ko-add-remove-list>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && vpcSecurityGroupIdsErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: vpcSecurityGroupIdsErrorMessage">This value must begin with 'sg-'.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Security groups IDs"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Security groups IDs">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Specify the list of security group IDs. Must begin with 'sg-'.</p>
<p><a data-bind="urlByKey: 'awsRdsSecurityGroups'" target="_blank" href="http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Overview.RDSSecurityGroups.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- db subnet group name -->
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isSubnetGroupNameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Subnet Group</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(), textInput: dbSubnetGroupName" disabled="">
<p class="help-block" data-bind="visible: $parent.highlightErrors() && subnetGroupNameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: subnetGroupNameErrorMessage">Database Subnet Group name cannot be empty.</span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: $parent.editable()" style="display: none;">
<ko-help-icon data-title="Subnet Group"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Subnet Group">
<span class="help-content" data-bind="template: { nodes: content }">
A DB subnet group is a collection of subnets (typically private) that you create for a VPC and that you then designate for your DB instances. A DB subnet group allows you to specify a particular VPC when you create DB instances.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
</div>
<!-- tags -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Tags</label>
<div class="col-md-8 col-sm-8 col-xs-6">
<ul class="list-unstyled">
<li class="row" data-bind="visible: _tags().length !== 0" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Name</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Value</p>
</div>
</li>
<li class="row" data-bind="visible: _tags().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button type="button" class="btn btn-default" data-bind="click: function() { _tags.insertAfter({}, $element); }">+</button>
</div>
</li>
<!-- ko foreach: _tags --><!-- /ko -->
</ul>
</div>
</div>
</div>
<!-- This button makes it so if a user hits enter while in a text box-->
<!-- the button performs the onsubmit, to the outer <form> -->
<button style="display: none;"></button>
</form>
</div>
<div class="modal-footer">
<button name="close" type="button" class="btn btn-primary" data-bind="visible: closeVisible, click: onDismiss">Close</button>
<button name="cancel" type="button" class="btn btn-link" data-bind="visible: cancelVisible, click: onDismiss" style="display: none;">Cancel</button>
<button name="reset" type="reset" class="btn btn-link" data-bind="visible: resetVisible, click: onReset" style="display: none;">Reset</button>
<button name="ok" type="submit" data-bind="visible: okVisible, click: onOK, attr: { class : okButtonClass }" class="btn btn-primary" style="display: none;">
<span data-bind="text: okButtonText">OK</span>
<span data-bind="visible: isSaving" style="display: none;">...</span>
</button>
</div>
</form>
</div>
</div>
</div>
</ko-modal>
</div>
<!-- /ko -->
</fieldset>
</div>
<div class="col-md-12 col-sm-12 col-xs-12 form-group">
<fieldset class="form-section" data-bind="if: isNewMode">
<a class="collapsible-section-header" data-toggle="collapse" href=".cluster-configuration" aria-expanded="false" data-bind="click: function() { configurationSectionCollapsed(!configurationSectionCollapsed()) }">
<h4><span class="glyphicon small glyphicon-chevron-down" aria-hidden="true" data-bind="css: { 'glyphicon-chevron-right': configurationSectionCollapsed(), 'glyphicon-chevron-down': !configurationSectionCollapsed()}">
</span> Configurations (optional)</h4>
</a>
<div class="cluster-configuration collapse in">
<div class="form-group">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-3 col-sm-4 col-xs-5">
<button type="button" class="btn btn-default" data-bind="click: configure">
Services Configuration
</button>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="">
<span class="help-content" data-bind="template: { nodes: content }">Configuration for the Cluster services.</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-3 col-sm-4 col-xs-5">
<button type="button" class="btn btn-default" data-bind="click: configureRoles">
Roles Configuration
</button>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="">
<span class="help-content" data-bind="template: { nodes: content }">Configuration for the Cluster service roles.</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-3 col-sm-4 col-xs-5">
<div class="checkbox">
<label>
<input type="checkbox" data-bind="checked: overrideParcelRepositories"> Override default parcel repositories
</label>
</div>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Parcel Repositories"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Parcel Repositories">
<span class="help-content" data-bind="template: { nodes: content }">
Customize Parcel Repositories to be used by the Cluster.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="visible: overrideParcelRepositories" style="display: none;">
<div class="col-md-offset-3 col-sm-offset-4 col-xs-offset-5 col-md-5 col-sm-6 col-xs-7" data-bind="css: { 'has-error': highlightErrors() && !isParcelRepositoriesValid() }">
<ul class="list-unstyled">
<li class="row" data-bind="visible: _parcelRepositories().length === 0" style="display: none;">
<div class="col-md-2 col-sm-2 col-xs-2">
<button class="btn btn-default" data-bind="click: function() { _parcelRepositories.insertAfter({}, $element); }">+
</button>
</div>
</li>
<!-- ko foreach: _parcelRepositories -->
<li class="row">
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" data-bind="textInput: value">
</div>
<div class="col-md-3 col-sm-3 col-xs-3 text-nowrap">
<button class="btn btn-default" data-bind="click: function() { $parent._parcelRepositories.removeItem($data, $element); }">-
</button>
<button class="btn btn-default" data-bind="click: function() { $parent._parcelRepositories.insertAfter($data, $element); }">+
</button>
</div>
</li>
<!-- /ko -->
</ul>
<p class="help-block">
<small><b>Example</b> http://archive.cloudera.com/cdh5/parcels/latest/</small>
</p>
<p class="help-block" data-bind="visible: highlightErrors() && parcelRepositoriesErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: parcelRepositoriesErrorMessage"></span>
</p>
</div>
</div>
</div>
</fieldset>
</div>
</fieldset>
<!-- ko if: cluster.isNewMode -->
<!-- ko with: configurationModal -->
<ko-modal params="showDialog: showDialog,
okButtonText: 'Save changes',
title: title,
viewModel: $data,
closeVisible: viewing,
okVisible: editable,
resetVisible: editable,
cancelVisible: editable,
onOK: apply,
onReset: reset,
onDismiss: hide"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<div class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" data-bind="modal: show, attr: { 'aria-labelledby': title }" aria-labelledby="Roles Configuration" style="display: none;">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<form data-bind="submit: onOK">
<div class="modal-header">
<button type="button" class="close" data-bind="click: onDismiss"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title" data-bind="text: title">Roles Configuration</h4>
</div>
<div class="modal-body form-horizontal" data-bind="template: { nodes: content, data: viewModel }">
<!-- ko foreach: filters -->
<div class="form-group">
<label class="col-md-1 col-sm-2 col-xs-3 control-label text-left" data-bind="text: label">Service</label>
<div class="col-md-5 col-sm-6 col-xs-7">
<select class="form-control" data-bind="options: availableValues,
optionsText: 'label',
optionsValue: 'name',
value: selectedValue"><option value="HDFS">HDFS</option><option value="HIVE">Hive</option><option value="HUE">Hue</option><option value="OOZIE">Oozie</option><option value="SQOOP">Sqoop 2</option><option value="YARN">YARN</option><option value="ZOOKEEPER">ZooKeeper (modified)</option></select>
</div>
<div class="col-md-1 col-sm-2 col-xs-2">
<ko-help-icon data-bind="attr: { 'data-title': label }" data-title="Service"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Service">
<span class="help-content" data-bind="template: { nodes: content }">
<p data-bind="text: $parent.description">Select a cluster service to filter roles.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<label class="col-md-1 col-sm-2 col-xs-3 control-label text-left" data-bind="text: label">Role</label>
<div class="col-md-5 col-sm-6 col-xs-7">
<select class="form-control" data-bind="options: availableValues,
optionsText: 'label',
optionsValue: 'name',
value: selectedValue"><option value="SERVER">Server (modified)</option></select>
</div>
<div class="col-md-1 col-sm-2 col-xs-2">
<ko-help-icon data-bind="attr: { 'data-title': label }" data-title="Role"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Role">
<span class="help-content" data-bind="template: { nodes: content }">
<p data-bind="text: $parent.description">Select a cluster service role to configure.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- /ko-->
<hr>
<!-- ko if: selectedConfigurations().length -->
<!-- ko foreach: selectedConfigurations -->
<!-- ko if: configurations().length -->
<!-- ko if: title -->
<a class="collapsible-section-header" data-toggle="collapse" aria-expanded="false" data-bind="attr: {href: '.role-configuration-' + $index()}, click: function() { configurationSectionCollapsed(!configurationSectionCollapsed()) }" href=".role-configuration-0">
<h4><span class="glyphicon small glyphicon-chevron-down" aria-hidden="true" data-bind="css: { 'glyphicon-chevron-right': configurationSectionCollapsed, 'glyphicon-chevron-down': !configurationSectionCollapsed() }">
</span> <span data-bind="text: title">masters</span></h4>
</a>
<!-- /ko -->
<div class="collapse in role-configuration-0" data-bind="css: 'role-configuration-' + $index()">
<ul data-bind="foreach: configurations" class="list-unstyled">
<li>
<!-- ko if: widget === 'CUSTOM' -->
<div class="form-group">
<div class="col-md-4 col-sm-4 col-xs-4" data-bind="css: { 'has-error' : highlightErrors() && nameErrorMessage() }">
<input type="text" class="form-control" placeholder="Name" data-bind="textInput: proposedName">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4" data-bind="css: { 'has-error' : highlightErrors() && valueErrorMessage() }">
<input type="text" class="form-control" placeholder="Value" data-bind="textInput: proposedValue">
<p class="help-block" data-bind="visible: highlightErrors() && valueErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: valueErrorMessage"></span>
</p>
</div>
<div class="col-md-2 col-sm-2 col-xs-2 text-nowrap">
<button tabindex="-1" class="btn btn-default" type="button" data-bind="disable: $parent.removeConfigurationDisabled,
click: function() { $parent.configurations.removeItem($data, $element); }" disabled="">-</button>
<button tabindex="-1" class="btn btn-default" type="button" data-bind="click: function() { $parent.configurations.insertAfter($data, $element); }">+</button>
</div>
</div>
<!-- /ko -->
</li>
</ul>
</div>
<!-- /ko --><!-- title -->
<!-- ko if: configurations().length -->
<!-- ko if: title -->
<a class="collapsible-section-header" data-toggle="collapse" aria-expanded="false" data-bind="attr: {href: '.role-configuration-' + $index()}, click: function() { configurationSectionCollapsed(!configurationSectionCollapsed()) }" href=".role-configuration-1">
<h4><span class="glyphicon small glyphicon-chevron-down" aria-hidden="true" data-bind="css: { 'glyphicon-chevron-right': configurationSectionCollapsed, 'glyphicon-chevron-down': !configurationSectionCollapsed() }">
</span> <span data-bind="text: title">workers</span></h4>
</a>
<!-- /ko -->
<div class="collapse in role-configuration-1" data-bind="css: 'role-configuration-' + $index()">
<ul data-bind="foreach: configurations" class="list-unstyled">
<li>
<!-- ko if: widget === 'CUSTOM' -->
<div class="form-group">
<div class="col-md-4 col-sm-4 col-xs-4" data-bind="css: { 'has-error' : highlightErrors() && nameErrorMessage() }">
<input type="text" class="form-control" placeholder="Name" data-bind="textInput: proposedName">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4 has-error" data-bind="css: { 'has-error' : highlightErrors() && valueErrorMessage() }">
<input type="text" class="form-control" placeholder="Value" data-bind="textInput: proposedValue">
<p class="help-block" data-bind="visible: highlightErrors() && valueErrorMessage()">
<span class="small text-danger" data-bind="text: valueErrorMessage">The value is missing.</span>
</p>
</div>
<div class="col-md-2 col-sm-2 col-xs-2 text-nowrap">
<button tabindex="-1" class="btn btn-default" type="button" data-bind="disable: $parent.removeConfigurationDisabled,
click: function() { $parent.configurations.removeItem($data, $element); }" disabled="">-</button>
<button tabindex="-1" class="btn btn-default" type="button" data-bind="click: function() { $parent.configurations.insertAfter($data, $element); }">+</button>
</div>
</div>
<!-- /ko -->
</li>
</ul>
</div>
<!-- /ko --><!-- title -->
<!-- /ko --><!-- foreach -->
<!-- /ko --><!-- selectedConfigurations().length -->
</div>
<div class="modal-footer">
<button name="close" type="button" class="btn btn-primary" data-bind="visible: closeVisible, click: onDismiss" style="display: none;">Close</button>
<button name="cancel" type="button" class="btn btn-link" data-bind="visible: cancelVisible, click: onDismiss">Cancel</button>
<button name="reset" type="reset" class="btn btn-link" data-bind="visible: resetVisible, click: onReset">Reset</button>
<button name="ok" type="submit" data-bind="visible: okVisible, click: onOK, attr: { class : okButtonClass }" class="btn btn-primary">
<span data-bind="text: okButtonText">Save changes</span>
<span data-bind="visible: isSaving" style="display: none;">...</span>
</button>
</div>
</form>
</div>
</div>
</div>
</ko-modal>
<!-- /ko -->
<!-- /ko -->
<!-- ko with: virtualInstancesModal -->
<div class="modal fade" tabindex="-1" role="dialog" aria-labelledby="Instances" aria-hidden="true" data-bind="modal:showDialog">
<div class="modal-dialog modal-lg virtual-instances-modal">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title">Instance group: <span data-bind="text: name"></span></h4>
</div>
<div class="modal-body form-horizontal">
<div class="panel panel-default">
<div class="panel-heading">
<h5>Add Instances</h5>
</div>
<div class="panel-body">
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isNewInstanceCountValid() }">
<label class="col-md-3 col-sm-3 col-xs-3 control-label">Add Number of Instances</label>
<div class="col-md-2 col-sm-2 col-xs-2">
<input type="number" min="0" class="form-control text-right" data-bind="textInput: newInstanceCount">
</div>
</div>
</div>
</div>
<div class="panel panel-default" data-bind="visible: instances().length > 0" style="display: none;">
<div class="panel-heading">
<h5>
Edit Instances
<span class="small">
<span class="text-info" data-bind="text: repairSummary"></span> <span class="text-danger" data-bind="text: deleteSummary"></span>
</span>
</h5>
</div>
<div class="panel-body">
<button type="button" class="btn btn-default" data-bind="enable: enableRepair, click: repairSelected" disabled="">Repair</button>
<button type="button" class="btn btn-default" data-bind="enable: enableDelete, click: deleteSelected" disabled="">Delete</button>
<table class="table" data-bind="visible: instances().length > 0" style="display: none;">
<thead>
<tr>
<th><input type="checkbox" data-bind="checked: checkAll"></th>
<th>IP Address</th>
<th>Health</th>
<th>Action Status</th>
</tr>
</thead>
<tbody>
<!-- ko foreach: instances --><!-- /ko -->
</tbody>
</table>
</div><!-- .panel-body -->
</div><!-- .panel -->
</div><!-- .modal-body -->
<div class="modal-footer">
<button type="button" class="btn btn-link" data-dismiss="modal">Cancel</button>
<button type="button" class="btn btn-link" data-bind="click: reset">Reset</button>
<button type="button" class="btn btn-primary" data-bind="enable: enableOK, click: apply">OK</button>
</div>
</div>
</div>
</div>
<!-- /ko -->
<!-- ko with: roleAssignmentModal -->
<div class="modal fade" tabindex="-1" role="dialog" aria-labelledby="Role Assignment" aria-hidden="true" data-bind="modal:showDialog" style="display: none;">
<div class="modal-dialog modal-lg role-assignment-modal">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title">Instance group: <span data-bind="text: groupName()">workers</span></h4>
</div>
<div class="modal-body form-horizontal">
<div class="form-group role-assignments">
<label class="col-md-3 col-sm-4 col-xs-5 control-label">Role Assignment</label>
<div class="col-md-9 col-sm-8 col-xs-7">
<table class="table">
<thead>
<tr>
<th class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="small">Service</span>
</th>
<th colspan="2" class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<span class="small">Role</span>
</th>
</tr>
</thead>
<tbody>
<!-- ko foreach: allowedServiceTypeToRoleTypes -->
<tr data-bind="if: $parent.isNewMode() || _roleTypes().length > 0">
<td class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="service-type">
<span data-bind="humanizeServiceType: name">HDFS</span>
</span>
</td><!-- .form-control-static -->
<td class="col-md-2 col-sm-2 col-xs-2 form-control-static" data-bind="visible: $parent.isNewMode()">
<div class="add-role-type-btn dropdown">
<button class="btn btn-default btn-xs dropdown-toggle" type="button" data-toggle="dropdown" aria-expanded="true" data-bind="attr: { disabled : otherRoleTypes().length === 0 }">
Add Role <span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<!-- ko foreach: otherRoleTypes -->
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">NameNode</a></li>
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">SecondaryNameNode</a></li>
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Balancer</a></li>
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Gateway</a></li>
<!-- /ko -->
</ul>
</div><!-- .add-role-type-btn -->
</td><!-- .form-control-static -->
<td class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<!-- ko foreach: _roleTypes -->
<span class="role-type">
<span data-bind="humanizeRoleType: value">DataNode</span>
<button class="btn btn-default btn-xs" title="Remove" data-bind="visible: $parents[1].isNewMode(), click: function() { $parent._roleTypes.removeItem($data, $element); }">×</button>
</span>
<!-- /ko --><!-- _roleTypes -->
</td>
</tr>
<tr data-bind="if: $parent.isNewMode() || _roleTypes().length > 0">
<td class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="service-type">
<span data-bind="humanizeServiceType: name">Hive</span>
</span>
</td><!-- .form-control-static -->
<td class="col-md-2 col-sm-2 col-xs-2 form-control-static" data-bind="visible: $parent.isNewMode()">
<div class="add-role-type-btn dropdown">
<button class="btn btn-default btn-xs dropdown-toggle" type="button" data-toggle="dropdown" aria-expanded="true" data-bind="attr: { disabled : otherRoleTypes().length === 0 }">
Add Role <span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<!-- ko foreach: otherRoleTypes -->
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Hive Metastore Server</a></li>
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">HiveServer2</a></li>
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Gateway</a></li>
<!-- /ko -->
</ul>
</div><!-- .add-role-type-btn -->
</td><!-- .form-control-static -->
<td class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<!-- ko foreach: _roleTypes --><!-- /ko --><!-- _roleTypes -->
</td>
</tr>
<tr data-bind="if: $parent.isNewMode() || _roleTypes().length > 0">
<td class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="service-type">
<span data-bind="humanizeServiceType: name">Hue</span>
</span>
</td><!-- .form-control-static -->
<td class="col-md-2 col-sm-2 col-xs-2 form-control-static" data-bind="visible: $parent.isNewMode()">
<div class="add-role-type-btn dropdown">
<button class="btn btn-default btn-xs dropdown-toggle" type="button" data-toggle="dropdown" aria-expanded="true" data-bind="attr: { disabled : otherRoleTypes().length === 0 }">
Add Role <span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<!-- ko foreach: otherRoleTypes -->
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Hue Server</a></li>
<!-- /ko -->
</ul>
</div><!-- .add-role-type-btn -->
</td><!-- .form-control-static -->
<td class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<!-- ko foreach: _roleTypes --><!-- /ko --><!-- _roleTypes -->
</td>
</tr>
<tr data-bind="if: $parent.isNewMode() || _roleTypes().length > 0">
<td class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="service-type">
<span data-bind="humanizeServiceType: name">Oozie</span>
</span>
</td><!-- .form-control-static -->
<td class="col-md-2 col-sm-2 col-xs-2 form-control-static" data-bind="visible: $parent.isNewMode()">
<div class="add-role-type-btn dropdown">
<button class="btn btn-default btn-xs dropdown-toggle" type="button" data-toggle="dropdown" aria-expanded="true" data-bind="attr: { disabled : otherRoleTypes().length === 0 }">
Add Role <span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<!-- ko foreach: otherRoleTypes -->
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Oozie Server</a></li>
<!-- /ko -->
</ul>
</div><!-- .add-role-type-btn -->
</td><!-- .form-control-static -->
<td class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<!-- ko foreach: _roleTypes --><!-- /ko --><!-- _roleTypes -->
</td>
</tr>
<tr data-bind="if: $parent.isNewMode() || _roleTypes().length > 0">
<td class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="service-type">
<span data-bind="humanizeServiceType: name">Sqoop 2</span>
</span>
</td><!-- .form-control-static -->
<td class="col-md-2 col-sm-2 col-xs-2 form-control-static" data-bind="visible: $parent.isNewMode()">
<div class="add-role-type-btn dropdown">
<button class="btn btn-default btn-xs dropdown-toggle" type="button" data-toggle="dropdown" aria-expanded="true" data-bind="attr: { disabled : otherRoleTypes().length === 0 }">
Add Role <span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<!-- ko foreach: otherRoleTypes -->
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Sqoop 2 Server</a></li>
<!-- /ko -->
</ul>
</div><!-- .add-role-type-btn -->
</td><!-- .form-control-static -->
<td class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<!-- ko foreach: _roleTypes --><!-- /ko --><!-- _roleTypes -->
</td>
</tr>
<tr data-bind="if: $parent.isNewMode() || _roleTypes().length > 0">
<td class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="service-type">
<span data-bind="humanizeServiceType: name">YARN</span>
</span>
</td><!-- .form-control-static -->
<td class="col-md-2 col-sm-2 col-xs-2 form-control-static" data-bind="visible: $parent.isNewMode()">
<div class="add-role-type-btn dropdown">
<button class="btn btn-default btn-xs dropdown-toggle" type="button" data-toggle="dropdown" aria-expanded="true" data-bind="attr: { disabled : otherRoleTypes().length === 0 }">
Add Role <span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<!-- ko foreach: otherRoleTypes -->
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">ResourceManager</a></li>
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">JobHistory Server</a></li>
<li role="presentation"><a role="menuitem" href="#" tabindex="-1" data-bind="humanizeRoleType: $data, click: function() { $parent.addRoleType($data, $element); return false; }">Gateway</a></li>
<!-- /ko -->
</ul>
</div><!-- .add-role-type-btn -->
</td><!-- .form-control-static -->
<td class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<!-- ko foreach: _roleTypes -->
<span class="role-type">
<span data-bind="humanizeRoleType: value">NodeManager</span>
<button class="btn btn-default btn-xs" title="Remove" data-bind="visible: $parents[1].isNewMode(), click: function() { $parent._roleTypes.removeItem($data, $element); }">×</button>
</span>
<!-- /ko --><!-- _roleTypes -->
</td>
</tr>
<tr data-bind="if: $parent.isNewMode() || _roleTypes().length > 0">
<td class="col-md-3 col-sm-4 col-xs-5 form-control-static">
<span class="service-type">
<span data-bind="humanizeServiceType: name">ZooKeeper</span>
</span>
</td><!-- .form-control-static -->
<td class="col-md-2 col-sm-2 col-xs-2 form-control-static" data-bind="visible: $parent.isNewMode()">
<div class="add-role-type-btn dropdown">
<button class="btn btn-default btn-xs dropdown-toggle" type="button" data-toggle="dropdown" aria-expanded="true" data-bind="attr: { disabled : otherRoleTypes().length === 0 }" disabled="true">
Add Role <span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<!-- ko foreach: otherRoleTypes --><!-- /ko -->
</ul>
</div><!-- .add-role-type-btn -->
</td><!-- .form-control-static -->
<td class="col-md-9 col-sm-8 col-xs-7 form-control-static">
<!-- ko foreach: _roleTypes -->
<span class="role-type">
<span data-bind="humanizeRoleType: value">Server</span>
<button class="btn btn-default btn-xs" title="Remove" data-bind="visible: $parents[1].isNewMode(), click: function() { $parent._roleTypes.removeItem($data, $element); }">×</button>
</span>
<!-- /ko --><!-- _roleTypes -->
</td>
</tr>
<!-- /ko --><!-- allowedServiceTypeToRoleTypes -->
</tbody>
</table>
<p class="help-block" data-bind="visible: highlightErrors() && roleAssignmentErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: roleAssignmentErrorMessage"></span>
</p>
</div>
</div><!-- .form-group -->
</div><!-- .modal-body -->
<div class="modal-footer">
<button type="button" class="btn btn-link" data-bind="visible: isNewMode" data-dismiss="modal">Cancel</button>
<button type="button" class="btn btn-link" data-bind="visible: isNewMode, click: reset">Reset</button>
<button type="button" class="btn btn-primary" data-bind="visible: isNewMode, click: apply">OK</button>
<button type="button" class="btn btn-primary" data-bind="visible: !isNewMode()" data-dismiss="modal" style="display: none;">Close</button>
</div>
</div>
</div>
</div>
<!-- /ko -->
<!-- ko with: instanceTemplateList.templateModal -->
<div class="modal fade" tabindex="-1" role="dialog" aria-labelledby="Instance Template" aria-hidden="true" data-bind="modal:showDialog" style="display: none;">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title">Instance Template</h4>
</div>
<div class="modal-body form-horizontal">
<!-- ko with: instanceTemplate -->
<div class="form-group" data-bind="visible: !isTemplateApplied(), css: { 'has-error': highlightErrors() && !isNameValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Instance Template name</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: isNewMode, textInput: name" placeholder="">
<p class="help-block" data-bind="visible: highlightErrors() && nameErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: nameErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1" data-bind="visible: isNewMode">
<ko-help-icon data-title="Instance Template name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Instance Template name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>The following characters are allowed:</p><p>A-Z, a-z, 0-9</p><p>The following characters are allowed except in the beginning and the end:</p><p>space ( ), underscore (_) and hyphen (-)</p><p>Should be between 2 and 40 characters in length.</p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isTypeValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Type</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<div class="input-group">
<input type="text" class="form-control" data-bind="enable: editable,
textInput: type,
typeahead: {
source: allTypes,
minLength: 0,
items: 'all' }" autocomplete="off">
<div class="input-group-btn" data-bind="if: editable">
<button tabindex="-1" type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
<span class="caret"></span>
</button>
<ul class="dropdown-menu pull-right typeahead" role="menu">
<!-- ko foreach: allTypes -->
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">t2.micro</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">t2.small</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">t2.medium</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.medium</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">m3.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c3.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">c4.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">g2.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.large</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">r3.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">i2.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">hs1.8xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.2xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.4xlarge</a></li>
<li><a href="#" data-bind="click: function() { $parent.type($data); }, text: $data">d2.8xlarge</a></li>
<!-- /ko -->
</ul>
</div>
</div>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Type"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Type">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Select an instance type as per the needs of the processes to be run on this instance.</p>
<p><a data-bind="urlByKey: 'awsInstType'" target="_blank" href="http://aws.amazon.com/ec2/instance-types/">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': highlightErrors() && !isImageValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Amazon Machine Image (AMI)</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()}, enable: editable, textInput: image" placeholder="ami-...">
<p class="help-block" data-bind="visible: highlightErrors() && imageErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: imageErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Amazon Machine Image (AMI)"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Amazon Machine Image (AMI)">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Red Hat Enterprise Linux 6.4 (64bit) 64bit PV or HVM AMIs are supported. Must begin with 'ami-'.</p><p>
</p><p><a data-bind="urlByKey: 'awsAmi'" target="_blank" href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AMIs.html">More information</a></p>
<p><a data-bind="urlByKey: 'awsAmiInstMatrix'" target="_blank" href="https://aws.amazon.com/amazon-linux-ami/instance-type-matrix/">Compatibility matrix</a></p>
<p><a data-bind="urlByKey: 'redHatPartners'" target="_blank" href="http://aws.amazon.com/partners/redhat/">Red Hat Enterprise Linux AMI IDs</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Tags</label>
<div class="col-md-8 col-sm-8 col-xs-6">
<ul class="list-unstyled">
<li class="row" data-bind="visible: _tags().length !== 0">
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Name</p>
</div>
<div class="col-md-4 col-sm-4 col-xs-4">
<p class="small form-control-static">Value</p>
</div>
</li>
<li class="row" data-bind="visible: _tags().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button class="btn btn-default" data-bind="click: function() { _tags.insertAfter({}, $element); }">+</button>
</div>
</li>
<!-- ko foreach: _tags -->
<li class="row" data-bind="css: { 'has-error': $parent.highlightErrors() && !isValid() }">
<div class="col-md-4 col-sm-4 col-xs-4">
<input type="text" class="form-control" data-bind="textInput: name, enable: $parent.editable()">
</div>
<div class="col-md-4 col-sm-4 col-xs-4">
<input type="text" class="form-control" data-bind="textInput: value, enable: $parent.editable()">
</div>
<div class="col-md-2 col-sm-2 col-xs-2 text-nowrap" data-bind="visible: $parent.editable()">
<button class="btn btn-default" data-bind="click: function() { $parent._tags.removeItem($data, $element); }">-</button>
<button class="btn btn-default" data-bind="click: function() { $parent._tags.insertAfter($data, $element); }">+</button>
</div>
</li>
<!-- /ko -->
</ul>
</div>
</div>
<!-- ko with: config -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">IAM Profile Name</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(), textInput: iamProfileName" placeholder="">
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="IAM Profile Name"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="IAM Profile Name">
<span class="help-content" data-bind="template: { nodes: content }">
<p>IAM roles help with key distribution. This role is optional and is used when launching a new instance.</p>
<a data-bind="urlByKey: 'awsIamRole'" target="_blank" href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html">More information</a>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Instance name prefix</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="enable: $parent.editable(), textInput: instanceNamePrefix" placeholder="">
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Instance name prefix"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Instance name prefix">
<span class="help-content" data-bind="template: { nodes: content }">
Prefix that Cloudera Director should use when naming the instances (this is not part of the hostname).
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isRootVolumeValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Root volume size</label>
<div class="col-md-2 col-sm-3 col-xs-3 text-nowrap">
<div class="input-group">
<input type="number" min="0" class="form-control text-right" data-bind="enable: $parent.editable(), textInput: rootVolumeSizeGB" placeholder="">
<span class="input-group-addon">GB</span>
</div>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && rootVolumeErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: rootVolumeErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1 col-md-offset-1 col-sm-offset-1">
<ko-help-icon data-title="Root volume size"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Root volume size">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Specify a size for the root volume (in GB). Cloudera Director will automatically expand the filesystem so that you can use all the available disk space for your application.</p>
<p><a data-bind="urlByKey: 'awsExpandPartition'" target="_blank" href="http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/storage_expand_partition.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isSubnetIdValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">VPC subnet ID</label>
<div class="col-md-3 col-sm-4 col-xs-7">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()}, enable: $parent.editable(), textInput: subnetId" placeholder="subnet-...">
<p class="help-block" data-bind="visible: $parent.highlightErrors() && subnetIdErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: subnetIdErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="VPC subnet ID"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="VPC subnet ID">
<span class="help-content" data-bind="template: { nodes: content }">
<p>ID of the VPC subnet. Must begin with 'subnet-'.</p>
<p><a data-bind="urlByKey: 'awsSubId'" target="_blank" href="http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Subnets.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<div class="form-group" data-bind="css: { 'has-error': $parent.highlightErrors() && !isSecurityGroupsIdsValid() }">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Security groups IDs</label>
<div class="col-md-5 col-sm-6 col-xs-7" data-bind="css: {'col-md-3 col-sm-3 col-xs-3': _securityGroupsIds().length === 0}">
<ko-add-remove-list params="list: _securityGroupsIds,
editable: $parent.editable,
placeholder: 'sg-...'"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<ul class="list-unstyled">
<li class="row" data-bind="visible: list().length === 0 && editable()" style="display: none;">
<div class="col-md-4 col-sm-4 col-xs-4">
<button type="button" class="btn btn-default" data-bind="click: function() { addItem({}, $element); }">+</button>
</div>
</li>
<li class="row" data-bind="foreach: list">
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" data-bind="event: {focus: $element.select()},
enable: $parent.editable(),
textInput: value,
attr: {placeholder: $parent.placeholder}" placeholder="sg-...">
</div>
<div class="col-md-3 col-sm-3 col-xs-3 text-nowrap" data-bind="visible: $parent.editable()">
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.removeItem($data, $element); }">-</button>
<button type="button" class="btn btn-default" data-bind="click: function() { $parent.addItem($data, $element); }">+</button>
</div>
</li>
</ul>
</ko-add-remove-list>
<p class="help-block" data-bind="visible: $parent.highlightErrors() && securityGroupsIdsErrorMessage()" style="display: none;">
<span class="small text-danger" data-bind="text: securityGroupsIdsErrorMessage"></span>
</p>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Security groups IDs"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Security groups IDs">
<span class="help-content" data-bind="template: { nodes: content }">
<p>Specify the list of security group IDs. Must begin with 'sg-'.</p>
<p><a data-bind="urlByKey: 'awsSecGrp'" target="_blank" href="http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_SecurityGroups.html">More information</a></p>
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- /ko -->
<div class="form-group">
<label class="col-md-4 col-sm-4 col-xs-4 control-label">Bootstrap script</label>
<div class="col-md-5 col-sm-5 col-xs-5">
<ko-file-text-chooser params="valueAccessor: bootstrapScript, editable: editable">
<div class="fileTextChooser" data-bind="css: {'has_error': errorMessage}">
<div class="radio">
<label class="radio-inline">
<input value="fileMode" type="radio" name="fileInput" data-bind="disable: disableComponent, checked: mode">
File Upload
</label>
<label class="radio-inline" data-bind="visible: canFileUpload">
<input value="textMode" type="radio" name="fileInput" data-bind="disable: disableComponent, checked: mode, visible: canFileUpload">
Direct Input
</label>
</div>
<div class="file-controls" data-bind="visible: fileMode">
<input type="text" class="form-control" disabled="disableComponent" data-bind="textInput: fileName, css: { 'has-error' : false }">
<span role="button" class="btn btn-default" tabindex="-1" data-bind="enable: fileMode, disable: disableComponent">
<input type="file" data-bind="event: {change: extractFile},
disable: disableComponent">Choose File
</span>
</div>
<textarea rows="5" class="form-control code" data-bind="event: {focus: $element.select()},
visible: textMode,
textInput: data,
enable: textMode,
attr: {placeholder: placeholder}" spellcheck="false" disabled="" placeholder="" style="display: none;"></textarea>
<p class="help-block" data-bind="visible: errorMessage" style="display: none;">
<span class="small text-danger" data-bind="html: errorMessage">false</span>
</p>
</div>
</ko-file-text-chooser>
</div>
<div class="col-md-1 col-sm-1 col-xs-1">
<ko-help-icon data-title="Bootstrap script"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<button type="button" class="btn btn-link btn-help" tabindex="-1" data-bind="css: params.buttonClass, popover: popover, attr: {title: title}" data-original-title="" title="Bootstrap script">
<span class="help-content" data-bind="template: { nodes: content }">
Embedded bootstrap script that runs as root and can be used to customize instances immediately after boot. Cloudera Director will automatically retry if the exit code is not 0.
</span>
<span class="icon circle-question-mark gray" data-bind="css: params.iconClass"></span>
<span class="sr-only">Help</span>
</button>
</ko-help-icon>
</div>
</div>
<!-- /ko -->
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary" data-bind="visible: !instanceTemplate.editable()" data-dismiss="modal" style="display: none;">Close</button>
<button type="button" class="btn btn-link" data-bind="visible: instanceTemplate.editable()" data-dismiss="modal">Cancel</button>
<button type="button" class="btn btn-primary" data-bind="visible: instanceTemplate.editable(), click: save, enable: enableSave() && !isSaving()">Save changes<span data-bind="visible: isSaving" style="display: none;">...</span></button>
</div>
</div>
</div>
</div>
<!-- /ko -->
</div><!-- .panel-body -->
</div><!-- .panel -->
</section>
<!-- /ko -->
<!-- ko with: steps[2] -->
<section data-bind="visible: isStepSelected" style="display: none;">
<h2>Status</h2>
<!-- ko foreach: pollableObjects -->
<ko-status params="pollable: $data"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<section>
<h4><span data-bind="text: name">cm1</span> <span data-bind="text: stage">Unknown</span></h4>
<div class="progress">
<div class="progress-bar" role="progressbar" data-bind="text: textContent,
attr: { 'aria-valuenow': status.percentageComplete },
style: { width: width},
css: { 'progress-bar-danger': status.hasFailed() }" aria-valuemin="0" aria-valuemax="100" aria-valuenow="0" style="width: 0%;">0 / 1</div>
</div>
<h5 data-bind="text: status.description"></h5>
<ol data-bind="foreach: status.descriptionDetails"></ol>
</section>
</ko-status>
<hr data-bind="if: ($index() !== ($parent.pollableObjects.length - 1))">
<ko-status params="pollable: $data"><!-- (c) Copyright 2015 Cloudera, Inc. All rights reserved. -->
<section>
<h4><span data-bind="text: name">cdh1</span> <span data-bind="text: stage">Unknown</span></h4>
<div class="progress">
<div class="progress-bar" role="progressbar" data-bind="text: textContent,
attr: { 'aria-valuenow': status.percentageComplete },
style: { width: width},
css: { 'progress-bar-danger': status.hasFailed() }" aria-valuemin="0" aria-valuemax="100" aria-valuenow="0" style="width: 0%;">0 / 1</div>
</div>
<h5 data-bind="text: status.description"></h5>
<ol data-bind="foreach: status.descriptionDetails"></ol>
</section>
</ko-status>
<hr data-bind="if: ($index() !== ($parent.pollableObjects.length - 1))">
<!-- /ko -->
</section>
<!-- /ko -->
</div>
<h2 data-bind="visible: $root.currentUser.isGuest()" style="display: none;">Insufficient permission to view this page.</h2>
<section class="wizard-buttons">
<section class="container">
<button type="button" class="btn btn-lg btn-default pull-left" data-bind="click: leave, visible: showQuit">
<span class="glyphicon glyphicon-backward"></span>
Quit</button>
<span data-bind="if: $root.currentUser.isAdmin()">
<button type="button" class="btn btn-lg btn-primary pull-right" data-bind="click: onClickContinue, enable: enableContinue() && !isLeaving()">
<span class="glyphicon glyphicon-forward"></span>
Continue<span data-bind="visible: isLeaving" style="display: none;">...</span></button>
</span>
</section>
</section>
</section>
<!-- ko with: commonModals -->
<!-- ko with: errorModal -->
<div class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" data-bind="modal:showModal, attr: {'aria-labelledby' : title}" aria-labelledby="Error">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title" data-bind="html: title">Error</h4>
</div>
<div class="modal-body">
<p data-bind="html: message"></p>
</div>
<div class="modal-footer">
<button type="button" data-dismiss="modal" data-bind="visible: showCancelButton" class="btn btn-link" style="display: none;">Cancel</button>
<button type="button" data-dismiss="modal" data-bind="click: onOK, text: okButtonText, attr: { class : okButtonClass }" class="btn btn-primary">Close</button>
</div>
</div>
</div>
</div>
<!-- /ko -->
<!-- ko with: confirmModal -->
<div class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" data-bind="modal:showModal, attr: {'aria-labelledby' : title}" aria-labelledby="Delete Group: gateway" style="display: none;">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
<h4 class="modal-title" data-bind="html: title">Delete Group: gateway</h4>
</div>
<div class="modal-body">
<p data-bind="html: message">Are you sure?</p>
</div>
<div class="modal-footer">
<button type="button" data-dismiss="modal" data-bind="visible: showCancelButton" class="btn btn-link">Cancel</button>
<button type="button" data-dismiss="modal" data-bind="click: onOK, text: okButtonText, attr: { class : okButtonClass }" class="btn btn-primary">OK</button>
</div>
</div>
</div>
</div>
<!-- /ko -->
<!-- /ko -->
var el = $("div[data-bind~=instanceNamePrefix]");
Ready to run.
Test | Ops/sec | |
---|---|---|
selector |
| ready |
object |
| ready |
jQuery.contains |
| ready |
parents |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.