-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #130 from es-ude/develop
Develop
- Loading branch information
Showing
123 changed files
with
5,183 additions
and
4,999 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
module.exports = { | ||
extends: ["@commitlint/config-conventional"], | ||
rules: { | ||
"type-empty": [2, "never"], | ||
"type-case": [2, "always", "lower-case"], | ||
"type-enum": [ | ||
2, | ||
"always", | ||
["build", "ci", "feat", "fix", "docs", "style", "refactor", "revert", "chore", "wip", "perf"], | ||
], | ||
"scope-empty": [2, "never"], | ||
"scope-case": [2, "always", "kebab-case"], | ||
"scope-enum": [ | ||
2, | ||
"always", | ||
["all", "application", "runtime", "workflow", "readme", "kubernetes", "docker", "gradle"], | ||
], | ||
}, | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
name: "Build Release Packages" | ||
on: | ||
workflow_dispatch: | ||
release: | ||
types: | ||
- released | ||
permissions: | ||
contents: read | ||
packages: write | ||
jobs: | ||
maven_package: | ||
name: Publish runtime as Maven Package | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.head_ref }} | ||
- name: Get Release Version | ||
id: release | ||
uses: GuillaumeFalourd/get-release-or-tag@v2 | ||
- name: Setup Java | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 22 | ||
- name: Setup Gradle | ||
uses: gradle/actions/setup-gradle@v4 | ||
- name: Push Package | ||
env: | ||
ACTOR: ${{ github.actor }} | ||
TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
./gradlew -Pversion=${{ steps.release.outputs.tag }} :runtime:publish | ||
container_image: | ||
name: Publish Monitor as Container Image | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.head_ref }} | ||
- name: Get Release Version | ||
id: release | ||
uses: GuillaumeFalourd/get-release-or-tag@v2 | ||
- name: Get Release Artifacts | ||
uses: Itsblue/download-release-assets-action@v4 | ||
with: | ||
version: ${{ steps.release.outputs.tag }} | ||
file: "monitor.jar" | ||
path: "monitor/build/libs" | ||
- name: Build Monitor Image | ||
working-directory: ./monitor | ||
env: | ||
RELEASE_TAG: ${{ steps.release.outputs.tag }} | ||
run: | | ||
docker build --file Dockerfile --tag ghcr.io/$GITHUB_REPOSITORY:$RELEASE_TAG --tag ghcr.io/$GITHUB_REPOSITORY:latest . | ||
- name: Login to Github Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Push Image to Github Container Registry | ||
run: | | ||
docker push --all-tags ghcr.io/$GITHUB_REPOSITORY |
24 changes: 14 additions & 10 deletions
24
.github/workflows/push_to_main.yml → .github/workflows/create_release.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,37 @@ | ||
# Workflow requires Variables to be defined as follows: | ||
# secrets.PUSH_TOKEN -> Password with rights to push to repository | ||
|
||
name: "Create Release" | ||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- 'main' | ||
|
||
- "main" | ||
permissions: | ||
contents: read | ||
jobs: | ||
semantic_release: | ||
release: | ||
name: Generate Release | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
issues: write | ||
pull-requests: write | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
persist-credentials: false | ||
- name: Build bootJar | ||
run: | | ||
./gradlew :monitor:bootJar | ||
- name: Install Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
cache: npm | ||
node-version: "lts/*" | ||
- name: Install semantic-release Plugin | ||
- name: Install NodeJS Dependencies | ||
run: npm clean-install | ||
- name: Verify the integrity of provenance attestations and registry signatures for installed dependencies | ||
- name: Verify the integrity and registry signatures for dependencies | ||
run: npm audit signatures | ||
- name: Create Release | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.PUSH_TOKEN }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: npx semantic-release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,11 +6,9 @@ on: | |
workflow_dispatch: | ||
pull_request: | ||
branches: | ||
- 'main' | ||
|
||
- "main" | ||
jobs: | ||
lint-commits: | ||
name: Commitlint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
|
@@ -20,15 +18,14 @@ jobs: | |
persist-credentials: false | ||
fetch-depth: 0 | ||
- name: Lint Commits | ||
uses: wagoid/commitlint-github-action@v5 | ||
|
||
uses: wagoid/commitlint-github-action@v6 | ||
with: | ||
failOnWarnings: true | ||
failOnErrors: true | ||
prettier: | ||
name: Beautify | ||
runs-on: ubuntu-latest | ||
needs: | ||
- lint-commits | ||
outputs: | ||
new_sha: ${{ steps.sha.outputs.SHA }} | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
@@ -39,30 +36,25 @@ jobs: | |
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 21 | ||
- name: Install Prettier | ||
run: npm ci | ||
- name: Install NodeJS Dependencies | ||
run: npm clean-install | ||
- name: Run Prettier | ||
run: npx prettier --write ./**/*.{java,md} | ||
- name: Publish Changes | ||
id: commit-and-push | ||
uses: EndBug/add-and-commit@v9.1.4 | ||
run: npx prettier --write "**/*.{md,yaml,js,html,java,properties}" | ||
- name: Commit Changes | ||
id: auto-commit | ||
uses: stefanzweifel/git-auto-commit-action@v4 | ||
with: | ||
committer_name: "Prettier Action" | ||
committer_email: "[email protected]" | ||
message: "refactor(style): beautify ${{ github.head_ref }}" | ||
push: true | ||
- name: Update SHA | ||
id: sha | ||
commit_message: "style(all): apply prettier to '${{ github.head_ref }}'" | ||
commit_user_name: github-actions | ||
commit_user_email: [email protected] | ||
commit_author: github-actions <[email protected]> | ||
- name: Check For Updated Files | ||
id: check-further-execution | ||
if: steps.auto-commit.outputs.changes_detected =='true' | ||
run: | | ||
if [[ "${{ steps.commit-and-push.outputs.pushed }}" == "true" ]]; then | ||
new_sha="${{ steps.commit-and-push.outputs.commit_long_sha }}" | ||
else | ||
new_sha="${{ github.head_ref }}" | ||
fi | ||
echo "SHA=$new_sha" >> $GITHUB_OUTPUT | ||
echo "Updates detected. Abort Workflow execution!" | | ||
exit 1 | ||
unit-tests: | ||
name: Unit Tests | ||
runs-on: ubuntu-latest | ||
needs: | ||
- prettier | ||
|
@@ -73,37 +65,34 @@ jobs: | |
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ needs.prettier.outputs.new_sha }} | ||
ref: ${{ github.head_ref }} | ||
- name: Setup Java environment | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 17 | ||
java-version: 22 | ||
- name: Setup Gradle | ||
uses: gradle/gradle-build-action@v3 | ||
- name: Clean Build Artifacts | ||
run: ./gradlew clean | ||
- name: Run All Integration Tests | ||
run: ./gradlew test | ||
|
||
integration-tests: | ||
name: Integration Tests | ||
runs-on: ubuntu-latest | ||
needs: | ||
- prettier | ||
- unit-tests | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ needs.prettier.outputs.new_sha }} | ||
ref: ${{ github.head_ref }} | ||
- name: Setup Java Environment | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 17 | ||
java-version: 22 | ||
- name: Setup Gradle | ||
uses: gradle/gradle-build-action@v2 | ||
uses: gradle/gradle-build-action@v3 | ||
- name: Clean Build Artifacts | ||
run: ./gradlew clean | ||
- name: Run Integration Tests | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.