Merge branch 'feature/REPO-5111_repo_build'

# Conflicts:
#	.travis.yml
#	distribution/pom.xml
#	docker-alfresco/pom.xml
#	pom.xml
#	public-javadoc/pom.xml
#	tests/environment/.env
#	tests/pom.xml
#	tests/tas-cmis/pom.xml
#	tests/tas-email/pom.xml
#	tests/tas-integration/pom.xml
#	tests/tas-restapi/pom.xml
#	tests/tas-webdav/pom.xml
This commit is contained in:
Alan Davis
2020-10-21 19:27:15 +01:00
13 changed files with 38 additions and 170 deletions

View File

@@ -1,5 +1,6 @@
--- ---
dist: xenial dist: xenial
sudo: required
language: java language: java
jdk: openjdk11 jdk: openjdk11
@@ -20,17 +21,17 @@ before_cache: bash scripts/travis/cleanup_cache.sh
branches: branches:
only: only:
- master - master
- develop
- /release\/.*/ - /release\/.*/
- feature/REPO-5111_repo_build - /feature\/.*/
- /fix\/.*/
env: env:
global: global:
- TAS_SCRIPTS=../alfresco-community-repo/packaging/tests/scripts - TAS_SCRIPTS=../alfresco-community-repo/packaging/tests/scripts
- TAS_ENVIRONMENT=./tests/environment - TAS_ENVIRONMENT=./tests/environment
# Must be in the format <alfresco-version>-<additional_versioning> ie. 6.3.0-repo-xxxx-x or 6.3.0-Ax # Release version has to start with real version (7.0.0-....) for the docker image to build successfully.
- RELEASE_VERSION=7.0.0-TEST4 - RELEASE_VERSION=7.0.0-A9
- DEVELOPMENT_VERSION=7.0.0-TEST5-SNAPSHOT - DEVELOPMENT_VERSION=7.0.0-SNAPSHOT
stages: stages:
- name: test - name: test
@@ -38,26 +39,15 @@ stages:
- name: docker_latest - name: docker_latest
if: fork = false AND type != pull_request AND branch = master if: fork = false AND type != pull_request AND branch = master
- name: release - name: release
if: commit_message ~= /\[release\]/ AND fork = false AND type != pull_request AND (branch =~ ^(master|develop)$ OR branch =~ /release\/.*/) if: commit_message =~ /\[release\]/ AND fork = false AND type != pull_request AND (branch = master OR branch =~ /release\/.*/)
- name: publish - name: publish
if: commit_message ~= /\[publish\]/ AND fork = false AND type != pull_request AND (branch =~ ^(master|develop)$ OR branch =~ /release\/.*/) if: commit_message =~ /\[publish\]/ AND fork = false AND type != pull_request AND (branch = master OR branch =~ /release\/.*/)
before_install: travis_retry bash scripts/travis/init.sh before_install: travis_retry bash scripts/travis/init.sh
install: travis_retry travis_wait 40 bash scripts/travis/build.sh install: travis_retry travis_wait 40 bash scripts/travis/build.sh
jobs: jobs:
include: include:
- name: "WhiteSource scan"
stage: test
# only on master or develop and if it is not a PR
if: fork = false AND branch =~ ^(master|develop)$ AND type != pull_request
install: travis_retry travis_wait 30 mvn -B -q install -f war/pom.xml
script:
# Download the latest version of WhiteSource Unified Agent
- curl -LJO https://github.com/whitesource/unified-agent-distribution/releases/latest/download/wss-unified-agent.jar
# Run WhiteSource Unified Agent
- java -jar wss-unified-agent.jar -apiKey ${WHITESOURCE_API_KEY} -c .wss-unified-agent.config -d ./war
- name: "REST API TAS tests part1" - name: "REST API TAS tests part1"
before_script: before_script:
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml
@@ -111,10 +101,10 @@ jobs:
stage: docker_latest stage: docker_latest
script: travis_retry travis_wait 30 mvn -B -V clean install -DskipTests -Dmaven.javadoc.skip=true -Pinternal script: travis_retry travis_wait 30 mvn -B -V clean install -DskipTests -Dmaven.javadoc.skip=true -Pinternal
- name: "Release and Copy to S3 Staging" - name: "Release and Copy to S3 Staging Bucket"
stage: release stage: release
before_script: bash scripts/travis/verify_release_tag.sh before_script: bash scripts/travis/verify_release_tag.sh
script: travis_wait 40 bash scripts/travis/maven_release.sh script: travis_wait 60 bash scripts/travis/maven_release.sh
before_deploy: before_deploy:
# Move the final artifacts to a single folder (deploy_dir) to be copied to S3 # Move the final artifacts to a single folder (deploy_dir) to be copied to S3
- mkdir -p deploy_dir - mkdir -p deploy_dir
@@ -132,8 +122,10 @@ jobs:
upload_dir: "alfresco-content-services-community/release/${TRAVIS_BRANCH}/${TRAVIS_BUILD_NUMBER}" upload_dir: "alfresco-content-services-community/release/${TRAVIS_BRANCH}/${TRAVIS_BUILD_NUMBER}"
on: on:
all_branches: true all_branches: true
after_deploy:
- echo "Finished release and deployed to https://s3.console.aws.amazon.com/s3/buckets/alfresco-artefacts-staging/alfresco-content-services/release/${TRAVIS_BRANCH}/${TRAVIS_BUILD_NUMBER}"
- name: "Copy to S3 Release" - name: "Copy to S3 Release Bucket"
stage: publish stage: publish
# Nothing to build/install as we are just copying from S3 buckets # Nothing to build/install as we are just copying from S3 buckets
install: skip install: skip

