mirror of
https://github.com/Slava-Shchipunov/awg-openwrt.git
synced 2026-03-14 01:13:09 +00:00
feat: upgrade workflow
This commit is contained in:
42
.github/workflows/build-module.yml
vendored
42
.github/workflows/build-module.yml
vendored
@@ -1,22 +1,44 @@
|
||||
name: Create Release on Tag
|
||||
# on: [workflow_dispatch]
|
||||
# on:
|
||||
# push:
|
||||
# tags:
|
||||
# - "v*.*.*"
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*.*.*"
|
||||
|
||||
jobs:
|
||||
generate-config:
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
job-config: ${{ steps.generate-config.outputs.job-config }}
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20.16.0'
|
||||
|
||||
- name: Get OpenWRT version from tag
|
||||
id: get_version
|
||||
run: echo "VERSION=${GITHUB_REF/refs\/tags\/v/}" >> $GITHUB_ENV
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm install
|
||||
|
||||
- name: Generate Job Config
|
||||
id: generate-config
|
||||
run: node index.js ${{ env.VERSION }}
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
build:
|
||||
name: "v${{ matrix.build_env.tag }} - ${{ matrix.build_env.pkgarch}} :: ${{ matrix.build_env.target}}/${{ matrix.build_env.subtarget}} build"
|
||||
runs-on: ubuntu-latest
|
||||
needs: generate-config
|
||||
strategy:
|
||||
matrix:
|
||||
build_env:
|
||||
- tag: "23.05.4"
|
||||
pkgarch: aarch64_cortex-a53
|
||||
target: mediatek
|
||||
subtarget: filogic
|
||||
vermagic: "03ba5b5fee47f2232a088e3cd9832aec"
|
||||
build_env: ${{ fromJson(needs.generate-config.outputs.job-config) }}
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
35
.github/workflows/tets-script.yml
vendored
35
.github/workflows/tets-script.yml
vendored
@@ -1,35 +0,0 @@
|
||||
name: OpenWRT Data Fetch
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*.*.*'
|
||||
|
||||
jobs:
|
||||
fetch-data:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20.16.0'
|
||||
|
||||
- name: Get OpenWRT version from tag
|
||||
id: get_version
|
||||
run: echo "VERSION=${GITHUB_REF/refs\/tags\/v/}" >> $GITHUB_ENV
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm install
|
||||
|
||||
- name: Run script with version
|
||||
run: node index.js ${{ env.VERSION }}
|
||||
|
||||
- name: Upload results.json
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: results
|
||||
path: results.json
|
||||
Reference in New Issue
Block a user