- 创建一个定制的 WebSphere CloudBurst 模式接下来,您将创建一个包含脚本包的模式:
- 从 Welcome 页面中,在控制台中,单击 Create patterns。
- 在本例中,您将使用 WebSphere single server 模式的副本作为定制模式的基础。要克隆模式,单击此模式并选择右上方工具栏中的 Clone 图标。在对话框中提供有关新模式的必要信息(图 6)。图 6. 创建模式
 - 要进入编辑模式,单击右上方工具栏中的 Edit 按钮。
- 在 Pattern Editor 模板上的下拉菜单中,选择 Script Packages。
- 将 Rational Build Forge Integration 脚本包拖拽到画布中的 Standalone server 组件上。添加了脚本包后,单击页面右上角的 Done editing 链接来返回到 Patterns 页面。
- 此时,可以选择与脚本包相同的方式锁定模式。 图 7. 编辑模式

- 部署 WebSphere CloudBurst 模式包含 Rational Build Forge 集成脚本包的 WebSphere CloudBurst 模式现在已经准备好进行部署:
- 从模式定义面板中,单击 Deploy 按钮并为虚拟系统提供一个名称。
- 单击 Configure virtual parts 并单击 Standalone server。 图 8. 部署模式

在 Standalone server configuration 面板中,提供了诸如 cell 名、节点名和密码等 WebSphere 配置(图 8)。还要注意,为被定义为 Rational Build Forge Integration 脚本包的一部分的 4 个变量提供了值。虽然这些值本可以直接放入到模式中,但是在部署时提供这些值可以实现灵活性,即对多个不同 Rational Build Forge 项目甚至不同的 Rational Build Forge 服务器使用相同的模式。 - 在提供了所有必要的信息后,单击 OK 开始部署过程。当部署过程完成后,Virtual Systems 页面将被更新以包含虚拟系统的当前状态。图 9. 脚本包执行

当脚本包完成运行后,Rational Build Forge 控制台应当显示一条消息,表明在模式部署期间被引用的项目已成功执行(图 10)。 图 10. Rational Build Forge 作业 上面所述的 MyWebProject 项目中的每一个步骤都在为您的 WebSphere CloudBurst 模式中的 Standalone server 部分创建的虚拟机上运行。
- 检验结果要确认项目获得了预期的结果 —— 在本例中,意味着样例 Web 服务应用程序完成了安装 —— 检查 WebSphere Application Server 管理控制台,确保该应用程序出现在其中(图 11)。
图 11. WebSphere Application Server 管理控制台 在上图中,注意样例 Web 服务应用程序 JaxWSServicesSamples 被安装到由 WebSphere CloudBurst 创建的 WebSphere Application Server 实例。
|