mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-09 18:16:10 +00:00
git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@2637 71c3de6d-444a-0410-be80-ed276b4c234a
328 lines
11 KiB
XML
328 lines
11 KiB
XML
<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>
|
|
<parent>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>pom</artifactId>
|
|
<version>1.91-SNAPSHOT</version>
|
|
<relativePath>../pom.xml</relativePath>
|
|
</parent>
|
|
|
|
<artifactId>hudson-war</artifactId>
|
|
<packaging>war</packaging>
|
|
<name>Hudson war</name>
|
|
|
|
<build>
|
|
<directory>target</directory>
|
|
<finalName>hudson</finalName>
|
|
|
|
<plugins>
|
|
<plugin>
|
|
<artifactId>maven-war-plugin</artifactId>
|
|
<version>2.0</version>
|
|
<configuration>
|
|
<webResources>
|
|
<resource>
|
|
<directory>${basedir}/resources</directory>
|
|
</resource>
|
|
<resource>
|
|
<directory>${basedir}/target/generated-resources</directory>
|
|
</resource>
|
|
</webResources>
|
|
<!-- for putting Main-Class into war -->
|
|
<archive>
|
|
<manifest>
|
|
<mainClass>Main</mainClass>
|
|
</manifest>
|
|
</archive>
|
|
</configuration>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-antrun-plugin</artifactId>
|
|
<executions>
|
|
<!-- compile src/launcher/java/Main.java into hudson.war -->
|
|
<execution>
|
|
<phase>generate-resources</phase>
|
|
<configuration>
|
|
<tasks>
|
|
<mkdir dir="target/generated-resources" />
|
|
<!-- needs to be forked because Maven doesn't seem to put tools.jar in classpath -->
|
|
<javac srcdir="src/launcher/java" includes="*.java" source="1.4" target="1.4" destdir="target/generated-resources" fork="true" debug="on" />
|
|
</tasks>
|
|
</configuration>
|
|
<goals>
|
|
<goal>run</goal>
|
|
</goals>
|
|
</execution>
|
|
<!-- sign the war -->
|
|
<execution>
|
|
<id>signWar</id>
|
|
<phase>verify</phase>
|
|
<goals>
|
|
<goal>run</goal>
|
|
</goals>
|
|
<configuration>
|
|
<tasks>
|
|
<!-- see ../jnlp-agent/pom.xml for details -->
|
|
<signjar jar="target/hudson.war" alias="${hudson.sign.alias}" keystore="${hudson.sign.keystore}" storepass="${hudson.sign.storepass}" />
|
|
</tasks>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.codehaus.mojo</groupId>
|
|
<artifactId>dependency-maven-plugin</artifactId>
|
|
<executions>
|
|
<!-- for copying remoting jar to $WAR/WEB-INF/slave.jar -->
|
|
<execution>
|
|
<id>copy-slave.jar</id>
|
|
<phase>generate-resources</phase>
|
|
<goals>
|
|
<goal>copy</goal>
|
|
</goals>
|
|
<configuration>
|
|
<artifactItems>
|
|
<artifactItem>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>remoting</artifactId>
|
|
<version>${version}</version>
|
|
<classifier>${hudsonRemotingClassifier}</classifier>
|
|
<destFileName>slave.jar</destFileName>
|
|
</artifactItem>
|
|
</artifactItems>
|
|
<outputDirectory>${basedir}/target/generated-resources/WEB-INF</outputDirectory>
|
|
</configuration>
|
|
</execution>
|
|
<!--
|
|
for copying remoting jar to $WAR/WEB-INF/remoting.jar
|
|
-->
|
|
<execution>
|
|
<id>copy-remoting.jar</id>
|
|
<phase>generate-resources</phase>
|
|
<goals>
|
|
<goal>copy</goal>
|
|
</goals>
|
|
<configuration>
|
|
<artifactItems>
|
|
<artifactItem>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>remoting</artifactId>
|
|
<version>${version}</version>
|
|
<classifier>${hudsonRemotingClassifier}</classifier>
|
|
<destFileName>remoting.jar</destFileName>
|
|
</artifactItem>
|
|
</artifactItems>
|
|
<outputDirectory>${basedir}/target/generated-resources/WEB-INF</outputDirectory>
|
|
</configuration>
|
|
</execution>
|
|
<!-- for copying remoting jar to $WAR/WEB-INF/jnlp-agent.jar -->
|
|
<execution>
|
|
<id>copy-jnlp-agent.jar</id>
|
|
<phase>generate-resources</phase>
|
|
<goals>
|
|
<goal>copy</goal>
|
|
</goals>
|
|
<configuration>
|
|
<artifactItems>
|
|
<artifactItem>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>jnlp-agent</artifactId>
|
|
<version>${version}</version>
|
|
<destFileName>jnlp-agent.jar</destFileName>
|
|
</artifactItem>
|
|
</artifactItems>
|
|
<outputDirectory>${basedir}/target/generated-resources/WEB-INF</outputDirectory>
|
|
</configuration>
|
|
</execution>
|
|
<!-- for copying winstone.jar -->
|
|
<execution>
|
|
<id>copy-winstone.jar</id>
|
|
<phase>generate-resources</phase>
|
|
<goals>
|
|
<goal>copy</goal>
|
|
</goals>
|
|
<configuration>
|
|
<artifactItems>
|
|
<artifactItem>
|
|
<groupId>winstone</groupId>
|
|
<artifactId>winstone</artifactId>
|
|
<version>0.9.6</version>
|
|
<destFileName>winstone.jar</destFileName>
|
|
</artifactItem>
|
|
</artifactItems>
|
|
<outputDirectory>${basedir}/target/generated-resources</outputDirectory>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.mortbay.jetty</groupId>
|
|
<artifactId>maven-jetty-plugin</artifactId>
|
|
<version>6.1.1</version>
|
|
<configuration>
|
|
<contextPath>/</contextPath>
|
|
<!--
|
|
read directly from core module's output directory,
|
|
so that changes are picked up right away without running mvn.
|
|
-->
|
|
<classesDirectory>../core/target/classes</classesDirectory>
|
|
<!--
|
|
enable automatic reloading when some files change.
|
|
-->
|
|
<!--scanIntervalSeconds>1</scanIntervalSeconds-->
|
|
<webAppSourceDirectory>${basedir}/resources</webAppSourceDirectory>
|
|
<!--realm for debug
|
|
<userRealms>
|
|
<userRealm implementation="org.mortbay.jetty.security.HashUserRealm">
|
|
<name>hudsonRealm</name>
|
|
<config>src/realm.properties</config>
|
|
</userRealm>
|
|
</userRealms>-->
|
|
<systemProperties>
|
|
<systemProperty>
|
|
<name>HUDSON_HOME</name>
|
|
<value>${basedir}/work</value>
|
|
</systemProperty>
|
|
<systemProperty>
|
|
<!-- always reload views during debugging -->
|
|
<name>stapler.jelly.noCache</name>
|
|
<value>true</value>
|
|
</systemProperty>
|
|
<systemProperty>
|
|
<!-- enable experimental Maven support during debugging -->
|
|
<name>hudson.maven</name>
|
|
<value>true</value>
|
|
</systemProperty>
|
|
<systemProperty>
|
|
<!-- load view resources from the source directly, again for real time change -->
|
|
<name>stapler.resourcePath</name>
|
|
<value>../core/src/main/resources</value>
|
|
</systemProperty>
|
|
</systemProperties>
|
|
</configuration>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
|
|
<profiles>
|
|
<profile>
|
|
<id>debug</id>
|
|
<activation>
|
|
<activeByDefault>true</activeByDefault>
|
|
</activation>
|
|
<properties>
|
|
<hudsonClassifier />
|
|
<hudsonRemotingClassifier />
|
|
</properties>
|
|
</profile>
|
|
<profile>
|
|
<id>release</id>
|
|
<properties>
|
|
<hudsonClassifier>jdk14</hudsonClassifier>
|
|
<hudsonRemotingClassifier>jdk14-jar-with-dependencies</hudsonRemotingClassifier>
|
|
</properties>
|
|
</profile>
|
|
</profiles>
|
|
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>remoting</artifactId>
|
|
<version>${version}</version>
|
|
<classifier>${hudsonClassifier}</classifier>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>jnlp-agent</artifactId>
|
|
<version>${version}</version>
|
|
<!--
|
|
not really a test scope, but we use dependency-maven-plugin to copy this jar,
|
|
so we don't want this to be bundled in war by maven-war-plugin.
|
|
-->
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>hudson-core</artifactId>
|
|
<version>${version}</version>
|
|
<classifier>${hudsonClassifier}</classifier>
|
|
<exclusions>
|
|
<!-- jars that are not needed in war -->
|
|
<exclusion>
|
|
<groupId>javax.servlet</groupId>
|
|
<artifactId>servlet-api</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>xalan</groupId>
|
|
<artifactId>xalan</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>xerces</groupId>
|
|
<artifactId>xercesImpl</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>xml-apis</groupId>
|
|
<artifactId>xml-apis</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>xerces</groupId>
|
|
<artifactId>xmlParserAPIs</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>msv</groupId>
|
|
<artifactId>xsdlib</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>msv</groupId>
|
|
<artifactId>relaxngDatatype</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>forehead</groupId>
|
|
<artifactId>forehead</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>jdom</groupId>
|
|
<artifactId>jdom</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>xom</groupId>
|
|
<artifactId>xom</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>commons-cli</groupId>
|
|
<artifactId>commons-cli</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>commons-discovery</groupId>
|
|
<artifactId>commons-discovery</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>commons-jelly</groupId>
|
|
<artifactId>commons-jelly-tags-junit</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>jaxme</groupId>
|
|
<artifactId>jaxme-api</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>junit</groupId>
|
|
<artifactId>junit</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>stax</groupId>
|
|
<artifactId>stax-api</artifactId>
|
|
</exclusion>
|
|
<exclusion>
|
|
<groupId>pull-parser</groupId>
|
|
<artifactId>pull-parser</artifactId>
|
|
</exclusion>
|
|
<!-- we want jdk14 version, but core depends on jdk1.5 version -->
|
|
<exclusion>
|
|
<groupId>org.jvnet.hudson.main</groupId>
|
|
<artifactId>remoting</artifactId>
|
|
</exclusion>
|
|
</exclusions>
|
|
</dependency>
|
|
</dependencies>
|
|
</project> |