将Jenkins作为Heroku应用程序加载非常容易
1)pom.xml文件:
<?xml version="1.0" encoding="UTF-8"?>
<!--
Just need a plain and mostly empty pom.xml for Orchard to detect that this is a Java application
-->
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.example</groupId>
<version>1.0-SNAPSHOT</version>
<artifactId>helloworld</artifactId>
</project>
web: java -jar jenkins.war --httpPort=$PORT --ajp13Port=-1 --httpsPort=-1
真正的问题在于 jenkins 使用本地文件系统进行存储,而在 Heroku 环境中,本地存储不是持久的,因此您需要定期管理您的配置或使用 github 存储附加组件。