-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
andrey.shulika
committed
Jan 2, 2024
1 parent
ea7b398
commit 5d91835
Showing
2 changed files
with
86 additions
and
0 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,23 @@ | ||
name: Dev build and publish Docker distributions to Github Container Registry ghcr.io | ||
|
||
on: | ||
push: | ||
branches-ignore: | ||
- master | ||
- version-* | ||
- dependabot** | ||
paths-ignore: | ||
- README.md | ||
|
||
env: | ||
APP_NAME: ${{ github.repository }} | ||
BRANCH: ${{ github.ref }} | ||
|
||
jobs: | ||
build-job: | ||
uses: th2-net/.github/.github/workflows/compound-java-dev.yml@main | ||
with: | ||
build-target: 'Docker' | ||
docker-username: ${{ github.actor }} | ||
secrets: | ||
docker-password: ${{ secrets.GITHUB_TOKEN }} |
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,63 @@ | ||
name: Check licenses | ||
|
||
on: | ||
push: | ||
branches-ignore: | ||
- master | ||
- version-* | ||
- dependabot** | ||
paths-ignore: | ||
- README.md | ||
|
||
env: | ||
APP_NAME: ${{ github.repository }} | ||
BRANCH: ${{ github.ref }} | ||
|
||
jobs: | ||
check_licenses: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: checkout actions | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install jq env | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y jq | ||
- name: Download script | ||
run: | | ||
wget -q -O check_licenses.sh https://raw.githubusercontent.com/th2-net/.github/th2-1836-json-files-update/license-compliance/check_licenses.sh | ||
chmod +x ./check_licenses.sh | ||
- name: Run check_licenses script | ||
run: ./check_licenses.sh java | ||
id: run_script | ||
|
||
- name: Get version | ||
run: | ||
VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\),\1,') | ||
|
||
- name: Uploading results | ||
if: always() | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: licenses_check-$APP_NAME-$VERSION | ||
path: ./licenses_check/ | ||
|
||
- name: Results checking | ||
id: result-check | ||
run: | | ||
line_count=$(wc -l < ./licenses_check/failed_licenses.csv) | ||
if [[ $line_count -gt 1 ]]; then | ||
echo "FAILED due to unknown/failed licenses found" | ||
exit 1 | ||
else | ||
echo "PASSED: licenses check successfull" | ||
exit 0 | ||
fi | ||
continue-on-error: false | ||
|
||
# - name: Set workflow status | ||
# run: echo "::set-output name=status::Failure" | ||
# if: steps.set_status.outputs.result == 'FAILED due to unknown licenses found' | ||
# continue-on-error: false |