View File

@@ -7,7 +7,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>acs-community-packaging</artifactId> <artifactId>acs-community-packaging</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<dependencies> <dependencies>
@@ -117,6 +117,7 @@
<executions> <executions>
<execution> <execution>
<id>default-resources</id> <id>default-resources</id>
<!-- runs in process-resources phase. -->
<configuration> <configuration>
<overwrite>true</overwrite> <overwrite>true</overwrite>
</configuration> </configuration>
@@ -124,7 +125,7 @@
</executions> </executions>
</plugin> </plugin>
<!-- Copy the enterprise's deployment resources in the validate phase, before default-resources <!-- Copy the enterprise's deployment resources in the generate-resources phase, before default-resources
copies this project's resources in the process-resources phase. --> copies this project's resources in the process-resources phase. -->
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
@@ -132,7 +133,7 @@
<executions> <executions>
<execution> <execution>
<id>unpack-licenses-and-keystore</id> <id>unpack-licenses-and-keystore</id>
<phase>validate</phase> <phase>generate-resources</phase>
<goals> <goals>
<goal>unpack</goal> <goal>unpack</goal>
</goals> </goals>
@@ -184,9 +185,11 @@
</execution> </execution>
<!-- Copy ROOT.war --> <!-- Copy ROOT.war -->
<!-- This plugin <execution> must be before the "make-assembly" as it is in the same phase -->
<execution> <execution>
<id>copy-resources-war</id> <id>copy-resources-war</id>
<phase>generate-resources</phase> <!-- We want the wars in the zip but not the package's jar. -->
<phase>package</phase>
<goals> <goals>
<goal>copy</goal> <goal>copy</goal>
</goals> </goals>

View File

@@ -2,6 +2,7 @@
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd"> xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>distribution</id> <id>distribution</id>
<includeBaseDirectory>false</includeBaseDirectory>
<formats> <formats>
<format>zip</format> <format>zip</format>

View File

