Revert "revert deployment changes (#228)" (#229)

This reverts commit 7773db3394.
This commit is contained in:
Ralph O'Flinn 2021-03-24 01:41:41 -05:00 committed by GitHub
parent 7773db3394
commit 1dd2851e45
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 168 additions and 359 deletions

View file

@ -1,21 +0,0 @@
<settings xmlns="http://maven.apache.org/SETTINGS/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd">
<profiles>
<profile>
<id>defaults</id>
<properties>
<app-name>vivo</app-name>
<vivo-dir>/usr/local/vivo/home</vivo-dir>
<tomcat-dir>/usr/local/tomcat</tomcat-dir>
<default-theme>wilma</default-theme>
</properties>
</profile>
</profiles>
<activeProfiles>
<activeProfile>defaults</activeProfile>
</activeProfiles>
</settings>

View file

@ -23,108 +23,24 @@
<default-theme>wilma</default-theme>
</properties>
<profiles>
<profile>
<id>package</id>
<activation>
<property><name>vivo-dir</name></property>
</activation>
<build>
<finalName>${app-name}</finalName>
<plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<configuration>
<descriptors>
<descriptor>src/main/assembly/home.xml</descriptor>
</descriptors>
<appendAssemblyId>false</appendAssemblyId>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>install</id>
<activation>
<property><name>vivo-dir</name></property>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<configuration>
<descriptors>
<descriptor>src/main/assembly/home.xml</descriptor>
</descriptors>
<appendAssemblyId>false</appendAssemblyId>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>remove-webapp</id>
<phase>verify</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<delete dir="${vivo-dir}/rdf" />
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>install</id>
<phase>install</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>${vivo-dir}</outputDirectory>
<resources>
<resource>
<directory>${project.build.directory}/${project.build.finalName}</directory>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<build>
<plugins>
<plugin>
<artifactId>maven-install-plugin</artifactId>
<artifactId>maven-assembly-plugin</artifactId>
<configuration>
<skip>true</skip>
<descriptors>
<descriptor>src/main/assembly/home.xml</descriptor>
</descriptors>
<appendAssemblyId>false</appendAssemblyId>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>

View file

@ -4,6 +4,7 @@
<id>home</id>
<formats>
<format>dir</format>
<format>tar</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<dependencySets>

View file

@ -29,12 +29,6 @@
<encoding>UTF-8</encoding>
</configuration>
</plugin>
<plugin>
<artifactId>maven-install-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
@ -148,12 +142,6 @@
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<version>2.6</version>
@ -177,60 +165,6 @@
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<executions>
<execution>
<id>default-war</id>
<phase/>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>install</id>
<activation>
<property><name>vivo-dir</name></property>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-enforcer-plugin</artifactId>
<executions>
<execution>
<id>enforce-properties</id>
<phase>validate</phase>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<requireProperty>
<property>app-name</property>
<message>You must provide an application name (app-name)</message>
</requireProperty>
</rules>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>skip</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<version>2.8.2</version>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>
</profile>

View file

@ -19,117 +19,9 @@
<name>VIVO Install Web App</name>
<profiles>
<profile>
<id>package</id>
<activation>
<property><name>app-name</name></property>
</activation>
<build>
<finalName>${app-name}</finalName>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
</manifest>
</archive>
<archiveClasses>false</archiveClasses>
<overlays>
<overlay>
<groupId>org.vivoweb</groupId>
<artifactId>vivo-webapp</artifactId>
<type>war</type>
</overlay>
<!-- Overlays for multilingual support -->
<!-- overlay>
<groupId>org.vivoweb</groupId>
<artifactId>vitro-languages-webapp</artifactId>
<type>war</type>
</overlay>
<overlay>
<groupId>org.vivoweb</groupId>
<artifactId>vivo-languages-webapp</artifactId>
<type>war</type>
</overlay -->
</overlays>
<webResources>
<resource>
<directory>src/main/webResources</directory>
<filtering>true</filtering>
</resource>
</webResources>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>install</id>
<activation>
<property><name>tomcat-dir</name></property>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>remove-webapp</id>
<phase>verify</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<delete dir="${tomcat-dir}/webapps/${project.build.finalName}" />
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>install</id>
<phase>install</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>${project.groupId}</groupId>
<artifactId>${project.artifactId}</artifactId>
<version>${project.version}</version>
<type>war</type>
<overWrite>true</overWrite>
<outputDirectory>${tomcat-dir}/webapps/${project.build.finalName}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<build>
<finalName>${app-name}</finalName>
<plugins>
<plugin>
<artifactId>maven-install-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<configuration>
@ -140,6 +32,75 @@
</filesets>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<configuration>
<skip>false</skip>
</configuration>
<executions>
<execution>
<id>include-home</id>
<phase>process-resources</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>org.vivoweb</groupId>
<artifactId>vivo-installer-home</artifactId>
<version>${project.version}</version>
<type>tar</type>
<destFileName>vivo-home.tar</destFileName>
<outputDirectory>${project.build.directory}/home-files</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
</manifest>
</archive>
<archiveClasses>false</archiveClasses>
<overlays>
<overlay>
<groupId>org.vivoweb</groupId>
<artifactId>vivo-webapp</artifactId>
<type>war</type>
</overlay>
<!-- Overlays for multilingual support -->
<overlay>
<groupId>org.vivoweb</groupId>
<artifactId>vitro-languages-webapp-core</artifactId>
<type>war</type>
</overlay>
<overlay>
<groupId>org.vivoweb</groupId>
<artifactId>vivo-languages-webapp-core</artifactId>
<type>war</type>
</overlay>
</overlays>
<webResources>
<resource>
<directory>src/main/webResources</directory>
<filtering>true</filtering>
</resource>
<resource>
<directory>${project.build.directory}/home-files/</directory>
<targetPath>WEB-INF/resources/home-files/</targetPath>
</resource>
</webResources>
</configuration>
</plugin>
</plugins>
</build>

View file

@ -1,9 +1,52 @@
<Context> <!-- useHttpOnly="false" -->
<!--
# The 'home' property specifies the location of VIVO HOME.
# The system user used to run the VIVO web application must have write access
# to the parent directory of the directory defined in this property, if VIVO HOME
# does not already exist.
# If this directory already exists, the system user used to run the VIVO web application
# must have write access to this directory.
-->
<Environment
type="java.lang.String"
name="vitro/home"
value="${vivo-dir}" override="true"/>
<!--
# The name of the application (possibly not used).
-->
<Environment
type="java.lang.String"
name="vitro/appName"
value="${app-name}" override="true"/>
<!--
# The email address of the root user for the VIVO application. The password
# for this user is initially set to "rootPassword", but you will be asked to
# change the password the first time you log in.
-->
<Environment
type="java.lang.String"
name="vitro/rootUserAddress"
value="vivo_root@mydomain.edu" override="true"/>
<!--
# This namespace will be used when generating URIs for objects created in the
# editor. In order to serve linked data, the default namespace must be composed
# as follows (optional elements in parentheses):
#
# scheme + server_name (+ port) (+ servlet_context) + "/individual/"
#
# For example, Cornell's default namespace is:
#
# http://vivo.cornell.edu/individual/
-->
<Environment
type="java.lang.String"
name="vitro/defaultNamespace"
value="http://vivo.mydomain.edu/individual/" override="true"/>
<!-- Disable persist sessions on shut down.-->
<Manager pathname="" />
</Context>

View file

@ -24,7 +24,7 @@
# debug.log4j.properties exists will be used instead, if it exists, but is not stored in Subversion.
log4j.appender.AllAppender=org.apache.log4j.RollingFileAppender
log4j.appender.AllAppender.File=${catalina.base}/logs/${app-name}.all.log
log4j.appender.AllAppender.File= ${catalina.base}/logs/vivo.all.log
log4j.appender.AllAppender.MaxFileSize=10MB
log4j.appender.AllAppender.MaxBackupIndex=10
log4j.appender.AllAppender.layout=org.apache.log4j.PatternLayout