<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/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <name>Activiti - Rest</name>
  <artifactId>activiti-webapp-rest2</artifactId>
  <packaging>war</packaging>

  <parent>
    <groupId>org.activiti</groupId>
    <artifactId>activiti-root</artifactId>
    <relativePath>../..</relativePath>
    <version>5.20.0</version>
  </parent>
  
  <build>
    <plugins>
      <plugin>
        <groupId>org.zeroturnaround</groupId>
        <artifactId>jrebel-maven-plugin</artifactId>
        <executions>
          <execution>
            <id>generate-rebel-xml</id>
            <phase>process-resources</phase>
            <goals>
              <goal>generate</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
	    <groupId>org.apache.tomcat.maven</groupId>
        <artifactId>tomcat7-maven-plugin</artifactId>
		<configuration>
		  <port>8080</port>
		  <path>/activiti-rest</path>
		  <systemProperties>
		    <com.sun.management.jmxremote.port>4000</com.sun.management.jmxremote.port>
          </systemProperties>
		</configuration>
      </plugin>
    </plugins>
    <pluginManagement>
      <plugins>
        <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
        <plugin>
          <groupId>org.eclipse.m2e</groupId>
          <artifactId>lifecycle-mapping</artifactId>
          <version>1.0.0</version>
          <configuration>
            <lifecycleMappingMetadata>
              <pluginExecutions>
                <pluginExecution>
                  <pluginExecutionFilter>
                    <groupId>
                      org.zeroturnaround
                    </groupId>
                    <artifactId>
                      jrebel-maven-plugin
                    </artifactId>
                    <versionRange>
                      [1.0.7,)
                    </versionRange>
                    <goals>
                      <goal>generate</goal>
                    </goals>
                  </pluginExecutionFilter>
                  <action>
                    <ignore></ignore>
                  </action>
                </pluginExecution>
              </pluginExecutions>
            </lifecycleMappingMetadata>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>
  </build>

  <profiles>
    <profile>
	  <id>buildExecutableWar</id>
	    <build>
		  <plugins>
            <plugin>
              <groupId>org.apache.tomcat.maven</groupId>
			  <artifactId>tomcat7-maven-plugin</artifactId>
			  <version>2.1</version>
			  <configuration>
			    <path>/</path>
			  </configuration>
			  <executions>
			    <execution>
				  <id>tomcat-run</id>
				  <goals>
				    <goal>exec-war-only</goal>
				  </goals>
				  <phase>package</phase>
				  <configuration>
                    <path>/activiti-rest</path>
                  </configuration>
				</execution>
			  </executions>
			</plugin>
		  </plugins>
	  </build>
    </profile>
  </profiles>
  
  <dependencies>
    <dependency>
      <groupId>org.activiti</groupId>
      <artifactId>activiti-engine</artifactId>
    </dependency>
    <dependency>
      <groupId>org.activiti</groupId>
      <artifactId>activiti-spring</artifactId>
    </dependency>
    <dependency>
      <groupId>org.activiti</groupId>
      <artifactId>activiti-rest</artifactId>
    </dependency>
    <dependency>
      <groupId>org.activiti</groupId>
      <artifactId>activiti-json-converter</artifactId>
    </dependency>
    <dependency>
      <groupId>com.h2database</groupId>
      <artifactId>h2</artifactId>
    </dependency>
    <dependency>
      <groupId>org.codehaus.groovy</groupId>
      <artifactId>groovy-all</artifactId>
    </dependency>
    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>javax.servlet-api</artifactId>
      <version>3.1.0</version>
      <scope>provided</scope>
    </dependency>
  </dependencies>
</project>