@@ -7,86 +7,15 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>acs-community-packaging</artifactId> <artifactId>acs-community-packaging</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<properties> <properties>
<image.name>alfresco/alfresco-content-repository-community</image.name> <image.name>alfresco/alfresco-content-repository-community</image.name>
</properties> </properties>
<!-- <dependencies>-->
<!-- <dependency>-->
<!-- <groupId>org.alfresco</groupId>-->
<!-- <artifactId>alfresco-mmt</artifactId>-->
<!-- </dependency>-->
<!-- <dependency>-->
<!-- <groupId>org.alfresco</groupId>-->
<!-- <artifactId>alfresco-server-root</artifactId>-->
<!-- <type>war</type>-->
<!-- </dependency>-->
<!-- <dependency>-->
<!-- <groupId>org.postgresql</groupId>-->
<!-- <artifactId>postgresql</artifactId>-->
<!-- </dependency>-->
<!-- <dependency>-->
<!-- <groupId>org.alfresco.aos-module</groupId>-->
<!-- <artifactId>alfresco-aos-module</artifactId>-->
<!-- <type>amp</type>-->
<!-- <exclusions>-->
<!-- <exclusion>-->
<!-- <groupId>org.alfresco.aos-module</groupId>-->
<!-- <artifactId>alfresco-aos-repo-binding</artifactId>-->
<!-- </exclusion>-->
<!-- </exclusions>-->
<!-- </dependency>-->
<!-- <dependency>-->
<!-- <groupId>org.alfresco.aos-module</groupId>-->
<!-- <artifactId>alfresco-vti-bin</artifactId>-->
<!-- <type>war</type>-->
<!-- </dependency>-->
<!-- <dependency>-->
<!-- <groupId>org.alfresco.integrations</groupId>-->
<!-- <artifactId>alfresco-googledrive-repo-community</artifactId>-->
<!-- <type>amp</type>-->
<!-- </dependency>-->
<!-- <dependency>-->
<!-- <groupId>org.alfresco</groupId>-->
<!-- <artifactId>api-explorer</artifactId>-->
<!-- <version>${alfresco.api-explorer.version}</version>-->
<!-- <type>war</type>-->
<!-- </dependency>-->
<!-- <dependency>-->
<!-- <groupId>org.alfresco</groupId>-->
<!-- <artifactId>alfresco-share-services</artifactId>-->
<!-- <type>amp</type>-->
<!-- </dependency>-->
<!-- </dependencies>-->
<build> <build>
<plugins> <plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>copy-licenses</id>
<phase>process-resources</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<resources>
<resource>
<!-- Extract licenses directory -->
<directory>../distribution/src/main/resources/licenses</directory>
<filtering>false</filtering>
</resource>
</resources>
<outputDirectory>${project.build.directory}/licenses</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId> <artifactId>maven-dependency-plugin</artifactId>
@@ -99,13 +28,6 @@
</goals> </goals>
<configuration> <configuration>
<artifactItems> <artifactItems>
<!-- <artifactItem>-->
<!-- <groupId>org.alfresco</groupId>-->
<!-- <artifactId>content-services-community</artifactId>-->
<!-- <type>war</type>-->
<!-- <overWrite>false</overWrite>-->
<!-- <outputDirectory>${project.build.directory}/war/alfresco</outputDirectory>-->
<!-- </artifactItem>-->
<artifactItem> <artifactItem>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>api-explorer</artifactId> <artifactId>api-explorer</artifactId>
@@ -113,50 +35,9 @@
<type>war</type> <type>war</type>
<outputDirectory>${project.build.directory}/war/api-explorer</outputDirectory> <outputDirectory>${project.build.directory}/war/api-explorer</outputDirectory>
</artifactItem> </artifactItem>
<!-- <artifactItem>-->
<!-- <groupId>org.alfresco</groupId>-->
<!-- <artifactId>alfresco-server-root</artifactId>-->
<!-- <version>${dependency.alfresco-server-root.version}</version>-->
<!-- <type>war</type>-->
<!-- <outputDirectory>${project.build.directory}/war/ROOT</outputDirectory>-->
<!-- </artifactItem>-->
<!-- <artifactItem>-->
<!-- <groupId>org.alfresco.aos-module</groupId>-->
<!-- <artifactId>alfresco-vti-bin</artifactId>-->
<!-- <type>war</type>-->
<!-- <outputDirectory>${project.build.directory}/war/_vti_bin</outputDirectory>-->
<!-- </artifactItem>-->
</artifactItems> </artifactItems>
</configuration> </configuration>
</execution> </execution>
<!-- <execution>-->
<!-- <id>copy-jdbc-connectors</id>-->
<!-- <phase>process-resources</phase>-->
<!-- <goals>-->
<!-- <goal>copy</goal>-->
<!-- </goals>-->
<!-- <configuration>-->
<!-- <artifactItems>-->
<!-- <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>-->
<!-- <artifactItem>-->
<!-- <groupId>org.alfresco</groupId>-->
<!-- <artifactId>alfresco-mmt</artifactId>-->
<!-- <version>${dependency.alfresco-mmt.version}</version>-->
<!-- <type>jar</type>-->
<!-- <overWrite>false</overWrite>-->
<!-- <outputDirectory>${project.build.directory}/alfresco-mmt</outputDirectory>-->
<!-- </artifactItem>-->
<!-- </artifactItems>-->
<!-- </configuration>-->
<!-- </execution>-->
<execution> <execution>
<id>copy-amps</id> <id>copy-amps</id>
<phase>process-resources</phase> <phase>process-resources</phase>
@@ -252,16 +133,6 @@
</buildOptions> </buildOptions>
</build> </build>
</image> </image>
<!-- DockerHub image -->
<image>
<name>${image.name}:${image.tag}</name>
<build>
<dockerFileDir>${project.basedir}/</dockerFileDir>
<buildOptions>
<squash>true</squash>
</buildOptions>
</build>
</image>
</images> </images>
</configuration> </configuration>
<executions> <executions>

