synology-dsm-open-vm-tools/.github/workflows/build.yml
AuxXxilium 81bb852c89 tree: fix (thanks to @wjz304)
Signed-off-by: AuxXxilium <info@auxxxilium.tech>
2024-04-08 22:35:02 +02:00

68 lines
1.7 KiB
YAML

#
# Copyright (C) 2023 AuxXxilium <https://github.com/AuxXxilium> and Ing <https://github.com/wjz304>
#
# This is free software, licensed under the MIT License.
# See /LICENSE for more information.
#
name: build
on:
workflow_dispatch:
inputs:
tag:
description: "tag"
required: false
type: string
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
target: [x64-7.1, aarch64-7.1]
steps:
- name: Checkout
uses: actions/checkout@main
- name: Init Env
run: |
git config --global user.email "info@auxxxilium.tech"
git config --global user.name "AuxXxilium"
sudo timedatectl set-timezone "Europe/Berlin"
- name: Checkout SynoCommunity Source and Docker Image
run: |
docker pull ghcr.io/synocommunity/spksrc
git clone --depth=1 https://github.com/SynoCommunity/spksrc.git
cp -rf src/* spksrc
- name: Build Package
run: |
ROOT_PATH="${{ github.workspace }}"
MAKE_ARCH="arch-${{ matrix.target }}"
docker run -v ${ROOT_PATH}/spksrc:/spksrc -w /spksrc/spk/open-vm-tools ghcr.io/synocommunity/spksrc make ${MAKE_ARCH}
- name: Upload to Artifacts
if: inputs.tag == ''
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.target }}
path: |
spksrc/packages/*.spk
retention-days: 5
- name: Release
if: inputs.tag != ''
uses: softprops/action-gh-release@v2
body: |
### DSM 7.0 / 7.1 / 7.2
- Perform code repair using SSH connection
`sudo sed -i 's/package/root/g' /var/packages/open-vm-tools/conf/privilege`
with:
tag_name: ${{ inputs.tag }}
files: spksrc/packages/*.spk