Skip to content

gitlab-docker-int-test-latest-twelve #3316

gitlab-docker-int-test-latest-twelve

gitlab-docker-int-test-latest-twelve #3316

# Copyright 2021 Goldman Sachs
#
# Licensed 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.
name: gitlab-docker-int-test-latest-twelve
env:
CI_DEPLOY_USERNAME: ${{ secrets.CI_DEPLOY_USERNAME }}
CI_DEPLOY_PASSWORD: ${{ secrets.CI_DEPLOY_PASSWORD }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
on:
schedule:
- cron: '0 20 * * *' # daily at 20:00 UTC
push:
branches:
- master
pull_request:
branches:
- "**"
workflow_dispatch:
inputs:
logLevel:
description: 'Log level'
required: true
default: 'warning'
jobs:
build:
name: Run GitLab Docker Integration Tests
if: (github.repository == 'finos/legend-sdlc')
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Cache Maven dependencies
uses: actions/cache@v4
env:
cache-name: cache-mvn-deps
with:
path: ~/.m2/repository
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 21
java-package: jdk
server-id: ossrh
server-username: CI_DEPLOY_USERNAME
server-password: CI_DEPLOY_PASSWORD
- name: Configure git
run: |
git config --global committer.email "infra@finos.org"
git config --global committer.name "FINOS Admin"
git config --global author.email "${GITHUB_ACTOR}@users.noreply.github.com"
git config --global author.name "${GITHUB_ACTOR}"
- name: Download deps and plugins
run: mvn de.qaware.maven:go-offline-maven-plugin:resolve-dependencies
- name: Configure and start GitLab container
run: docker run --detach
--hostname localhost
--env GITLAB_OMNIBUS_CONFIG="gitlab_rails['initial_root_password'] = 'ac0018BD19066353'"
--publish 8090:80
--name gitlab
gitlab/gitlab-ee:12.10.14-ee.0
- name: Wait until gitlab container is up and running
run: sleep 450
- name: Build + Test
run: mvn verify javadoc:javadoc -Dorg.slf4j.simpleLogger.showDateTime=true -Dorg.slf4j.simpleLogger.dateTimeFormat=HH:mm:ss.SSSZ -P test-gitlab-docker
- name: Shutdown GitLab container
run: docker stop gitlab