Skip to content

Commit

Permalink
adding mkdeb.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
ampledata committed Jun 19, 2024
1 parent 8a4428a commit 310edbc
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 22 deletions.
37 changes: 15 additions & 22 deletions .github/workflows/deb-build-action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,34 +11,27 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: create sample script
run: |
mkdir -p .debpkg/usr/bin
mkdir -p .debpkg/lib/systemd/system
mkdir -p .debpkg/boot
- name: Create Debian package structure
run: mkdeb.sh

cp adsbxfeed.sh .debpkg/usr/bin/adsbxfeed.sh
chmod +x .debpkg/usr/bin/adsbxfeed.sh
cp adsbxfeed.service .debpkg/lib/systemd/system
cp adsbxfeed.txt .debpkg/boot
# create DEBIAN directory if you want to add other pre/post scripts
mkdir -p .debpkg/DEBIAN
echo -e "systemctl enable adsbxfeed --now" > .debpkg/DEBIAN/postinst
chmod +x .debpkg/DEBIAN/postinst
echo -e "systemctl disable adsbxfeed --now" > .debpkg/DEBIAN/prerm
chmod +x .debpkg/DEBIAN/prerm
- name: Make amd64 Debian package
uses: jiro4989/build-deb-action@v3
with:
package: adsbxfeed
package_root: .debpkg
maintainer: Greg Albrecht
arch: amd64
version: ${{ github.ref }} # refs/tags/v*.*.*
desc: "Configures ADSBExchange ADS-B feeder."
homepage: 'https://github.com/snstac/adsbxfeed'

- uses: jiro4989/build-deb-action@v3
- name: Make arm64 Debian package
uses: jiro4989/build-deb-action@v3
with:
package: adsbxfeed
package_root: .debpkg
maintainer: Greg Albrecht
arch: any
arch: arm64
version: ${{ github.ref }} # refs/tags/v*.*.*
desc: "Configures ADSBExchange ADS-B feeder."
homepage: 'https://github.com/snstac/adsbxfeed'
Expand Down
21 changes: 21 additions & 0 deletions mkdeb.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/bin/bash

mkdir -p .debpkg/usr/bin
mkdir -p .debpkg/lib/systemd/system
mkdir -p .debpkg/boot

cp adsbxfeed.sh .debpkg/usr/bin/adsbxfeed.sh
chmod +x .debpkg/usr/bin/adsbxfeed.sh

cp adsbxfeed.service .debpkg/lib/systemd/system

cp adsbxfeed.txt .debpkg/boot

# create DEBIAN directory if you want to add other pre/post scripts
mkdir -p .debpkg/DEBIAN

echo -e "systemctl enable adsbxfeed --now" > .debpkg/DEBIAN/postinst
chmod +x .debpkg/DEBIAN/postinst

echo -e "systemctl disable adsbxfeed --now" > .debpkg/DEBIAN/prerm
chmod +x .debpkg/DEBIAN/prerm

0 comments on commit 310edbc

Please sign in to comment.