Skip to content

Commit

Permalink
[Actions] Updating deprecated actions, removing unnecessary checkouts…
Browse files Browse the repository at this point in the history
…, adding workflow dispatch call (#304)

* Updating all actions to Node.js 20

* Triggering Actions on other branches to test the changes

* Adding on workflow_dispatch and making sure the template from develop branch will be triggered

* Adding workflow_dispatch to Windows, updating all actions to v4

* Updating Linux Actions to v4

* Adding comments to Windows actions

* Using templates from develop branches to test it

* Comment adjustments

* Adding branch restriction back and using templates from masters

* Adding branch restriction back for Windows build
  • Loading branch information
VeithMetro committed Jun 6, 2024
1 parent bb02972 commit 061002c
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 24 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Build ThunderNanoServicesRDK on Linux

on:
workflow_dispatch:
push:
branches: ["master"]
pull_request:
Expand Down
19 changes: 11 additions & 8 deletions .github/workflows/Build ThunderNanoServicesRDK on Windows.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Build ThunderNanoServicesRDK on Windows

on:
workflow_dispatch:
push:
branches: ["master"]
pull_request:
Expand All @@ -25,50 +26,52 @@ jobs:
type: [Debug, Release]
version: [64, 86]

# ----- Checkout -----
name: Build type - ${{matrix.type}}${{matrix.version}}
steps:
- name: Checkout ThunderOnWindows
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderOnWindows
repository: WebPlatformForEmbedded/ThunderOnWindows

- name: Checkout Thunder
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderOnWindows/Thunder
repository: rdkcentral/Thunder

- name: Checkout ThunderTools
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderOnWindows/ThunderTools
repository: rdkcentral/ThunderTools

- name: Checkout ThunderClientLibraries
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderOnWindows/ThunderClientLibraries
repository: rdkcentral/ThunderClientLibraries

- name: Checkout ThunderInterfaces
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderOnWindows/ThunderInterfaces
repository: rdkcentral/ThunderInterfaces

- name: Checkout ThunderNanoServices
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderOnWindows/ThunderNanoServices
repository: rdkcentral/ThunderNanoServices

- name: Checkout ThunderNanoServicesRDK
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderOnWindows/ThunderNanoServicesRDK
repository: WebPlatformForEmbedded/ThunderNanoServicesRDK

# ----- Install, build & upload artifacts -----
- name: Install jsonref
run: pip install jsonref

Expand All @@ -87,7 +90,7 @@ jobs:
run: tar -czvf ${{matrix.type}}${{matrix.version}}.tar.gz artifacts

- name: Upload
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: ThunderNanoServicesRDK-${{matrix.type}}${{matrix.version}}-artifact
path: ${{matrix.type}}${{matrix.version}}.tar.gz
23 changes: 7 additions & 16 deletions .github/workflows/Linux build template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@ jobs:

name: Build type - ${{matrix.build_type}}
steps:
# --------- Packages install & artifacts download ---------
- name: Install necessary packages
uses: nick-fields/retry@v2
uses: nick-fields/retry@v3
with:
timeout_minutes: 10
max_attempts: 10
Expand All @@ -27,20 +28,8 @@ jobs:
pip install jsonref
sudo apt install build-essential cmake ninja-build libusb-1.0-0-dev zlib1g-dev libssl-dev
- name: Checkout Thunder
uses: actions/checkout@v3
with:
path: Thunder
repository: rdkcentral/Thunder

- name: Checkout ThunderInterfaces
uses: actions/checkout@v3
with:
path: ThunderInterfaces
repository: rdkcentral/ThunderInterfaces

- name: Download artifacts
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: ThunderInterfaces-${{matrix.build_type}}-artifact
path: ${{matrix.build_type}}
Expand All @@ -50,8 +39,9 @@ jobs:
tar -xvzf ${{matrix.build_type}}/${{matrix.build_type}}.tar.gz
rm ${{matrix.build_type}}/${{matrix.build_type}}.tar.gz
# ----- Checkout & Options regex -----
- name: Checkout ThunderNanoServicesRDK
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: ThunderNanoServicesRDK
repository: WebPlatformForEmbedded/ThunderNanoServicesRDK
Expand All @@ -65,6 +55,7 @@ jobs:
regex_flags: 'gim'
search_string: ${{github.event.pull_request.body}}

# ----- Build & upload artifacts -----
- name: Build ThunderNanoServicesRDK
run: |
cmake -G Ninja -S ThunderNanoServicesRDK -B ${{matrix.build_type}}/build/ThunderNanoServicesRDK \
Expand All @@ -86,7 +77,7 @@ jobs:
run: tar -czvf ${{matrix.build_type}}.tar.gz ${{matrix.build_type}}

- name: Upload
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: ThunderNanoServicesRDK-${{matrix.build_type}}-artifact
path: ${{matrix.build_type}}.tar.gz

0 comments on commit 061002c

Please sign in to comment.