wgctrl-go/os_userspace.go
Matt Layher 97bc4ad4a1
FreeBSD kernel support (#128)
* internal/freebsd: add initial version of FreeBSD support
* internal/wguser: Replace deprecated io/ioutil package with io
* internal/freebsd: prepare CI to run tests on FreeBSD
* test: sort AllowedIPs before diffing them
* test: skip integration test configure_peers_update_only on FreeBSD
* test: increase test timeout for slow FreeBSD tests
* add FreeBSD support to README

Signed-off-by: Steffen Vogel <post@steffenvogel.de>

* *: tidy
* go.mod: bump dependencies
* .builds: try to fix OpenBSD

Signed-off-by: Matt Layher <mdlayher@gmail.com>

Co-authored-by: Steffen Vogel <post@steffenvogel.de>
2022-11-04 09:57:56 -04:00

21 lines
502 B
Go

//go:build !linux && !openbsd && !windows && !freebsd
// +build !linux,!openbsd,!windows,!freebsd
package wgctrl
import (
"golang.zx2c4.com/wireguard/wgctrl/internal/wginternal"
"golang.zx2c4.com/wireguard/wgctrl/internal/wguser"
)
// newClients configures wginternal.Clients for systems which only support
// userspace WireGuard implementations.
func newClients() ([]wginternal.Client, error) {
c, err := wguser.New()
if err != nil {
return nil, err
}
return []wginternal.Client{c}, nil
}