mirror of
https://gitlab.postmarketos.org/postmarketOS/pmaports.git
synced 2025-07-13 16:49:46 +03:00
The type was erroneously set as 'simple', and since we are setting ExecStop we actually need to set RemainAfterExit to avoid running ExecStop when the oneshot service runs. This is because nft returns/ exits pretty much immediately after applying the config. fixes #2846
14 lines
315 B
Desktop File
14 lines
315 B
Desktop File
[Unit]
|
|
Description=nftables firewall used on pmOS
|
|
Wants=network-pre.target
|
|
Before=network-pre.target
|
|
|
|
[Service]
|
|
Type=oneshot
|
|
ExecStart=/usr/sbin/nft -f "/etc/nftables.nft"
|
|
ExecReload=/usr/sbin/nft -f "/etc/nftables.nft"
|
|
ExecStop=/usr/sbin/nft flush ruleset
|
|
RemainAfterExit=yes
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|