wireguard-tools: add an sv service.
This commit is contained in:
parent
ce9248f1ce
commit
2a11885991
3 changed files with 21 additions and 1 deletions
7
srcpkgs/wireguard-tools/files/wireguard/finish
Executable file
7
srcpkgs/wireguard-tools/files/wireguard/finish
Executable file
|
@ -0,0 +1,7 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
for conf in /etc/wireguard/*.conf; do
|
||||
[ -e "$conf" ] || continue;
|
||||
wg-quick down "$conf"
|
||||
done
|
9
srcpkgs/wireguard-tools/files/wireguard/run
Executable file
9
srcpkgs/wireguard-tools/files/wireguard/run
Executable file
|
@ -0,0 +1,9 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
for conf in /etc/wireguard/*.conf; do
|
||||
[ -e "$conf" ] || continue;
|
||||
wg-quick up "$conf"
|
||||
done
|
||||
|
||||
exec chpst -b wireguard pause
|
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'wireguard-tools'
|
||||
pkgname=wireguard-tools
|
||||
version=1.0.20200513
|
||||
revision=1
|
||||
revision=2
|
||||
build_wrksrc="src"
|
||||
build_style=gnu-makefile
|
||||
make_install_args="WITH_BASHCOMPLETION=yes WITH_WGQUICK=yes"
|
||||
|
@ -17,3 +17,7 @@ make_dirs="/etc/wireguard 0700 root root"
|
|||
post_extract() {
|
||||
sed -i 's/^CFLAGS /override &/' ${build_wrksrc}/Makefile
|
||||
}
|
||||
|
||||
post_install() {
|
||||
vsv wireguard
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue