summaryrefslogtreecommitdiff
path: root/pkg/backend/actions.go
blob: 805c5ad533af54160e9acee59258deb064c979b1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package backend

import (
	"log"
)

func startVPN() {
	setError("")
	err := ctx.bm.StartVPN(ctx.Provider)
	if err != nil {
		log.Println("ERROR: ", err)
		setError(err.Error())
	}
}

func stopVPN() {
	err := ctx.bm.StopVPN()
	if err != nil {
		log.Println(err)
	}
}

func getGateway() string {
	return ctx.bm.GetCurrentGateway()
}