mirror of
https://github.com/ngoduykhanh/wireguard-ui.git
synced 2025-04-19 19:59:13 +03:00
Add build information to the bianry
This commit is contained in:
parent
04174594b9
commit
8aa84b2be6
1 changed files with 14 additions and 0 deletions
14
main.go
14
main.go
|
@ -8,9 +8,23 @@ import (
|
||||||
"github.com/ngoduykhanh/wireguard-ui/router"
|
"github.com/ngoduykhanh/wireguard-ui/router"
|
||||||
"github.com/ngoduykhanh/wireguard-ui/util"
|
"github.com/ngoduykhanh/wireguard-ui/util"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
var appVersion = "development"
|
||||||
|
var gitCommit = "N/A"
|
||||||
|
var gitRef = "N/A"
|
||||||
|
var buildTime = fmt.Sprintf(time.Now().UTC().Format("01-02-2006 15:04:05"))
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
// print app information
|
||||||
|
fmt.Println("Wireguard UI")
|
||||||
|
fmt.Println("App Version\t:", appVersion)
|
||||||
|
fmt.Println("Git Commit\t:", gitCommit)
|
||||||
|
fmt.Println("Git Ref\t\t:", gitRef)
|
||||||
|
fmt.Println("Build Time\t:", buildTime)
|
||||||
|
fmt.Println("Git Repo\t:", "https://github.com/ngoduykhanh/wireguard-ui")
|
||||||
|
|
||||||
// initialize DB
|
// initialize DB
|
||||||
err := util.InitDB()
|
err := util.InitDB()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Add table
Reference in a new issue