main/postmarketos-config-nftables: add openrc subpkg (MR 5172)

For installing openrc-specific dependencies, specifically
nftables-openrc which is needed because the post-install enables the
openrc service and expects the initd script to be available then

[ci:skip-build] already built successfully in CI
This commit is contained in:
Clayton Craft 2024-05-27 10:16:54 -07:00
parent aaa7d267a2
commit fd16f66e4f
No known key found for this signature in database
GPG key ID: 4A4CED6D7EDF950A
2 changed files with 10 additions and 3 deletions

View file

@ -1,12 +1,11 @@
# Maintainer: Clayton Craft <clayton@craftyguy.net>
pkgname=postmarketos-config-nftables
pkgver=0.16
pkgrel=0
pkgrel=1
pkgdesc="nftables firewall configuration for postmarketOS"
url="https://gitlab.com/postmarketos"
arch="noarch"
license="MIT"
depends="nftables-openrc"
subpackages="
$pkgname-openusb:openusb
$pkgname-log:log
@ -19,6 +18,7 @@ subpackages="
$pkgname-vlc-chromecast:vlc_chromecast
$pkgname-vncserver:vncserver
$pkgname-wifi-display:wifi_display
$pkgname-openrc
"
source="
rules/00_log_all.nft
@ -39,7 +39,6 @@ source="
networkmanager.conf
"
options="!check" # No tests
install="$pkgname.post-install"
package() {
cd rules
@ -48,6 +47,14 @@ package() {
done
}
openrc() {
install_if="$pkgname=$pkgver-r$pkgrel openrc"
install="$subpkgname.post-install"
depends="nftables-openrc"
mkdir -p "$subpkgdir"
}
openusb() {
depends="$pkgname"
description="Adds a rule to accept all incoming connections to the usb* interface"