Skip to content

Merge pull request #356 from DSD-DBS/increase-open-timeout-fixed #2101

Merge pull request #356 from DSD-DBS/increase-open-timeout-fixed

Merge pull request #356 from DSD-DBS/increase-open-timeout-fixed #2101

# SPDX-FileCopyrightText: Copyright DB InfraGO AG and contributors
# SPDX-License-Identifier: CC0-1.0
name: Build & push images
on:
push:
pull_request:
branches: ['main']
env:
registry: ghcr.io/dsd-dbs/capella-dockerimages/
images: capella/base capella/remote
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install pre-commit
run: |-
python -m pip install 'pre-commit'
- name: Run pre-commit
run: |-
pre-commit run --all-files
deploy-docker-images:
runs-on: ubuntu-latest
needs: [lint]
strategy:
matrix:
capella_version:
- '5.0.0'
- '5.2.0'
- '6.0.0'
- '6.1.0'
- '7.0.0'
dropins:
- name: 'without'
dropins: 'ModelsImporter'
- name: 'selected'
dropins: 'ModelsImporter,CapellaXHTMLDocGen,DiagramStyler,PVMT,Filtering,Requirements,SubsystemTransition'
name:
Capella ${{ matrix.capella_version }} with ${{ matrix.dropins.name }}
dropins
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Login to github container registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set outputs
id: tag
run: |
echo "branch=$(echo $GITHUB_REF_NAME | sed 's/[^a-zA-Z0-9.]/-/g')" >> "$GITHUB_OUTPUT"
echo "sha=$(git rev-parse --short HEAD)" >> "$GITHUB_OUTPUT"
- name: Build
# prettier-ignore
run: >
make ${{ env.images }}
CAPELLA_DOWNLOAD_URL="https://mirror.umd.edu/eclipse/capella/core/products/releases/{}"
CAPELLA_VERSIONS="${{ matrix.capella_version }}"
DOCKER_PREFIX="${{ env.registry }}"
CAPELLA_DOCKERIMAGES_REVISION="${{ steps.tag.outputs.branch }}"
CAPELLA_DROPINS="${{ matrix.dropins.dropins }}"
DOCKER_TAG_SCHEMA=${{ matrix.capella_version }}-${{ matrix.dropins.name }}-dropins-${{ steps.tag.outputs.branch }}
DOCKER_BUILD_FLAGS="--label git-short-sha=${{ steps.tag.outputs.sha }}"
- name: Push
run: |
for image in ${{ env.images }}
do docker push "${{ env.registry }}$image:${{ matrix.capella_version }}-${{ matrix.dropins.name }}-dropins-${{ steps.tag.outputs.branch }}"
done