58 lines
1.8 KiB
YAML
58 lines
1.8 KiB
YAML
name: Build Packages
|
|
|
|
on:
|
|
watch:
|
|
types: started
|
|
repository_dispatch:
|
|
types: build
|
|
|
|
jobs:
|
|
build:
|
|
if: github.event.repository.owner.id == github.event.sender.id
|
|
name: Build ${{ matrix.arch }}-${{ matrix.tag }}
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
arch:
|
|
- aarch64_generic
|
|
- x86_64
|
|
tag:
|
|
- openwrt-23.05
|
|
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Build Packages
|
|
uses: sbwml/openwrt-gh-action-sdk@helloworld
|
|
env:
|
|
ARCH: ${{ matrix.arch }}-${{ matrix.tag }}
|
|
FEEDNAME: packages_ci
|
|
PACKAGES: luci-app-passwall luci-app-passwall2 luci-app-ssr-plus hysteria ipt2socks pdnsd redsocks2 shadow-tls trojan tuic-client xray-plugin v2ray-core v2ray-geodata naiveproxy chinadns-ng
|
|
KEY_BUILD: ${{ secrets.sign_key }}
|
|
NO_REFRESH_CHECK: true
|
|
IGNORE_ERRORS: true
|
|
|
|
- name: Upload artifacts
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: ${{ matrix.tag }}-${{ matrix.arch }}
|
|
path: bin/packages/${{ matrix.arch }}/packages_ci/*.ipk
|
|
|
|
- name: Upload FTP
|
|
uses: sbwml/FTP-Deploy-Action@master
|
|
with:
|
|
server: ${{ secrets.ftp_address }}
|
|
username: ${{ secrets.ftp_username }}
|
|
password: ${{ secrets.ftp_password }}
|
|
server-dir: ${{ matrix.tag }}/${{ matrix.arch }}/
|
|
local-dir: bin/packages/${{ matrix.arch }}/packages_ci/
|
|
dangerous-clean-slate: true
|
|
|
|
- name: Create metadata
|
|
run: |
|
|
sshpass -p ${{ secrets.server_password }} ssh -o StrictHostKeyChecking=no root@${{ secrets.ftp_address }} >/dev/null 2>&1
|
|
sshpass -p ${{ secrets.server_password }} ssh root@${{ secrets.ftp_address }} "/opt/sbin/opkg"
|