Skip to content

Commit

Permalink
Updated github->actions
Browse files Browse the repository at this point in the history
Signed-off-by: Taras Drozdovskyi <t.drozdovsky@samsung.com>
  • Loading branch information
tdrozdovsky committed Dec 12, 2023
1 parent 564afba commit 3d1c27b
Show file tree
Hide file tree
Showing 7 changed files with 87 additions and 22 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
platform: [numaker_pfm_m2351, m2351_badge, mps2_an505_qemu]
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11

- name: Install extra tools
run: |
Expand Down
61 changes: 43 additions & 18 deletions .github/workflows/fossology.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,54 @@ on: [push, pull_request]
# contents: read

jobs:
fossology:
runs-on: ubuntu-latest

container:
image: fossology/fossology:scanner

check-license:
name: Check license
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- run: |
docker run --rm --name "fossologyscanner" -w "/opt/repo" -v ${PWD}:/opt/repo \
-e GITHUB_TOKEN=${{ github.token }} \
-e GITHUB_PULL_REQUEST=${{ github.event.number }} \
-e GITHUB_REPOSITORY=${{ github.repository }} \
-e GITHUB_REPO_URL=${{ github.repositoryUrl }} \
-e GITHUB_REPO_OWNER=${{ github.repository_owner }} \
-e GITHUB_API=${{ github.api_url }} \
-e GITHUB_ACTIONS=true \
fossology/fossology:scanner "/bin/fossologyscanner" --report TEXT repo nomos ojo
# - name: Upload artifact
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce
with:
name: scan-fossology-report
path: ./results

- name: Fossology run
run: |
export GITHUB_TOKEN=${{secrets.GITHUB_TOKEN}}
export GITHUB_PULL_REQUEST="None"
/bin/fossologyscanner repo nomos ojo copyright keyword
continue-on-error: true
# - name: Artifact download
- uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
with:
name: scan-fossology-report

- name: Upload artifact
uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce
check-copyright:
name: Check copyright
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- run: |
docker run --rm --name "fossologyscanner" -w "/opt/repo" -v ${PWD}:/opt/repo \
-e GITHUB_TOKEN=${{ github.token }} \
-e GITHUB_PULL_REQUEST=${{ github.event.number }} \
-e GITHUB_REPOSITORY=${{ github.repository }} \
-e GITHUB_API=${{ github.api_url }} \
-e GITHUB_REPO_URL=${{ github.repositoryUrl }} \
-e GITHUB_REPO_OWNER=${{ github.repository_owner }} \
-e GITHUB_ACTIONS=true \
fossology/fossology:scanner "/bin/fossologyscanner" --report TEXT repo copyright keyword
# - name: Upload artifact
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce
with:
name: scan-fossology-report
path: ./results

- name: Artifact download
uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
# - name: Artifact download
- uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
with:
name: scan-fossology-report
name: scan-fossology-report
38 changes: 38 additions & 0 deletions .github/workflows/fossology_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Check diff for license with Fossology

on: [push, pull_request]


jobs:
check-license:
name: Check license
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- run: |
docker run --rm --name "fossologyscanner" -w "/opt/repo" -v ${PWD}:/opt/repo \
-e GITHUB_TOKEN=${{ github.token }} \
-e GITHUB_PULL_REQUEST=${{ github.event.number }} \
-e GITHUB_REPOSITORY=${{ github.repository }} \
-e GITHUB_REPO_URL=${{ github.repositoryUrl }} \
-e GITHUB_REPO_OWNER=${{ github.repository_owner }} \
-e GITHUB_API=${{ github.api_url }} \
-e GITHUB_ACTIONS=true \
fossology/fossology:scanner "/bin/fossologyscanner" --report TEXT repo nomos ojo
check-copyright:
name: Check copyright
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- run: |
docker run --rm --name "fossologyscanner" -w "/opt/repo" -v ${PWD}:/opt/repo \
-e GITHUB_TOKEN=${{ github.token }} \
-e GITHUB_PULL_REQUEST=${{ github.event.number }} \
-e GITHUB_REPOSITORY=${{ github.repository }} \
-e GITHUB_API=${{ github.api_url }} \
-e GITHUB_REPO_URL=${{ github.repositoryUrl }} \
-e GITHUB_REPO_OWNER=${{ github.repository_owner }} \
-e GITHUB_ACTIONS=true \
fossology/fossology:scanner "/bin/fossologyscanner" --report TEXT repo copyright keyword
2 changes: 1 addition & 1 deletion .github/workflows/license-finder.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
image: gianlucadb0/license_finder

steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11

- name: License finder run
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/scancode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
image: gianlucadb0/scancode-toolkit

steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11

- name: Create results directory
run: mkdir results
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/scorecards-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:

steps:
- name: "Checkout code"
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
with:
persist-credentials: false

Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,3 +90,5 @@ you can find here](.github/CONTRIBUTING.md).
[NuMaker-PFM-M2351]: http://www.nuvoton.com.cn/hq/products/iot-solution/iot-platform/numaker-maker-platform/numaker-pfm-m2351?__locale=en
[M2351-Badge]: docs/schemes/m2351_badge
[V2M-MPS2-Qemu]: https://developer.arm.com/documentation/100964/1114/Microcontroller-Prototyping-System-2?lang=en


0 comments on commit 3d1c27b

Please sign in to comment.