Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Übernahme sprint -> main #34

Merged
merged 121 commits into from
Apr 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
121 commits
Select commit Hold shift + click to select a range
e22d10b
Folgendes hinzufügen/ergänzen/ändern (MDAS-454) :
Onlinee Jan 17, 2024
44b7ab9
minioclient
sfi2022 Jan 22, 2024
6c2bff7
S3 Client Anbindung.
sfi2022 Jan 23, 2024
0cd73c7
Add filesInFolder REST resource service
sfi2022 Jan 25, 2024
5760dd2
Add max items per bucket limit
sfi2022 Jan 31, 2024
ac5bb8a
Error handling invalid bucket name
sfi2022 Jan 31, 2024
1af9f3c
Openapi operationId added. S3 path/prefix
sfi2022 Jan 31, 2024
f592089
MDAS-456 Refactoring Exception Handling
sfi2022 Feb 1, 2024
f6bc3e5
:recycle: MDAS-456 S3Test S3FileLimitTest
sfi2022 Feb 6, 2024
f8fb6ab
:recycle: MDAS-456 maven profile generate-openapi added
sfi2022 Feb 6, 2024
ec6fce9
:recycle: MDAS-456 Constants introduced. Exceptions refactored.. S3Pr…
sfi2022 Feb 6, 2024
8077dc4
:recycle: MDAS-45 Config files refactoring
sfi2022 Feb 8, 2024
43fdc4e
:recycle: MDAS-45 Constants refactored. ExceptionRouteBuilder moved
sfi2022 Feb 8, 2024
34fb89e
:recycle: MDAS-456 operationID changed
sfi2022 Feb 8, 2024
f145eff
:recycle: MDAS-456 Resource file moved
sfi2022 Feb 8, 2024
6f61602
:recycle: MDAS-456 Tests renamed
sfi2022 Feb 8, 2024
ffba5f4
:recycle: MDAS-456 Changes review https://github.com/it-at-m/mobidam-…
sfi2022 Feb 13, 2024
cd3f8fc
:bug: MDAS-456 Error in build.yaml fixed
sfi2022 Feb 13, 2024
79b7f61
:bug: MDAS-456 Error in build.yaml fixed
sfi2022 Feb 13, 2024
63fdd9a
Merge branch 'mdas-456' of https://github.com/it-at-m/mobidam-s3-eai …
sfi2022 Feb 13, 2024
b71ac81
:bug: MDAS-456 Error in build.yaml parent pom removed
sfi2022 Feb 14, 2024
8b79fc1
:bug: MDAS-456 pom.xml project encoding added. surefire plugin upgrade
sfi2022 Feb 14, 2024
f710b9a
:bug: MDAS-456 mvn spotless:apply
sfi2022 Feb 14, 2024
823995c
:art: MDAS-456 Checkstyle
sfi2022 Feb 14, 2024
f414de0
:art: MDAS-456 Checkstyle
sfi2022 Feb 14, 2024
b920759
:art: MDAS-456 Checkstyle + spotless
sfi2022 Feb 14, 2024
33c457a
error handling suggestion
martind260 Feb 16, 2024
5a2ed86
:recycle: MDAS-456 application-limit.yml refactored
sfi2022 Feb 19, 2024
f1df587
:recycle: MDAS-456 Return limited list with warn.
sfi2022 Feb 19, 2024
a280812
:recycle: MDAS-456 Logging removed.
sfi2022 Feb 19, 2024
a9c10e8
first working draft
martind260 Feb 20, 2024
18088d1
error handling improved
martind260 Feb 20, 2024
3cbbd3d
spotless
martind260 Feb 20, 2024
97594d9
docu
martind260 Feb 20, 2024
3a60ede
S3Client removed from tests
martind260 Feb 20, 2024
b196cb4
Unittests added
martind260 Feb 20, 2024
65aed9f
rel-notes added
martind260 Feb 20, 2024
cba5e06
:recycle: MDAS-456 Exception handling. JSON output. OK output with Ht…
sfi2022 Feb 21, 2024
5c4b9f7
:recycle: MDAS-456 Exception handling. JSON output. OK output with Ht…
sfi2022 Feb 21, 2024
332bea3
Merge branch 'mdas-456' of https://github.com/it-at-m/mobidam-s3-eai …
sfi2022 Feb 21, 2024
f3fd39f
s3 config removed
martind260 Feb 22, 2024
8136bca
gitignore app-local
martind260 Feb 22, 2024
a9fec2c
mdas-458 read prop instead of env-var
martind260 Feb 22, 2024
2725825
mdas-458 s3 properties restructured
martind260 Feb 22, 2024
3b7766d
mdas-456 adjustments from pair programming
martind260 Feb 23, 2024
b5a16e4
mdas-458 adjustments from pair programming in 456
martind260 Feb 23, 2024
24b7c18
Update dependency de.muenchen.oss:itm-java-codeformat to v1.0.9
renovate[bot] Feb 23, 2024
6521702
Update dependency org.jacoco:jacoco-maven-plugin to v0.8.11
renovate[bot] Feb 23, 2024
d4a8464
:recycle: MDAS-456 Adapted to changes
sfi2022 Feb 23, 2024
d615dec
:art: MDAS-456 Checkstyle
sfi2022 Feb 23, 2024
0006863
:white_check_mark: MDAS-456 S3Api test added
sfi2022 Feb 23, 2024
0bcbff7
Update dependency com.diffplug.spotless:spotless-maven-plugin to v2.43.0
renovate[bot] Feb 24, 2024
7b77b72
Update dependency org.apache.maven.plugins:maven-scm-plugin to v1.13.0
renovate[bot] Feb 26, 2024
e59a389
Merge pull request #7 from it-at-m/renovate/itm-java-codeformat.version
martind260 Feb 26, 2024
b1f5d9a
Merge pull request #10 from it-at-m/renovate/maven-spotless-plugin.ve…
martind260 Feb 26, 2024
4e592e5
Merge pull request #14 from it-at-m/renovate/maven-scm-plugin.version
martind260 Feb 26, 2024
fd8cab1
Update dependency org.apache.maven.plugins:maven-checkstyle-plugin to…
renovate[bot] Feb 26, 2024
2f9f834
Merge pull request #12 from it-at-m/renovate/maven-checkstyle-plugin.…
martind260 Feb 26, 2024
e117755
Merge pull request #8 from it-at-m/renovate/jacoco.version
martind260 Feb 26, 2024
8751469
:memo: MDAS-456 Openapi documentation added.
sfi2022 Feb 26, 2024
c5ccf99
:memo: MDAS-456 Openapi documentation in german.
sfi2022 Feb 26, 2024
28f081d
:recycle: MDAS-456 Constant replaced with property.
sfi2022 Feb 26, 2024
94d53ba
Merge pull request #17 from it-at-m/mdas-456
sfi2022 Feb 26, 2024
25da2a9
Merge branch 'sprint' into MDAS-458_S3-EAI-Buckets-und-Credentials
martind260 Feb 26, 2024
cc7ffeb
tests fixed after merge
martind260 Feb 26, 2024
bf3454e
soap-request added
martind260 Feb 27, 2024
302e63f
error handling optimized
martind260 Feb 27, 2024
dab1d6f
spotless version downgrade
martind260 Feb 27, 2024
062c2f7
checkstyle
martind260 Feb 27, 2024
b16d044
docu
martind260 Feb 28, 2024
b26470a
:recycle: MDAS-457 REST Ressource, S3Connection, TestCases and Error …
sfi2022 Feb 28, 2024
108441c
:art: MDAS-457 Checkstyle and spotless corrections
sfi2022 Feb 28, 2024
0ee97fb
Merge pull request #25 from it-at-m/docu
martind260 Feb 29, 2024
4069486
:memo: MDAS-457 Merge docu
sfi2022 Feb 29, 2024
ac98a15
Merge pull request #24 from it-at-m/MDAS-458_S3-EAI-Buckets-und-Crede…
martind260 Feb 29, 2024
9a9a8bd
checklist-check added
martind260 Feb 29, 2024
c8daa16
require-checklist moved
martind260 Feb 29, 2024
813aa56
:recycle: MDAS-457 Merge MDAS-458_S3-EAI-Buckets-und-Credentials
sfi2022 Mar 5, 2024
eb8b472
:art: MDAS-457 Format spottless + checkstyle.
sfi2022 Mar 7, 2024
4abdd04
:recycle: MDAS-457 Review notes implemented.
sfi2022 Mar 8, 2024
6d797a2
:tada: Adjustes build and compliance workflow
mirrodi Mar 8, 2024
d37793d
:construction_worker: Add publishing to dev
mirrodi Mar 8, 2024
3f950f6
:construction_worker: Add publishing to test
mirrodi Mar 8, 2024
4b7bf8b
:recycle: Rename workflow job
mirrodi Mar 8, 2024
b40003b
:construction_worker: Add publishing to demo
mirrodi Mar 8, 2024
5d2e941
:construction_worker: Add publishing to prod
mirrodi Mar 8, 2024
c08d117
:construction_worker: Add release building
mirrodi Mar 8, 2024
72bf92a
:recycle: MDAS-457 Review notes implemented.
sfi2022 Mar 8, 2024
54b4ac1
Merge branch 'MDAS-457_Implementierung-S3-EAI-Endpunkt-vorsignierte-A…
sfi2022 Mar 11, 2024
372db27
:recycle: MDAS-457 Review notes implemented.
sfi2022 Mar 11, 2024
36df883
:recycle: MDAS-457 Review notes implemented.
sfi2022 Mar 11, 2024
0277ee8
Merge pull request #27 from it-at-m/MDAS-457_Implementierung-S3-EAI-E…
sfi2022 Mar 12, 2024
fd02f4e
:construction_worker: Add demo image
mirrodi Mar 12, 2024
d5ae668
:construction_worker: Add dev image
mirrodi Mar 12, 2024
f68c0dd
:construction_worker: Add prod image
mirrodi Mar 12, 2024
8c07449
:construction_worker: Add test image
mirrodi Mar 12, 2024
91ab495
:construction_worker: Add release image
mirrodi Mar 12, 2024
697b4d8
:recycle: Renamed Images
mirrodi Mar 12, 2024
c8ad1e7
:alembic: Testing workflows
mirrodi Mar 12, 2024
0eca2e8
Bump main version to 0.0.1
invalid-email-address Mar 12, 2024
71a471a
:bug: Fixed release build
mirrodi Mar 12, 2024
da7c36e
Merge remote-tracking branch 'origin/461_Deployment' into 461_Deployment
mirrodi Mar 12, 2024
19d6ed0
:alembic: Reverting Maven version
mirrodi Mar 12, 2024
69d020e
Bump main version to 0.0.1
invalid-email-address Mar 12, 2024
dd38fcd
Bump version to 0.0.2-SNAPSHOT
invalid-email-address Mar 12, 2024
1426b3e
:alembic: Testing release build
mirrodi Mar 12, 2024
81ca22f
:alembic: Reverting Maven version
mirrodi Mar 12, 2024
a13b968
Revert "Bump version to 0.0.2-SNAPSHOT"
mirrodi Mar 12, 2024
c731a6a
Merge branch 'sprint' into 461_Deployment
mirrodi Mar 12, 2024
cff7162
Bump main version to 0.0.1
invalid-email-address Mar 12, 2024
d9ab189
:wastebasket: Removed testing code
mirrodi Mar 12, 2024
b71b65b
Merge remote-tracking branch 'origin/461_Deployment' into 461_Deployment
mirrodi Mar 12, 2024
e8b7b19
:recycle: Revert Maven version
mirrodi Mar 12, 2024
c0424bb
:bookmark: Releasenotes
mirrodi Mar 12, 2024
d1dd9d6
Update pull_request_template.md
martind260 Mar 13, 2024
852998c
Remove ignore branches
mirrodi Mar 18, 2024
e5a5b92
Merge pull request #28 from it-at-m/461_Deployment
mirrodi Mar 18, 2024
2335d21
Mdas 674 implementierung s3 eai endpunkt archivierung (#29)
sfi2022 Mar 25, 2024
6be326a
actor: renovate
martind260 Mar 25, 2024
997c545
:sparkles: MDAS-460 S3-EAI-Security-Absicherung (#32)
sfi2022 Apr 9, 2024
825f8fc
462 Git Ops (#33)
mirrodi Apr 9, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
## Pull Request

### Description

### Reference

Issues:

### Definition of Done
*Advice: Unchecked checkboxes are not accepted by the build pipeline. Cross out any non-relevant item by using '~~'.*

- [ ] Acceptance criteria are met
- [ ] Build/Test workflow has successfully finished
- [ ] Release notes are complemented
- [ ] Documentation is complemented (operator manual, system specification)
- [ ] Frontend is locally smoke-tested
- [ ] Board is updated
- [ ] Infrastructure is adjusted

Please delete all side branches after merging.
23 changes: 21 additions & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: build and test
name: Compliance check and build test

on: [push]
on:
push:
pull_request:
types: [ opened, reopened ]

jobs:
compliance:
Expand All @@ -17,3 +20,19 @@ jobs:
policy-path: default.yaml
token: ${{ secrets.GITHUB_TOKEN }}
argvs: "--disable-dependabot --disable-secret-scanning --disable-code-scanning --display"

build-maven:
needs: compliance
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: "17"
distribution: "temurin"
cache: "maven"

- name: Build with Maven
run: mvn --update-snapshots -f pom.xml verify
70 changes: 70 additions & 0 deletions .github/workflows/publish-demo.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
name: Build and publish to demo

on:
workflow_dispatch: # execute manually
schedule: # it's important that the hour in the cron-job is after the hour of project_start_date in step calculate-time-passed
- cron: '0 13 * * 6' # execute automatically every Saturday at 13:00, change!! day of week if needed

env:
SPRINT_LENGTH_IN_WEEKS: 3

jobs:
build-and-docker-push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Get seconds passed since project start # project_start_date needs to be changed!! if different dispatch day is preferred
id: calculate-time-passed
run: | # 2023-10-28 is a Saturday and is used as the base for calculating the weeks passed
project_start_date=$(echo -n "2023-10-28 10:00") # it's important that the hour in this step is before the hour given in the cron-job
project_start_epoch_seconds=$(date -d "$project_start_date" +%s)
time_passed=$(($(date +"%s")-$project_start_epoch_seconds))
echo "::set-output name=time_passed::$time_passed"

- name: Get number of weeks passed
id: get-number-of-weeks
run: | # 604800 is 1 week in seconds
num_weeks_mod_sprint=$(((${{ steps.calculate-time-passed.outputs.time_passed }}/604800)%${{ env.SPRINT_LENGTH_IN_WEEKS }}))
echo "::set-output name=num_weeks_mod_sprint::$num_weeks_mod_sprint"

- name: Check if job should be run # the automatically triggered actions should only be executed at the end of a sprint
if: github.event_name != 'workflow_dispatch' && steps.get-number-of-weeks.outputs.num_weeks_mod_sprint != 0
run: | # canceling the job if the conditions weren't met, https://stackoverflow.com/a/75809743
gh run cancel ${{ github.run_id }}
gh run watch ${{ github.run_id }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Git checkout to main branch # the workflow is triggered in the default branch, which doesn't have to be MAIN
uses: actions/checkout@v4
with: { ref: main } # this also serves as a safeguard for workflows triggered manually

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'

- name: Build with Maven
run: mvn --update-snapshots -f pom.xml verify

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Login to Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push image
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ghcr.io/it-at-m/mobidam-s3-eai:demo
37 changes: 37 additions & 0 deletions .github/workflows/publish-feature.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Build and publish to dev

on: [workflow_dispatch]

jobs:
build-and-docker-push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'

- name: Build with Maven
run: mvn --update-snapshots -f pom.xml verify

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Login to Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push image
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ghcr.io/it-at-m/mobidam-s3-eai:dev
49 changes: 49 additions & 0 deletions .github/workflows/publish-prod.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Build and publish to prod

on:
workflow_dispatch:
inputs:
version:
description: 'Which version should be deployed to production?'
required: true
default: '0.0.1'

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Git checkout to specific version
uses: actions/checkout@v4
with:
ref: refs/tags/${{ github.event.inputs.version }}

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: "17"
distribution: "temurin"
cache: "maven"

- name: Build with Maven
run: mvn -B verify -f pom.xml -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=WARN

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Login to Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push image
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ghcr.io/it-at-m/mobidam-s3-eai:prod
40 changes: 40 additions & 0 deletions .github/workflows/publish-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Build and publish to test

on:
push:
branches:
- 'sprint'

jobs:
build-and-docker-push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'

- name: Build with Maven
run: mvn --update-snapshots -f pom.xml verify

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Login to Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push image
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ghcr.io/it-at-m/mobidam-s3-eai:test
108 changes: 108 additions & 0 deletions .github/workflows/release-build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
name: Build release

on: [workflow_dispatch]

jobs:
release:
name: Release to registry
runs-on: ubuntu-latest
steps:
- name: Git checkout to main branch # Releases are published on main branch
uses: actions/checkout@v4
with: { ref: main }

- name: Install Java and Maven
uses: actions/setup-java@v3
with:
java-version: "17"
distribution: "temurin"
cache: "maven"

- name: Clean Maven Project Version
id: set-version
run: |
current_version=$(mvn help:evaluate -f pom.xml -Dexpression=project.version -q -DforceStdout)
echo "Current version: $current_version"
new_version=$(echo $current_version | sed 's/-SNAPSHOT//')
echo "New version: $new_version"
mvn -B versions:set -f pom.xml -DnewVersion=$new_version
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
git add pom.xml
git commit -m "Bump main version to $new_version"
git push
echo "new_version=$new_version" >> $GITHUB_OUTPUT

- name: Build with Maven
run: mvn -B verify -f pom.xml -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=WARN

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Login to Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push image
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ghcr.io/it-at-m/mobidam-s3-eai:${{ steps.set-version.outputs.new_version }}, ghcr.io/it-at-m/mobidam-s3-eai:demo

github-release:
needs: release
name: Create github release
runs-on: ubuntu-latest
steps:
- name: Git checkout to main branch # Releases are published on main branch
uses: actions/checkout@v4
with: { ref: main }

- name: Get New Project Version
id: get-version
run: |
current_version=$(mvn help:evaluate -f pom.xml -Dexpression=project.version -q -DforceStdout)
new_version=$(echo $current_version | sed 's/-SNAPSHOT//')
echo "New version: $new_version"
echo "new_version=$new_version" >> $GITHUB_OUTPUT

- name: Create GitHub Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.get-version.outputs.new_version }}
release_name: Release ${{ steps.get-version.outputs.new_version }}
draft: false
prerelease: false

increase-snapshot:
needs: release
name: Increase patch-number of the SNAPSHOT-Version
runs-on: ubuntu-latest
steps:
- name: Git checkout to sprint branch # Snapshots are published on sprint branch
uses: actions/checkout@v4
with: { ref: sprint }

- name: Set Maven Project Version
id: set-version
run: |
current_version=$(mvn help:evaluate -f pom.xml -Dexpression=project.version -q -DforceStdout)
echo "Current version: $current_version"
new_version=$(echo $current_version | awk -F. -v OFS=. '{$3=$3+1; print $0"-SNAPSHOT"}')
echo "New version: $new_version"
mvn -B versions:set -DnewVersion=$new_version -f pom.xml
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
git add pom.xml
git commit -m "Bump version to $new_version"
git push
14 changes: 14 additions & 0 deletions .github/workflows/require-checklist.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Require Checklist

on:
pull_request:
types: [opened, edited, synchronize]

jobs:
checklist-check:
runs-on: ubuntu-latest
if: ${{ github.actor != 'renovate[bot]' }}
steps:
- uses: mheap/require-checklist-action@v2
with:
requireChecklist: true
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/target/
/.idea/
/src/main/resources/application-local.yml
Loading
Loading