initializeCluster.php 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334
  1. <?php require_once "./head.inc"; ?>
  2. <html>
  3. <head>
  4. <title id="pageTitleId"><?php echo $RES['page.title'] ?></title>
  5. <!-- CSS -->
  6. <link type="text/css" rel="stylesheet" href="../yui-3.5.1/build/cssreset/cssreset-min.css">
  7. <link type="text/css" rel="stylesheet" href="../css/bootstrap.css" media="screen"/>
  8. <link type="text/css" rel="stylesheet" href="../css/common.css" media="screen"/>
  9. <link type="text/css" rel="stylesheet" href="../css/common2.css" media="screen"/>
  10. <link type="text/css" rel="stylesheet" href="../css/common3.css" media="screen"/>
  11. <link type="text/css" rel="stylesheet" href="../css/selectHosts.css" media="screen"/>
  12. <link rel="shortcut icon" href="../images/logo-micro.gif">
  13. <!-- End CSS -->
  14. </head>
  15. <body class="yui3-skin-sam">
  16. <?php require "./topnav.htmli"; ?>
  17. <div id="ContentDivId">
  18. <!-- List of clusters
  19. <div name="clustersListDiv" id="clustersListDivId">
  20. </div>
  21. -->
  22. <!-- Installation Wizard -->
  23. <div name="installationWizardDiv" id="installationWizardDivId" style="display:block">
  24. <div name="installationWizardProgressBarDiv" id="installationWizardProgressBarDivId">
  25. <ol id="installationWizardProgressBarListId">
  26. <li id="createClusterStageId" class="installationWizardFirstStage installationWizardCurrentStage">
  27. <div>
  28. <span class="installationWizardStageNumber">
  29. 1
  30. </span>
  31. Create Cluster
  32. </div>
  33. </li>
  34. <li id="addNodesStageId" class="installationWizardUnvisitedStage">
  35. <div>
  36. <span class="installationWizardStageNumber">
  37. 2
  38. </span>
  39. Add Nodes
  40. </div>
  41. </li>
  42. <li id="selectServicesStageId" class="installationWizardUnvisitedStage">
  43. <div>
  44. <span class="installationWizardStageNumber">
  45. 3
  46. </span>
  47. Select Services
  48. </div>
  49. </li>
  50. <li id="assignHostsStageId" class="installationWizardUnvisitedStage">
  51. <div>
  52. <span class="installationWizardStageNumber">
  53. 4
  54. </span>
  55. Assign Hosts
  56. </div>
  57. </li>
  58. <li id="configureClusterStageId" class="installationWizardUnvisitedStage">
  59. <div>
  60. <span class="installationWizardStageNumber">
  61. 5
  62. </span>
  63. Select Mount Points
  64. </div>
  65. </li>
  66. <li id="configureClusterAdvancedStageId" class="installationWizardUnvisitedStage">
  67. <div>
  68. <span class="installationWizardStageNumber">
  69. 6
  70. </span>
  71. Custom Config
  72. </div>
  73. </li>
  74. <li id="deployClusterStageId" class="installationWizardLastStage installationWizardUnvisitedStage">
  75. <div>
  76. <span class="installationWizardStageNumber">
  77. 7
  78. </span>
  79. Review &amp; Deploy
  80. </div>
  81. </li>
  82. </ol>
  83. </div>
  84. <?php require "./utils.htmli"; ?>
  85. <div id="installationMainFormsDivId">
  86. <div id="createClusterCoreDivId">
  87. <div class="pageSummary">
  88. <h2><?php echo $RES['initWizard.createCluster.pageSummary.header'] ?></h2>
  89. <p><?php echo $RES['initWizard.createCluster.pageSummary.body'] ?></p>
  90. </div>
  91. <div id="formStatusDivId" class="formStatusBar" style="display:none">
  92. </div>
  93. <div class="pageContent">
  94. <form id="createClusterFormId">
  95. <label for="clusterNameId"><?php echo $RES['initWizard.createCluster.clusterName.label'] ?></label>
  96. <input type="text" name="clusterName" id="clusterNameId" placeholder="cluster name" value="">
  97. </form>
  98. <a href="javascript:void 0" class="btn btn-large" id="createClusterSubmitButtonId"><?php echo $RES['initWizard.createCluster.submit.label'] ?></a>
  99. </div>
  100. </div>
  101. <div id="addNodesCoreDivId" style="display:none">
  102. <div class="pageSummary">
  103. <h2><?php echo $RES['initWizard.addNodes.pageSummary.header'] ?></h2>
  104. <?php echo $RES['initWizard.addNodes.pageSummary.body'] ?>
  105. </div>
  106. <div id="formStatusDivId" class="alert alert-error" style="display:none">
  107. </div>
  108. <div class="pageContent">
  109. <form id="addNodesFilesFormId" enctype="multipart/form-data" method="post">
  110. <label for="clusterDeployUserId"><?php echo $RES['common.sshUsername.label'] ?></label>
  111. <input type="text" name="ClusterDeployUser" id="clusterDeployUserId" value="root" placeholder="">
  112. <div class="separator"></div>
  113. <label for="clusterDeployUserIdentityFileId"><?php echo $RES['common.sshPrivateKeyFile.label'] ?></label>
  114. <input type="file" name="clusterDeployUserIdentityFile" id="clusterDeployUserIdentityFileId" value="" placeholder="">
  115. <div class="separator"></div>
  116. <label for="clusterHostsFileId"><?php echo $RES['common.hostsFile.label'] ?></label>
  117. <input type="file" name="clusterHostsFile" id="clusterHostsFileId" value="" placeholder="">
  118. <div class="separator"></div>
  119. <div id="yumMirrorSupportFormId">
  120. <div id="yumMirrorSupportFormButtonWrapperId">
  121. <label class="checkbox" for="yumMirrorSupportFormButtonId"><?php echo $RES['initWizard.addNodes.useLocalYum.label'] ?>
  122. <input type="checkbox" name="YumMirrorSupportFormButton" id="yumMirrorSupportFormButtonId" value="" placeholder="">
  123. </label>
  124. </div>
  125. <div id="yumMirrorSupportFormFieldsId" style="display:none">
  126. <label for="yumRepoFilePathId"><?php echo $RES['initWizard.addNodes.yumRepoFilePath.label'] ?></label>
  127. <input type="text" name="YumRepoFilePath" id="yumRepoFilePathId" value="" placeholder="">
  128. <label for="hmcArtifactsDownloadUrlId"><?php echo $RES['initWizard.addNodes.apacheArtifactsDownloadUrl.label'] ?></label>
  129. <input type="text" name="HmcArtifactsDownloadUrl" id="hmcArtifactsDownloadUrlId" value="" placeholder="">
  130. <label for="hmcGplArtifactsDownloadUrlId"><?php echo $RES['initWizard.addNodes.gplArtifactsDownloadUrl.label'] ?></label>
  131. <input type="text" name="HmcGplArtifactsDownloadUrl" id="hmcGplArtifactsDownloadUrlId" value="" placeholder="">
  132. </div>
  133. </div>
  134. <div id="fileUploadWrapperDivId">
  135. <iframe name="fileUploadTarget" id="fileUploadTargetId" src="about:blank" style="display:none"></iframe>
  136. </div>
  137. </form>
  138. <div class="separator"></div>
  139. <a href="javascript:void 0" class="btn btn-large" id="addNodesSubmitButtonId"><?php echo $RES['initWizard.addNodes.submit.label'] ?></a>
  140. </div>
  141. </div>
  142. <div name="selectServicesCoreDiv" id="selectServicesCoreDivId" style="display:none">
  143. <fieldset>
  144. <div class="pageSummary">
  145. <h2><?php echo $RES['initWizard.selectServices.pageSummary.header'] ?></h2>
  146. <p><?php echo $RES['initWizard.selectServices.pageSummary.body'] ?></p>
  147. </div>
  148. <div style="width:100%;height:40px">
  149. <div id="formStatusDivId" class="formStatusBar" style="display:none">
  150. </div>
  151. </div>
  152. <div class="pageContent" style="margin-top:14px">
  153. <div id="selectCoreServicesListId">
  154. <ul id="selectCoreServicesListUlId">
  155. <div id="selectCoreServicesDynamicRenderDivId">
  156. </div>
  157. </ul>
  158. </div>
  159. <div id="selectOptionalServicesListId">
  160. <ul id="selectOptionalServicesListUlId">
  161. <div id="selectOptionalServicesDynamicRenderDivId">
  162. </div>
  163. </ul>
  164. </div>
  165. <div id="selectNonSelectableServicesListId">
  166. <ul id="selectNonSelectableServicesListUlId">
  167. <div id="selectNonSelectableServicesDynamicRenderDivId">
  168. </div>
  169. </ul>
  170. </div>
  171. </div>
  172. </fieldset>
  173. <a href="javascript:void 0" class="btn btn-large" style="margin:20px 0 0 60px" id="selectServicesSubmitButtonId" class="submitButton"><?php echo $RES['initWizard.selectServices.submit.label'] ?></a>
  174. </div>
  175. <!-- End of selectServicesCoreDivId -->
  176. <div name="assignHostsCoreDiv" id="assignHostsCoreDivId" style="display:none">
  177. <div id="statusDivId">
  178. </div>
  179. <div class="pageSummary">
  180. <h2><?php echo $RES['initWizard.assignMasters.pageSummary.header'] ?></h2>
  181. <p><?php echo $RES['initWizard.assignMasters.pageSummary.body'] ?></p>
  182. </div>
  183. <div id="formStatusDivId" class="formStatusBar" style="display:none">
  184. </div>
  185. <div id="masterServices">
  186. <div id="masterServicesToHostsContainer">
  187. <div id="masterServicesToHosts"></div>
  188. <a href="javascript:void 0" class="btn btn-large" id="selectServiceMastersSubmitButtonId"><?php echo $RES['initWizard.assignMasters.submit.label'] ?></a>
  189. </div>
  190. <div id="hostsToMasterServices"></div>
  191. </div>
  192. <div style="clear:both"></div>
  193. </div>
  194. <div name="configureClusterCoreDiv" id="configureClusterCoreDivId" style="display:none">
  195. <div class="pageSummary">
  196. <h2><?php echo $RES['initWizard.configureCluster.pageSummary.header'] ?></h2>
  197. <p><?php echo $RES['initWizard.configureCluster.pageSummary.body'] ?></p>
  198. </div>
  199. <div id="formStatusDivId" class="formStatusBar" style="display:none">
  200. </div>
  201. <div id="configureClusterInputContainerDivId">
  202. <form id="configureClusterFormId">
  203. <div name="configureClusterInputDiv" id="configureClusterInputDivId">
  204. <fieldset id="configureClusterInputFieldSetId">
  205. <!--<legend>Select mount points</legend>-->
  206. <div name="configureClusterMountPointsInputDiv" id="configureClusterMountPointsInputDivId">
  207. <div id="configureClusterMountPointsDynamicRenderDivId"></div>
  208. <p>
  209. <label for="customMountPoints"><?php echo $RES['initWizard.configureCluster.customMountPoints.label'] ?></label>
  210. <input type="text" name="customMountPoints" id="customMountPointsId" value="" placeholder="Comma-Separated List">
  211. </p>
  212. </div>
  213. <!-- Additional <div>s for other categories of cluster configuration go here -->
  214. </fieldset>
  215. </div>
  216. <a id="previewLinkId" href="javascript:void 0"><?php echo $RES['initWizard.configureCluster.preview.label'] ?></a>
  217. </form>
  218. <a href="javascript:void 0" class="btn btn-large" id="configureClusterSubmitButtonId"><?php echo $RES['initWizard.configureCluster.submit.label'] ?></a>
  219. </div>
  220. <div id="configureClusterDisplayDivId" style="display:none">
  221. <fieldset>
  222. <!--<legend>Effective mount points</legend>-->
  223. <div name="configureClusterMountPointsDisplayDiv" id="configureClusterMountPointsDisplayDivId">
  224. </div>
  225. </fieldset>
  226. </div>
  227. </div>
  228. <div id="configureClusterAdvancedCoreDivId" style="display:none">
  229. <div class="pageSummary">
  230. <h2><?php echo $RES['initWizard.configureClusterAdvanced.pageSummary.header'] ?></h2>
  231. <p><?php echo $RES['initWizard.configureClusterAdvanced.pageSummary.body'] ?></p>
  232. </div>
  233. <div id="formStatusDivId" class="formStatusBar" style="display:none">
  234. </div>
  235. <form id="configureClusterAdvancedFormId">
  236. <fieldset id="configureClusterAdvancedFieldSetId">
  237. <!--<legend>Advanced configuration</legend>-->
  238. <div id="configureClusterAdvancedDynamicRenderDivId"></div>
  239. </fieldset>
  240. </form>
  241. <label></label>
  242. <a href="javascript:void 0" class="btn btn-large" id="configureClusterAdvancedSubmitButtonId"><?php echo $RES['initWizard.configureClusterAdvanced.submit.label'] ?></a>
  243. </div>
  244. <div name="deployCoreDiv" id="deployCoreDivId" style="display:none">
  245. <div class="pageSummary">
  246. <h2><?php echo $RES['initWizard.reviewAndDeploy.pageSummary.header'] ?></h2>
  247. <p><?php echo $RES['initWizard.reviewAndDeploy.pageSummary.body'] ?></p>
  248. </div>
  249. <div id="formStatusDivId" class="formStatusBar" style="display:none">
  250. </div>
  251. <form id="deployFormId">
  252. <fieldset id="deployFieldSetId">
  253. <!--<legend>Review your settings</legend>-->
  254. <div id="deployDynamicRenderDivId"></div>
  255. </fieldset>
  256. </form>
  257. <label></label>
  258. <a href="javascript:void 0" class="btn btn-large" id="deploySubmitButtonId" value="Deploy"><?php echo $RES['initWizard.reviewAndDeploy.submit.label'] ?></a>
  259. </div>
  260. <?php require "./txnUtils.htmli"; ?>
  261. </div>
  262. </div>
  263. <!-- End of installation Wizard -->
  264. </div>
  265. <?php require "./footer.htmli"; ?>
  266. <!-- Javascript Scaffolding -->
  267. <script type="text/javascript">
  268. var freshInstall = true;
  269. var nodesAction = "addNodes";
  270. var InstallationWizard = {
  271. CreateCluster:
  272. {},
  273. AddNodes:
  274. {},
  275. AddNodesProgress:
  276. {},
  277. SelectServices:
  278. {},
  279. AssignMasters:
  280. {},
  281. ConfigureCluster:
  282. {},
  283. ConfigureServices:
  284. {},
  285. ReviewAndDeploy:
  286. {},
  287. DeployProgress:
  288. {}
  289. };
  290. var jsFilesToLoad = [
  291. '../js/ext/jquery.min.js',
  292. '../js/ext/bootstrap.min.js',
  293. '../js/utils.js',
  294. '../js/txnUtils.js',
  295. '../js/installationWizard.js',
  296. '../js/createCluster.js',
  297. '../js/addNodes.js',
  298. '../js/addNodesProgress.js',
  299. '../js/selectServices.js',
  300. '../js/assignMasters.js',
  301. '../js/configureCluster.js',
  302. '../js/configureServicesUtils.js',
  303. '../js/configureServices.js',
  304. '../js/reviewAndDeploy.js',
  305. '../js/deployProgress.js'
  306. ];
  307. </script>
  308. <?php require "./bootstrapJs.htmli"; ?>
  309. <!-- End of Javascript Scaffolding -->
  310. </body>
  311. </html>