Skip to content

Commit

Permalink
fix error
Browse files Browse the repository at this point in the history
Former-commit-id: da9844b0172b6e9ff0dab957af06d15d2f1a6985 [formerly da9844b0172b6e9ff0dab957af06d15d2f1a6985 [formerly 46fa7c6]]
Former-commit-id: 420ae457dd5e70c343420670fe5b4a9d31de2584
Former-commit-id: 060db0d
  • Loading branch information
WakeupTsai committed Jun 27, 2018
1 parent 4e79889 commit 7e49c35
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,11 @@ import (
"encoding/json"
"fmt"
"os"
"path/filepath"

"github.com/linkernetworks/logger"
"github.com/linkernetworks/mongo"
"github.com/linkernetworks/redis"
"github.com/linkernetworks/vortex/src/prometheus"
"k8s.io/client-go/tools/clientcmd"
)

type Config struct {
Expand All @@ -34,13 +32,6 @@ func Read(path string) (c Config, err error) {
return c, fmt.Errorf("Failed to load the config file: %v\n", err)
}

// FIXME, we need to find a way to test the fakeclient evne if we don't install the k8s
kubeconfig := filepath.Join(os.Getenv("HOME"), ".kube", "config")
c.Kubernetes, err = clientcmd.BuildConfigFromFlags("", kubeconfig)
if err != nil {
return c, fmt.Errorf("Failed to open the kubernetes config file: %v\n", err)
}

return c, nil
}

Expand Down

0 comments on commit 7e49c35

Please sign in to comment.