Continue with CI

This commit is contained in:
Andrey Pohilko
2022-08-22 17:54:11 +03:00
parent 3a11b78f51
commit 0b4931a73a
4 changed files with 13 additions and 961 deletions

View File

@@ -32,3 +32,5 @@ jobs:
with: with:
version: latest version: latest
args: release --snapshot --rm-dist args: release --snapshot --rm-dist
- name: Test Binary is Runnable
run: "dist/helm-dashboard_linux_amd64_v1/helm-dashboard --help"

1
go.mod
View File

@@ -4,6 +4,7 @@ go 1.18
require ( require (
github.com/gin-gonic/gin v1.8.1 github.com/gin-gonic/gin v1.8.1
github.com/sirupsen/logrus v1.8.1
github.com/spf13/cobra v1.4.0 github.com/spf13/cobra v1.4.0
github.com/toqueteos/webbrowser v1.2.0 github.com/toqueteos/webbrowser v1.2.0
helm.sh/helm/v3 v3.9.3 helm.sh/helm/v3 v3.9.3

962
go.sum

File diff suppressed because it is too large Load Diff

View File

@@ -1,9 +1,11 @@
package main package main
import ( import (
log "github.com/sirupsen/logrus"
"github.com/toqueteos/webbrowser" "github.com/toqueteos/webbrowser"
_ "k8s.io/client-go/plugin/pkg/client/auth" //required for auth _ "k8s.io/client-go/plugin/pkg/client/auth" //required for auth
"net/http" "net/http"
"os"
) )
var ( var (
@@ -12,7 +14,14 @@ var (
) )
func main() { func main() {
log.Infof("Helm Dashboard by Komodor, version %s (%s)", version, commit)
if len(os.Args) > 1 {
os.Exit(0)
}
go func() { go func() {
// TODO: if it's already running - just open the tab, check that it's another instance of us via API
err := webbrowser.Open("http://localhost:8080") err := webbrowser.Open("http://localhost:8080")
if err != nil { if err != nil {
return return