File tree Expand file tree Collapse file tree 6 files changed +109
-41
lines changed Expand file tree Collapse file tree 6 files changed +109
-41
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 4
4
5
5
# !! This script is meant for use in CI build use only !!
6
6
7
- BINDIR=/home/build/go/bin
8
-
9
7
KERNEL=$( uname -s)
10
8
11
9
# Use doas in place of sudo for OpenBSD.
@@ -15,13 +13,6 @@ if [ "${KERNEL}" == "OpenBSD" ]; then
15
13
fi
16
14
17
15
if [ " ${KERNEL} " == " Linux" ]; then
18
- # Set up the WireGuard kernel module on Linux.
19
- sudo apt --allow-unauthenticated -y update
20
- sudo apt -y install software-properties-common
21
- sudo add-apt-repository -y ppa:wireguard/wireguard
22
- sudo apt --allow-unauthenticated -y update
23
- sudo apt --allow-unauthenticated -y install linux-headers-$( uname -r) wireguard-dkms wireguard-tools
24
-
25
16
# Configure a WireGuard interface.
26
17
sudo ip link add wg0 type wireguard
27
18
sudo ip link set up wg0
39
30
go build -o wireguard-go
40
31
fi
41
32
42
- mkdir -p ${BINDIR}
43
- ${SUDO} mv ./wireguard-go ${BINDIR} /wireguard-go
33
+ ${SUDO} mv ./wireguard-go /usr/local/bin/wireguard-go
44
34
cd ..
45
35
${SUDO} rm -rf ./wireguard-go
Original file line number Diff line number Diff line change
1
+ name : Linux Integration Test
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+ pull_request :
8
+ branches :
9
+ - ' *'
10
+
11
+ jobs :
12
+ build :
13
+ strategy :
14
+ matrix :
15
+ go-version : [1.16]
16
+ runs-on : ubuntu-latest
17
+
18
+ steps :
19
+ - name : Set up Go
20
+ uses : actions/setup-go@v2
21
+ with :
22
+ go-version : ${{ matrix.go-version }}
23
+ id : go
24
+
25
+ - name : Check out code into the Go module directory
26
+ uses : actions/checkout@v2
27
+
28
+ - name : Set up integration test WireGuard interfaces
29
+ run : ./.cibuild.sh
30
+
31
+ - name : Start wireguard-go userspace device
32
+ run : sudo wireguard-go wguser0
33
+
34
+ - name : Build integration test binary
35
+ run : go test -c -race .
36
+
37
+ - name : Run integration tests
38
+ run : sudo WGCTRL_INTEGRATION=yesreallydoit ./wgctrl.test -test.v -test.run TestIntegration
Original file line number Diff line number Diff line change
1
+ name : Linux Test
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+ pull_request :
8
+ branches :
9
+ - ' *'
10
+
11
+ jobs :
12
+ build :
13
+ strategy :
14
+ matrix :
15
+ go-version : [1.16]
16
+ runs-on : ubuntu-latest
17
+
18
+ steps :
19
+ - name : Set up Go
20
+ uses : actions/setup-go@v2
21
+ with :
22
+ go-version : ${{ matrix.go-version }}
23
+ id : go
24
+
25
+ - name : Check out code into the Go module directory
26
+ uses : actions/checkout@v2
27
+
28
+ - name : Run tests
29
+ run : go test -race ./...
Original file line number Diff line number Diff line change
1
+ name : Static Analysis
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+ pull_request :
8
+ branches :
9
+ - ' *'
10
+
11
+ jobs :
12
+ build :
13
+ strategy :
14
+ matrix :
15
+ go-version : [1.16]
16
+ runs-on : ubuntu-latest
17
+
18
+ steps :
19
+ - name : Set up Go
20
+ uses : actions/setup-go@v2
21
+ with :
22
+ go-version : ${{ matrix.go-version }}
23
+ id : go
24
+
25
+ - name : Check out code into the Go module directory
26
+ uses : actions/checkout@v2
27
+
28
+ - name : Download staticcheck
29
+ run : go get honnef.co/go/tools/cmd/staticcheck
30
+
31
+ - name : Print staticcheck version
32
+ run : go run honnef.co/go/tools/cmd/staticcheck -version
33
+
34
+ - name : Run staticcheck
35
+ run : go run honnef.co/go/tools/cmd/staticcheck -- ./...
36
+
37
+ - name : Run go vet
38
+ run : go vet ./...
Original file line number Diff line number Diff line change 1
- # wgctrl [ ![ builds.sr.ht status] ( https://builds.sr.ht/~mdlayher/wgctrl-go.svg )] ( https://builds.sr.ht/~mdlayher/wgctrl-go? ) [ ![ GoDoc] ( https://godoc.org/golang.zx2c4.com/wireguard/wgctrl?status.svg )] ( https://godoc.org/golang.zx2c4.com/wireguard/wgctrl ) [ ![ Go Report Card] ( https://goreportcard.com/badge/golang.zx2c4.com/wireguard/wgctrl )] ( https://goreportcard.com/report/golang.zx2c4.com/wireguard/wgctrl )
1
+ # wgctrl [ ![ Test Status] ( https://golang.zx2c4.com/wireguard/wgctrl/workflows/Linux%20Test/badge.svg )] ( https://github.com/WireGuard/wgctrl-go/actions ) [ ![ Go Reference] ( https://pkg.go.dev/badge/golang.zx2c4.com/wireguard/wgctrl.svg )] ( https://pkg.go.dev/golang.zx2c4.com/wireguard/wgctrl ) [ ![ Go Report Card] ( https://goreportcard.com/badge/golang.zx2c4.com/wireguard/wgctrl )] ( https://goreportcard.com/report/golang.zx2c4.com/wireguard/wgctrl )
2
+
3
+ [ ![ Test Status] ( https://golang.zx2c4.com/wireguard/wgctrl/workflows/Linux%20Test/badge.svg )] ( https://golang.zx2c4.com/wireguard/wgctrl/actions ) [ ![ Go Reference] ( https://pkg.go.dev/badge/golang.zx2c4.com/wireguard/wgctrl.svg )] ( https://pkg.go.dev/golang.zx2c4.com/wireguard/wgctrl )
2
4
3
5
Package ` wgctrl ` enables control of WireGuard devices on multiple platforms.
4
6
You can’t perform that action at this time.
0 commit comments