oracle 容器运行_Oracle应用容器云的自由
oracle 容器運行
在這篇博客文章中,我將介紹如何部署CloudEE封裝在杜克大學應用自由尤伯杯罐子Oracle應用集裝箱云端 。
在Oracle Application Container Cloud中進行部署所需的部署工件是一個ZIP歸檔文件,其中包含應用程序über-jar和清單文件(manifest.json)。 下面列出了CloudEE Duke的manifest.json的Liberty版本。
manifest.json
{"runtime": {"majorVersion": "8"},"command": "java -jar cloudee-duke.jar","release": {"version": "1.0","build": "1","commit": "123"},"notes": "Dukes says hello from Liberty" }您需要指定供Liberty使用的端口。 這可以通過使用環境變量$ {env.PORT}在server.xml中進行配置來完成,如下所示:
<server description="Sample Liberty server"><featureManager><feature>microprofile-1.2</feature></featureManager><httpEndpoint httpPort="${env.PORT}" httpsPort="9443"id="defaultHttpEndpoint" host="*" /><quickStartSecurity userName="duke" userPassword="duke"/><keyStore id="defaultKeyStore" password="Liberty"/> </server>über-jar是通過結合使用Maven資源插件和Liberty Maven插件來生產的:
<plugin><groupId>org.apache.maven.plugins</groupId><artifactId>maven-resources-plugin</artifactId><version>3.0.2</version><executions><execution><id>copy-app</id><phase>package</phase><goals><goal>copy-resources</goal></goals><configuration><outputDirectory>${project.build.directory}/liberty/wlp/usr/servers/defaultServer/dropins</outputDirectory><resources><resource><directory>${project.build.directory}</directory><includes><include>${project.build.finalName}.war</include></includes></resource></resources></configuration></execution></executions> </plugin> <plugin><groupId>net.wasdev.wlp.maven.plugins</groupId><artifactId>liberty-maven-plugin</artifactId><version>2.2</version><extensions>true</extensions><configuration><install><type>webProfile7</type><version>2018.+</version></install><configFile>${basedir}/src/main/liberty/config/server.xml</configFile><serverEnv>${basedir}/src/main/liberty/config/server.env</serverEnv><jvmOptionsFile>${basedir}/src/main/liberty/config/jvm.options</jvmOptionsFile><packageFile>${project.build.directory}/${project.build.finalName}.jar</packageFile><include>runnable</include></configuration> <executions><execution><id>install-liberty</id><phase>prepare-package</phase><goals><goal>install-server</goal></goals></execution><execution><id>package-app</id><phase>package</phase><goals><goal>package-server</goal></goals></execution></executions> </plugin>有關如何使用maven命令生成可部署的ZIP存檔的示例,請參見完整的pom.xml :
mvn clean package assembly:single -Pliberty這將在目標文件夾中生成一個名為cloudee-duke-oracle-liberty.zip的文件。 這是您將部署到Oracle Application Container Cloud的ZIP存檔,如下面的屏幕快照所示。
部署應用程序后,您應該可以訪問hello端點
https://<dependsonyouraccount>.oraclecloud.com/helloZ公爵說你好!
您還將擁有MicroProfile實施提供的運行狀況和指標終結點
https://<dependsonyouraccount>.oraclecloud.com/health {
結果:“ UP”,
檢查:[]}
#TYPE base:classloader_total_loaded_class_count計數器
#HELP base:classloader_total_loaded_class_count顯示自Java虛擬機開始執行以來已加載的類的總數。
基數:classloader_total_loaded_class_count 9430 #TYPE base:cpu_system_load_average量規 …
翻譯自: https://www.javacodegeeks.com/2018/03/liberty-on-oracle-application-container-cloud.html
oracle 容器運行
總結
以上是生活随笔為你收集整理的oracle 容器运行_Oracle应用容器云的自由的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: ug用哪个电脑系统(ug支持什么系统)
- 下一篇: 为什么SpringBoot如此受欢迎?如