<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>
	<groupId>org.aludratest</groupId>
	<artifactId>cloud-manager-parent</artifactId>
	<version>1</version>
	<name>AludraTest Cloud Manager Parent POM</name>
	<description>Parent POM for AludraTest Cloud Manager modules.</description>
	<packaging>pom</packaging>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<!-- set to "deploy site-deploy" in subprojects to also deploy project's 
			site to GitHub. -->
		<aludratest.release.goals>deploy</aludratest.release.goals>
	</properties>

	<licenses>
		<license>
			<name>Apache License 2.0</name>
			<url>http://www.apache.org/licenses/LICENSE-2.0</url>
		</license>
	</licenses>

	<organization>
		<name>aludratest.org</name>
		<url>http://www.aludratest.org/</url>
	</organization>

	<url>http://www.aludratest.org/</url>

	<developers>
		<developer>
			<name>Florian Albrecht</name>
			<id>falbrech-hsdg</id>
			<organization>Hamburg Sud</organization>
			<organizationUrl>http://www.hamburgsud.com/</organizationUrl>
			<timezone>+1</timezone>
			<roles>
				<role>architect</role>
				<role>developer</role>
				<role>administrator</role>
			</roles>
		</developer>
	</developers>

	<dependencies>
		<dependency>
			<groupId>org.codehaus.plexus</groupId>
			<artifactId>plexus-container-default</artifactId>
			<version>1.6</version>
			<!-- exclude google collections, as it conflicts with Guava (required 
				by Selenium) -->
			<exclusions>
				<exclusion>
					<groupId>com.google.collections</groupId>
					<artifactId>google-collections</artifactId>
				</exclusion>
			</exclusions>
		</dependency>

		<dependency>
			<groupId>org.codehaus.plexus</groupId>
			<artifactId>plexus-component-annotations</artifactId>
			<version>1.6</version>
		</dependency>

	</dependencies>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>org.apache.httpcomponents</groupId>
				<artifactId>httpclient</artifactId>
				<version>4.4.1</version>
			</dependency>
			<dependency>
				<groupId>commons-io</groupId>
				<artifactId>commons-io</artifactId>
				<version>2.4</version>
			</dependency>

			<dependency>
				<groupId>junit</groupId>
				<artifactId>junit</artifactId>
				<version>4.11</version>
				<scope>test</scope>
			</dependency>
			<dependency>
				<groupId>org.slf4j</groupId>
				<artifactId>slf4j-log4j12</artifactId>
				<version>1.6.4</version>
				<scope>test</scope>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>3.1</version>
				<configuration>
					<source>1.6</source>
					<target>1.6</target>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
				<version>2.3</version>
				<executions>
					<execution>
						<id>attach-sources</id>
						<goals>
							<goal>jar-no-fork</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<!-- generate components.xml for Plexus -->
			<plugin>
				<groupId>org.codehaus.plexus</groupId>
				<artifactId>plexus-component-metadata</artifactId>
				<version>1.6</version>
				<executions>
					<execution>
						<goals>
							<goal>generate-metadata</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-enforcer-plugin</artifactId>
				<version>1.3.1</version>
				<configuration>
					<rules>
						<requireReleaseDeps>
							<message>No Snapshots Allowed!</message>
						</requireReleaseDeps>
					</rules>
					<fail>true</fail>
				</configuration>
			</plugin>
			
			<!-- check license headers -->
			<plugin>
				<groupId>com.mycila</groupId>
				<artifactId>license-maven-plugin</artifactId>
				<version>2.6</version>
				<configuration>
					<header>src/license/license-template.txt</header>
					<properties>
						<owner>AludraTest.org and the contributors</owner>
						<year>2010-2015</year>
					</properties>
					<includes>
						<include>src/main/java/**/*.java</include>
						<include>src/test/java/**/*.java</include>
					</includes>
					<mapping>
						<java>SLASHSTAR_STYLE</java>
					</mapping>
				</configuration>
				<executions>
					<execution>
						<goals>
							<goal>check</goal>
						</goals>
						<phase>verify</phase>
					</execution>

				</executions>
			</plugin>
			

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-site-plugin</artifactId>
				<version>3.4</version>
				<configuration>
					<!-- site deployment is handled by GitHub plugin, so disable it here -->
					<skipDeploy>true</skipDeploy>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-release-plugin</artifactId>
				<version>2.5.1</version>
				<configuration>
					<goals>${aludratest.release.goals}</goals>
				</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.codehaus.plexus
										</groupId>
										<artifactId>
											plexus-component-metadata
										</artifactId>
										<versionRange>
											[1.6,)
										</versionRange>
										<goals>
											<goal>
												generate-metadata
											</goal>
										</goals>
									</pluginExecutionFilter>
									<action>
										<ignore />
									</action>
								</pluginExecution>
							</pluginExecutions>
						</lifecycleMappingMetadata>
					</configuration>
				</plugin>

				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-javadoc-plugin</artifactId>
					<version>2.9.1</version>
				</plugin>

				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-deploy-plugin</artifactId>
					<version>2.8.2</version>
				</plugin>
			</plugins>
		</pluginManagement>
	</build>

	<reporting>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>2.9.1</version>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-report-plugin</artifactId>
				<version>2.17</version>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-pmd-plugin</artifactId>
				<!-- MUST be 3.1, due to incompatible ASM dependencies -->
				<version>3.1</version>
				<configuration>
					<rulesets>
						<ruleset>/rulesets/java/basic.xml</ruleset>
						<ruleset>/rulesets/java/braces.xml</ruleset>
					</rulesets>
					<typeResolution>true</typeResolution>
					<targetJdk>1.6</targetJdk>
					<failurePriority>2</failurePriority>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-jxr-plugin</artifactId>
				<version>2.4</version>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-project-info-reports-plugin</artifactId>
				<version>2.7</version>
				<configuration>
					<dependencyDetailsEnabled>false</dependencyDetailsEnabled>
				</configuration>
			</plugin>
		</plugins>
	</reporting>

	<profiles>
		<!-- Profile to activate for all deployment operations (Snapshots and Releases). -->
		<profile>
			<id>aludratest-sign</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<version>1.5</version>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
		
		<!-- download an run ConQAT analysis when Profile is active -->
		<profile>
			<id>run-conqat</id>
			<build>
				<plugins>
					<!-- download ConQAT -->
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-antrun-plugin</artifactId>
						<version>1.7</version>
						<executions>
							<execution>
								<id>download-and-run-conqat</id>
								<phase>site</phase>
								<goals><goal>run</goal></goals>
							</execution>
						</executions>
						<configuration>
							<target>
								<mkdir dir="conqat/engine" />
								<get src="https://www.cqse.eu/download/conqat/conqat-binary-2015.2.zip" dest="conqat/engine/conqat.zip" skipexisting="true" />
								<unzip src="conqat/engine/conqat.zip" dest="conqat/engine" overwrite="false" />
								<chmod file="${basedir}/conqat/engine/conqat-2015.2/bin/conqat.sh" perm="ugo+x" />
								<!-- run conqat -->
								<exec executable="${basedir}/conqat/engine/conqat-2015.2/bin/conqat.sh" osfamily="unix">
									<arg value="-f" />
									<arg value="${basedir}/conqat/${project.artifactId}.architecture.cqr" />
								</exec>
								<exec executable="${basedir}/conqat/engine/conqat-2015.2/bin/conqat.bat" osfamily="windows">
									<arg value="-f" />
									<arg value="${basedir}/conqat/${project.artifactId}.architecture.cqr" />
								</exec>
							</target>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
		
	</profiles>


	<scm>
		<connection>scm:git:https://git@github.com:AludraTest/cloud-manager-parent.git</connection>
		<developerConnection>scm:git:https://git@github.com/AludraTest/cloud-manager-parent.git</developerConnection>
		<url>https://github.com/AludraTest/cloud-manager-parent.git</url>
	  <tag>cloud-manager-parent-1</tag>
  </scm>

	<issueManagement>
		<url>https://github.com/AludraTest/cloud-manager-parent/issues</url>
		<system>GitHub Issues</system>
	</issueManagement>

	<distributionManagement>
		<snapshotRepository>
			<id>ossrh</id>
			<url>https://oss.sonatype.org/content/repositories/snapshots</url>
		</snapshotRepository>
		<repository>
			<id>ossrh</id>
			<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
		</repository>
		<site>
			<!-- this is not used at all, as GitHub site-deploy is used. But site 
				Plugin requires this to be here to work! -->
			<id>local-dummy</id>
			<url>file:/./target/site-deployment</url>
		</site>
	</distributionManagement>
</project>