blob: d5a0438623c513b90b54f1e7ee01cf034c8c55e5 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<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.apache.openmeetings</groupId>
<artifactId>openmeetings-parent</artifactId>
<version>6.0.0</version>
<relativePath>..</relativePath>
</parent>
<artifactId>openmeetings-server</artifactId>
<packaging>jar</packaging>
<name>Openmeetings Server</name>
<description>Module for OpenMeetings server assembly</description>
<properties>
<server.dir>${project.build.directory}/apache-tomcat-${tomcat.version}</server.dir>
<languages.dir>../openmeetings-web/src/main/java/org/apache/openmeetings/web/app</languages.dir>
<assembly.finalName>apache-openmeetings-${project.version}</assembly.finalName>
<assembly.descriptor>server</assembly.descriptor>
<dist.dir>${project.build.directory}/${assembly.finalName}</dist.dir>
<dist.webapps>${dist.dir}/webapps</dist.webapps>
<dist.om.dir>${dist.webapps}/openmeetings</dist.om.dir>
<om.webapp>webapps/openmeetings</om.webapp>
<root.webapp>webapps/ROOT</root.webapp>
<server-file.dir>web-server</server-file.dir>
<autoModuleName>apache.openmeetings.server</autoModuleName>
</properties>
<url>https://openmeetings.apache.org</url>
<scm>
<connection>scm:git:https://github.com/apache/openmeetings.git</connection>
<developerConnection>scm:git:https://github.com/apache/openmeetings.git</developerConnection>
<url>https://github.com/apache/openmeetings/tree/6.0.0</url>
<tag>HEAD</tag>
</scm>
<profiles>
<profile>
<id>quick</id>
<properties>
<assembly.finalName>server</assembly.finalName>
<assembly.descriptor>quick</assembly.descriptor>
<site.skip>true</site.skip>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<executions>
<execution>
<id>quick-clean</id>
<phase>initialize</phase>
<goals>
<goal>clean</goal>
</goals>
<configuration>
<excludeDefaultDirectories>true</excludeDefaultDirectories>
<filesets>
<fileset>
<directory>${dist.om.dir}</directory>
<includes>
<include>css/**</include>
<include>js/**</include>
<include>images/**</include>
<include>WEB-INF/lib/openmeetings*</include>
<include>WEB-INF/classes/META-INF/*</include>
</includes>
</fileset>
<fileset>
<directory>${dist.om.dir}/WEB-INF/lib</directory>
<includes>
<include>openmeetings-*.jar</include>
</includes>
</fileset>
<fileset>
<directory>${dist.om.dir}/WEB-INF/classes</directory>
<includes>
<include>**/*.html</include>
<include>**/*.js</include>
<include>**/*.css</include>
<include>**/*.xml</include>
</includes>
</fileset>
</filesets>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>unpacked</id>
<properties>
<maven.test.skip>true</maven.test.skip>
<assembly.finalName>server</assembly.finalName>
<assembly.descriptor>unpacked</assembly.descriptor>
<src.pack.skip>true</src.pack.skip>
<logback.console><![CDATA[<appender-ref ref="CONSOLE" />]]></logback.console>
</properties>
</profile>
<profile>
<id>prepare-web-server</id>
<activation>
<file>
<missing>web-server/apache-tomcat-9.0.43.tar.gz</missing> <!-- TODO should be in-sync with global property -->
</file>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>wagon-maven-plugin</artifactId>
<executions>
<execution>
<id>download-web-server</id>
<phase>process-resources</phase>
<goals>
<goal>download-single</goal>
</goals>
<configuration>
<url>https://archive.apache.org/dist/tomcat/tomcat-9/v${tomcat.version}/bin</url>
<fromFile>apache-tomcat-${tomcat.version}.tar.gz</fromFile>
<toDir>${server-file.dir}</toDir>
<skip>${server.dwnd.skip}</skip>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>${exec-maven-plugin.version}</version>
<executions>
<execution>
<id>generate-configs-xml-site</id>
<phase>pre-site</phase>
<goals>
<goal>java</goal>
</goals>
</execution>
<execution>
<id>generate-configs-xml-build</id>
<phase>generate-sources</phase>
<goals>
<goal>java</goal>
</goals>
</execution>
</executions>
<configuration>
<workingDirectory>${project.build.directory}</workingDirectory>
<includeProjectDependencies>true</includeProjectDependencies>
<includePluginDependencies>true</includePluginDependencies>
<addOutputToClasspath>true</addOutputToClasspath>
<mainClass>org.apache.openmeetings.backup.BackupExport</mainClass>
<arguments>
<argument>${project.build.directory}/generated-sources/GeneralConfiguration.xml</argument>
</arguments>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>xml-maven-plugin</artifactId>
<executions>
<execution>
<id>generate-doc-site</id>
<phase>pre-site</phase>
<goals>
<goal>transform</goal>
</goals>
</execution>
<execution>
<id>generate-doc-build</id>
<phase>generate-sources</phase>
<goals>
<goal>transform</goal>
</goals>
</execution>
</executions>
<configuration>
<transformationSets>
<transformationSet>
<dir>src/site/stylesheets</dir>
<includes>
<include>errorvalues.xml</include>
</includes>
<stylesheet>src/site/stylesheets/errortable.xsl</stylesheet>
<outputDir>${project.build.directory}/generated-site/xdoc</outputDir>
<parameters>
<parameter>
<name>languagesDir</name>
<value>${project.baseUri}/${languages.dir}</value>
</parameter>
</parameters>
</transformationSet>
<transformationSet>
<dir>${project.build.directory}/generated-sources</dir>
<includes>
<include>GeneralConfiguration.xml</include>
</includes>
<stylesheet>src/site/stylesheets/configs.xsl</stylesheet>
<outputDir>${project.build.directory}/generated-site/xdoc</outputDir>
</transformationSet>
</transformationSets>
<skip>${om.quick.build}</skip>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-css-js-site</id>
<phase>pre-site</phase>
<goals>
<goal>unpack</goal>
</goals>
</execution>
<execution>
<id>unpack-css-js</id>
<phase>generate-sources</phase>
<goals>
<goal>unpack</goal>
</goals>
</execution>
</executions>
<configuration>
<artifactItems>
<artifactItem>
<groupId>io.github.devacfr.maven.skins</groupId>
<artifactId>reflow-default-webdeps</artifactId>
<version>${reflow-maven-skin.version}</version>
<type>jar</type>
<overWrite>false</overWrite>
<includes>**/css/*.css,**/css/themes/${reflow-theme}/*.css,**/css/fontawesome/**,**/js/*.js,**/js/styles/github*.css</includes>
</artifactItem>
</artifactItems>
<outputDirectory>${project.build.directory}/site</outputDirectory>
<skip>${om.quick.build}</skip>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>prepare-site-site</id>
<phase>site</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
<descriptor>${project.basedir}/src/main/assembly/site.xml</descriptor>
</descriptors>
<appendAssemblyId>false</appendAssemblyId>
<finalName>site</finalName>
<skipAssembly>${site.skip}</skipAssembly>
</configuration>
</execution>
<execution>
<id>prepare-site</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
<descriptor>${project.basedir}/src/main/assembly/site.xml</descriptor>
</descriptors>
<appendAssemblyId>false</appendAssemblyId>
<finalName>site</finalName>
<skipAssembly>${site.skip}</skipAssembly>
</configuration>
</execution>
<execution>
<id>make-assembly</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
<descriptor>${project.basedir}/src/main/assembly/${assembly.descriptor}.xml</descriptor>
</descriptors>
<finalName>${assembly.finalName}</finalName>
<appendAssemblyId>false</appendAssemblyId>
<tarLongFileMode>gnu</tarLongFileMode>
</configuration>
</execution>
<execution>
<id>make-src</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
<descriptor>${project.basedir}/src/main/assembly/src.xml</descriptor>
</descriptors>
<finalName>${assembly.finalName}</finalName>
<appendAssemblyId>true</appendAssemblyId>
<tarLongFileMode>gnu</tarLongFileMode>
<skipAssembly>${src.pack.skip}</skipAssembly>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>unpack-web-server</id>
<phase>prepare-package</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<untar src="${server-file.dir}/apache-tomcat-${tomcat.version}.tar.gz" dest="${project.build.directory}"
compression="gzip" overwrite="true"/>
</target>
<skip>${om.quick.build}</skip>
</configuration>
</execution>
<execution>
<id>copy-site-site</id>
<phase>site</phase>
<configuration>
<target>
<copy todir="../target/site" overwrite="true" force="true">
<fileset dir="${project.build.directory}/site"/>
</copy>
</target>
<skip>${site.skip}</skip>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<execution>
<id>copy-site</id>
<phase>package</phase>
<configuration>
<target>
<copy todir="../target/site" overwrite="true" force="true">
<fileset dir="${project.build.directory}/site"/>
</copy>
</target>
<skip>${site.skip}</skip>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.apache.openmeetings</groupId>
<artifactId>openmeetings-web</artifactId>
<version>${project.version}</version>
<type>war</type>
</dependency>
<dependency>
<groupId>org.apache.openmeetings</groupId>
<artifactId>openmeetings-screenshare</artifactId>
</dependency>
<dependency>
<groupId>org.apache.openmeetings</groupId>
<artifactId>openmeetings-install</artifactId>
<scope>runtime</scope>
</dependency>
</dependencies>
</project>