Skip to content

Continuous Integration #2060

Continuous Integration

Continuous Integration #2060

Workflow file for this run

name: 'Continuous Integration'
on:
push:
workflow_dispatch:
schedule:
- cron: '7 0 * * SUN'
env:
GRADLE_OPTS: >-
-Dorg.gradle.project.org.alfresco.maven.nexus.username=${{ secrets.ALFRESCO_NEXUS_USERNAME }}
-Dorg.gradle.project.org.alfresco.maven.nexus.password=${{ secrets.ALFRESCO_NEXUS_PASSWORD }}
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
- name: Set up JDK 17
uses: actions/setup-java@cd89f46ac9d01407894225f350157564c9c7cee2 # v3
with:
distribution: 'temurin'
java-version: '17'
- name: Unit tests
uses: gradle/gradle-build-action@842c587ad8aa4c68eeba24c396e15af4c2e9f30a # v2
with:
cache-read-only: false
arguments: test --parallel --info
- name: Upload analysis to sonarcloud
uses: gradle/gradle-build-action@842c587ad8aa4c68eeba24c396e15af4c2e9f30a # v2
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
GITHUB_TOKEN: ${{ github.token }}
with:
cache-read-only: false
arguments: sonarqube -i
- name: Upload test artifact
if: success() || failure()
uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3
with:
name: test-result
path: /home/runner/work/**/build/reports
retention-days: 2
# integration-test:
# runs-on: ubuntu-latest
# strategy:
# fail-fast: false
# matrix:
# version: [ "community-7.0.0", "community-7.1.1", "community-7.2.0", "community-7.3.0", "community-7.4.0", "community-23.1.0", "community-23.2.0", "enterprise-7.0.1", "enterprise-7.1.0", "enterprise-7.2.0", "enterprise-7.3.0", "enterprise-7.4.0", "enterprise-23.1.0", "enterprise-23.2.0" ]
# steps:
# - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
# - name: Set up JDK 17
# uses: actions/setup-java@cd89f46ac9d01407894225f350157564c9c7cee2 # v3
# with:
# distribution: 'temurin'
# java-version: '17'
# - name: Login to CloudSmith docker registry
# run: echo "${{ secrets.CLOUDSMITH_APIKEY }}" | docker login private.docker.xenit.eu --username "${{ secrets.CLOUDSMITH_USER }}" --password-stdin
# - name: Integration tests
# uses: gradle/gradle-build-action@842c587ad8aa4c68eeba24c396e15af4c2e9f30a # v2
# with:
# cache-read-only: false
# arguments: :2repository:${{ matrix.version }}:integrationTests --info --stacktrace
# - name: Upload test artifact
# if: success() || failure()
# uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3
# with:
# name: integration-test-${{ matrix.version }}-result
# path: /home/runner/work/**/build/reports
# retention-days: 2
# publish-docker-images:
# needs: [ test, integration-test ]
# runs-on: ubuntu-latest
# if: ${{ startsWith(github.ref, 'refs/heads/master') || startsWith(github.ref, 'refs/tags/v') }}
# steps:
# - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
# - name: Set up JDK 17
# uses: actions/setup-java@cd89f46ac9d01407894225f350157564c9c7cee2 # v3
# with:
# distribution: 'temurin'
# java-version: '17'
# - name: Login to CloudSmith docker registry
# run: echo "${{ secrets.CLOUDSMITH_APIKEY }}" | docker login private.docker.xenit.eu --username "${{ secrets.CLOUDSMITH_USER }}" --password-stdin
# # We have to split out publishing to public and private repo's because pushing to docker.io does not seem to work
# # without supplying DOCKER_USER and DOCKER_PASSWORD. However, supplying those environment variables breaks
# # publishing to other repositories
# - name: Publish public docker images
# env:
# DOCKER_USER: ${{ secrets.DOCKER_USER }}
# DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
# uses: gradle/gradle-build-action@842c587ad8aa4c68eeba24c396e15af4c2e9f30a # v2
# with:
# cache-read-only: false
# arguments: pushDockerImage -PincludeEnterprise=false
# - name: Publish private docker images
# uses: gradle/gradle-build-action@842c587ad8aa4c68eeba24c396e15af4c2e9f30a # v2
# with:
# cache-read-only: false
# arguments: :2repository:pushDockerImage -PincludeCommunity=false
publish-maven-images:
needs: [ test, integration-test ]

Check failure on line 98 in .github/workflows/ci.yml

View workflow run for this annotation

GitHub Actions / Continuous Integration

Invalid workflow file

The workflow is not valid. .github/workflows/ci.yml (Line: 98, Col: 20): Job 'publish-maven-images' depends on unknown job 'integration-test'.
runs-on: ubuntu-latest
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
- name: Set up JDK 17
uses: actions/setup-java@cd89f46ac9d01407894225f350157564c9c7cee2 # v3
with:
distribution: 'temurin'
java-version: '17'
- name: Publish tomcat base jars
env:
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.MAVEN_CENTRAL_GPG_KEY }}
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.MAVEN_CENTRAL_GPG_PASSWORD }}
ORG_GRADLE_PROJECT_sonatype_username: ${{ secrets.SONATYPE_S01_USERNAME }}
ORG_GRADLE_PROJECT_sonatype_password: ${{ secrets.SONATYPE_S01_PASSWORD }}
uses: gradle/gradle-build-action@842c587ad8aa4c68eeba24c396e15af4c2e9f30a # v2
with:
cache-read-only: false
arguments: :tomcat-base:tomcat-embedded-9:publish :tomcat-base:tomcat-embedded-10:publish --info -PsigningKeyId=CDE3528F