Skip to content

Automatic debian package upload to deb repo #62

Automatic debian package upload to deb repo

Automatic debian package upload to deb repo #62

Workflow file for this run

name: Create debian package
on: [push, pull_request]
env:
pkg_name: fcow_1.2-${{github.run_number}}
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Create package structure
run: |
mkdir ${{env.pkg_name}}
cd ${{env.pkg_name}}
mkdir -p DEBIAN usr/local/bin usr/local/man/man6 usr/local/share/fcow
- name: Copy stuff inside
run: |
cp deb_control ${{env.pkg_name}}/DEBIAN/control
cp src/* ${{env.pkg_name}}/usr/local/bin/
chmod +x ${{env.pkg_name}}/usr/local/bin/*
cp share/* ${{env.pkg_name}}/usr/local/share/fcow/
cp man/* ${{env.pkg_name}}/usr/local/man/man6/
- name: Create deb package
run: dpkg-deb -Zxz --build ${{env.pkg_name}}
- name: Upload deb as artifact
uses: actions/upload-artifact@v3
with:
name: ${{env.pkg_name}}.deb
path: ${{env.pkg_name}}.deb
- name: Install rsync
run: apt install rsync
- name: Upload deb to repo
run: RSYNC_PASSWORD=${{secrets.RSYNC_REPO_PASS}} rsync -avz ${{env.pkg_name}}.deb rsync://[email protected]/debupload/pool/contrib/