13
pom.xml
View File

@@ -2,14 +2,14 @@
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>acs-community-packaging</artifactId> <artifactId>acs-community-packaging</artifactId>
<name>Alfresco Content Services Community Packaging</name> <name>Alfresco Content Services Community Packaging</name>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
<packaging>pom</packaging> <packaging>pom</packaging>
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo</artifactId> <artifactId>alfresco-community-repo</artifactId>
<relativePath>../alfresco-community-repo/pom.xml</relativePath> <relativePath>../alfresco-community-repo/pom.xml</relativePath>
<version>8.300-TEST6</version> <version>8.304</version>
</parent> </parent>
<scm> <scm>
@@ -31,13 +31,14 @@
</distributionManagement> </distributionManagement>
<properties> <properties>
<dependency.alfresco-community-repo.version>8.300-TEST6</dependency.alfresco-community-repo.version> <dependency.alfresco-community-repo.version>8.304</dependency.alfresco-community-repo.version>
<repo.image.tag>${dependency.alfresco-community-repo.version}</repo.image.tag> <repo.image.tag>${dependency.alfresco-community-repo.version}</repo.image.tag>
<share.image.tag>${alfresco.share.version}</share.image.tag>
<alfresco.share.version>7.0.0-A1</alfresco.share.version> <alfresco.share.version>7.0.0-A4</alfresco.share.version>
<alfresco.alfresco-share-services.version>7.0.0-A1</alfresco.alfresco-share-services.version> <alfresco.alfresco-share-services.version>7.0.0-A4</alfresco.alfresco-share-services.version>
<alfresco.api-explorer.version>7.0.0-A1</alfresco.api-explorer.version> <alfresco.api-explorer.version>7.0.0-M1</alfresco.api-explorer.version>
</properties> </properties>
<profiles> <profiles>

View File

@@ -5,7 +5,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>acs-community-packaging</artifactId> <artifactId>acs-community-packaging</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<packaging>pom</packaging> <packaging>pom</packaging>

View File

@@ -1,4 +1,4 @@
TRANSFORMERS_TAG=2.3.4 TRANSFORMERS_TAG=2.3.5
SOLR6_TAG=1.4.2 SOLR6_TAG=2.0.0
POSTGRES_TAG=11.7 POSTGRES_TAG=11.7
ACTIVEMQ_TAG=5.15.8 ACTIVEMQ_TAG=5.15.8

View File

@@ -6,7 +6,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>acs-community-packaging</artifactId> <artifactId>acs-community-packaging</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<modules> <modules>

View File

@@ -9,7 +9,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>content-repository-community-tests</artifactId> <artifactId>content-repository-community-tests</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>

View File

@@ -9,7 +9,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>content-repository-community-tests</artifactId> <artifactId>content-repository-community-tests</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>

View File

@@ -9,7 +9,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>content-repository-community-tests</artifactId> <artifactId>content-repository-community-tests</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>

View File

@@ -9,7 +9,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>content-repository-community-tests</artifactId> <artifactId>content-repository-community-tests</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>

View File

@@ -9,7 +9,7 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>content-repository-community-tests</artifactId> <artifactId>content-repository-community-tests</artifactId>
<version>7.0.0-TEST5-SNAPSHOT</version> <version>7.0.0-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>