Skip to content

Commit

Permalink
release on tag
Browse files Browse the repository at this point in the history
  • Loading branch information
yury-sannikov committed Dec 14, 2023
1 parent 48e47ca commit d62dde8
Showing 1 changed file with 12 additions and 27 deletions.
39 changes: 12 additions & 27 deletions .github/workflows/build-module.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Release AmneziaWG Kernel Module
on: [workflow_dispatch]
# on:
# push:
# tags:
# - "v*.*.*"
name: Create Release on Tag
# on: [workflow_dispatch]
on:
push:
tags:
- "v*.*.*"

jobs:
build:
Expand Down Expand Up @@ -104,34 +104,19 @@ jobs:
- name: Prepare artifacts
run: |
ls -al bin/packages/${{ matrix.build_env.pkgarch }}/awgopenwrt || true
ls -al bin/targets/${{ matrix.build_env.target}}/${{ matrix.build_env.subtarget}}/packages/ || true
tag_name=${{ github.ref_name }}
tag_name=${tag_name:=test}
echo "tag_name: ${tag_name}"
mkdir -p awgrelease
postfix="${tag_name}_${{ matrix.tag }}_${{ matrix.build_env.pkgarch}}_${{ matrix.build_env.target}}_${{ matrix.build_env.subtarget}}"
echo "postfix: ${postfix}"
cp bin/packages/${{ matrix.build_env.pkgarch }}/awgopenwrt/amnezia-wg-tools_*.ipk awgrelease/amnezia-wg-tools_${postfix}.ipk
cp bin/packages/${{ matrix.build_env.pkgarch }}/awgopenwrt/luci-app-amneziawg_*.ipk awgrelease/luci-app-amneziawg_${postfix}.ipk
cp bin/targets/${{ matrix.build_env.target}}/${{ matrix.build_env.subtarget}}/packages/kmod-amneziawg_*.ipk awgrelease/kmod-amneziawg_${postfix}.ipk
ls -al awgrelease/
cp bin/targets/${{ matrix.build_env.target}}/${{ matrix.build_env.subtarget}}/packages/kmod-amneziawg_*.ipk awgrelease/kmod-amneziawg_${postfix}.ipk
- name: Release
uses: softprops/action-gh-release@v1
with:
files: awgrelease/*.ipk

# - name: Release
# uses: softprops/action-gh-release@v1
# with:
# files: |
# bin/targets/${{ matrix.build_env.target}}/${{ matrix.build_env.subtarget}}/packages/kmod-amneziawg*.ipk

- name: Clenanup
- name: Cleanup
run: |
rm feeds.conf || true
rm -rf awgrelease || true

0 comments on commit d62dde8

Please sign in to comment.