name: Building Wine Runner Off-line Pages(amd64) run-name: ${{ github.actor }} Building Wine Runner Off-line Pages(amd64) 🚀 on: workflow_dispatch: jobs: Explore-GitHub-Actions: runs-on: ubuntu-latest steps: - name: Building DEB env: GUSER: ${{ secrets.GUSER }} PASSWORD: ${{ secrets.PASSWORD }} UPLOADURL: ${{ secrets.UPLOADURL }} run: | # 获取所需数据 cpu=$(cat /proc/cpuinfo | grep processor | wc -l) # 配置环境 sudo apt update sudo apt install python3-requests debootstrap xz-utils -y cd ~ mkdir package # 部署 chroot 环境 sudo debootstrap bookworm debian wget https://github.com/gfdgd-xi/deep-wine-runner/raw/main/pardus-chroot sudo cp pardus-chroot /usr/bin sudo chmod 777 /usr/bin/pardus-chroot sudo pardus-chroot debian ### 配置容器 ## 加入 wine 源 sudo chroot debian dpkg --add-architecture i386 sudo chroot debian apt update sudo chroot debian apt install wget -y sudo chroot debian wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key sudo chroot debian wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/debian/dists/bookworm/winehq-bookworm.sources sudo chroot debian apt update ## 获取 Wine 运行器安装包 git clone https://github.com/gfdgd-xi/deep-wine-runner --depth=1 url=`python3 deep-wine-runner/off-line-shell/GetNewestDebUrl.py` wget $url mv *.deb debian/tmp/wine-runner.deb ## 安装 sudo chroot debian apt install locales /tmp/wine-runner.deb winehq-devel -y # 构建软件包 sudo cp debian/opt package -rv sudo cp debian/usr/bin package -rv sudo cp debian/usr/lib package -rv sudo cp debian/usr/lib32 package -rv sudo cp debian/usr/lib64 package -rv cp deep-wine-runner/off-line-shell/run.sh package -rv cp deep-wine-runner/off-line-shell/bwrap_amd64 package/bwrap -rv sudo chmod 777 -Rv package cd package tar -cvf ../spark-deepin-wine-runner-off-line.tar * cd .. xz -T $cpu spark-deepin-wine-runner-off-line.tar - name: upload result uses: actions/upload-artifact@v1 with: name: spark-deepin-wine-runner-off-line.tar.xz path: /home/runner/spark-deepin-wine-runner-off-line.tar.xz