Skip to content

Commit

Permalink
REPO-2907 Add config for Docker images
Browse files Browse the repository at this point in the history
  • Loading branch information
killerboot authored Sep 18, 2017
1 parent e2fea4b commit b654b51
Show file tree
Hide file tree
Showing 3 changed files with 93 additions and 0 deletions.
11 changes: 11 additions & 0 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
FROM tomcat:8.5.20-jre8

RUN mkdir -p /usr/local/tomcat/shared/classes

RUN touch /usr/local/tomcat/shared/classes/alfresco-global.properties

COPY target/war/alfresco.war /usr/local/tomcat/webapps/alfresco.war
COPY target/connector/* /usr/local/tomcat/lib/

RUN sed -i "s/shared.loader=/shared.loader=\${catalina.base}\/shared\/classes/" /usr/local/tomcat/conf/catalina.properties

81 changes: 81 additions & 0 deletions docker/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
<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>
<artifactId>content-services-community-docker</artifactId>
<name>Alfresco Content Services Community Docker image builder</name>
<packaging>pom</packaging>

<parent>
<groupId>org.alfresco</groupId>
<artifactId>acs-community-packaging</artifactId>
<version>6.0.b-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

<dependencies>
<dependency>
<groupId>org.alfresco</groupId>
<artifactId>content-services-community</artifactId>
<version>${project.version}</version>
<type>war</type>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>${dependency.mysql.version}</version>
</dependency>
<dependency>
<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>${dependency.postgresql.version}</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.0.2</version>
<executions>
<execution>
<id>copy-resources</id>
<phase>process-resources</phase>
<goals>
<goal>copy</goal>
</goals>
</execution>
</executions>
<configuration>
<artifactItems>
<artifactItem>
<groupId>org.alfresco</groupId>
<artifactId>content-services-community</artifactId>
<version>${project.version}</version>
<type>war</type>
<overWrite>false</overWrite>
<outputDirectory>${project.build.directory}/war</outputDirectory>
<destFileName>alfresco.war</destFileName>
</artifactItem>
<artifactItem>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<type>jar</type>
<overWrite>false</overWrite>
<outputDirectory>${project.build.directory}/connector</outputDirectory>
</artifactItem>
<artifactItem>
<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>${dependency.postgresql.version}</version>
<type>jar</type>
<overWrite>false</overWrite>
<outputDirectory>${project.build.directory}/connector</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</plugin>
</plugins>

</build>

</project>
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
<modules>
<module>war</module>
<module>zip</module>
<module>docker</module>
</modules>

<scm>
Expand Down

0 comments on commit b654b51

Please sign in to comment.