mirror of
https://github.com/e-m-b-a/emba.git
synced 2026-10-12 02:13:21 +00:00
Merge pull request #2117 from m-1-k-3/report_deploy
Example report deployment
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
name: Deploy EMBA Report to GitHub Pages
|
||||
|
||||
on:
|
||||
# Allows you to trigger this manually or via an API webhook from your build server
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 0 * * 1' # Runs every Monday at midnight to refresh public demos
|
||||
|
||||
permissions:
|
||||
contents: write # Crucial: Allows the runner to push data to the gh-pages branch
|
||||
|
||||
jobs:
|
||||
analyze-and-deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - https://github.com/actions/checkout/releases/tag/v6.0.2
|
||||
- name: Free Disk Space (Ubuntu)
|
||||
uses: jlumbroso/free-disk-space@54081f138730dfa15788a46383842cd2f914a1be # v1.3.1 - https://github.com/jlumbroso/free-disk-space/releases/tag/v1.3.1
|
||||
with:
|
||||
tool-cache: true
|
||||
android: true
|
||||
dotnet: true
|
||||
haskell: true
|
||||
large-packages: false
|
||||
swap-storage: true
|
||||
- name: EMBA default install
|
||||
uses: nick-fields/retry@ad984534de44a9489a53aefd81eb77f87c70dc60 # v4.0.0 - https://github.com/nick-fields/retry/releases/tag/v4.0.0
|
||||
with:
|
||||
timeout_minutes: 800
|
||||
max_attempts: 3
|
||||
command: |
|
||||
sudo rm -r ./external || true
|
||||
sudo ./installer.sh -d
|
||||
- name: Run Firmware Download
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install wget
|
||||
wget https://ftp.dlink.de/dir/dir-600/archive/driver_software/DIR-600_fw_revb5_214b01_ALL_de_20130122.zip
|
||||
- name: Run EMBA Firmware Analyzer
|
||||
run: |
|
||||
NO_UPDATE_CHECK=1 sudo -E ./emba -f ./DIR-600_fw_revb5_214b01_ALL_de_20130122.zip -l ./logs_emba -p ./scan-profiles/default-scan.emba -y -Q
|
||||
- name: Prepare public html report
|
||||
run: |
|
||||
mkdir -p emba-report
|
||||
cp -r logs_emba/html-report/* emba-report/
|
||||
- name: Deploy HTML Report to GitHub Pages
|
||||
uses: JamesIves/github-pages-deploy-action@fa24774553152dd7873cd16ebd8d959b010c5445 # v4.9.0 - https://github.com/JamesIves/github-pages-deploy-action/releases/tag/v4.9.0
|
||||
with:
|
||||
folder: emba-report # The directory containing EMBA's index.html and assets
|
||||
branch: emba_report # The branch GitHub Pages will serve from
|
||||
clean: true # Automatically removes old files if you only want the 'latest' scan visible
|
||||
|
||||
Reference in New Issue
Block a user