Skip to content

Commit

Permalink
Revendor
Browse files Browse the repository at this point in the history
  • Loading branch information
tamalsaha committed Feb 2, 2018
1 parent bf16fa3 commit 08296cf
Show file tree
Hide file tree
Showing 87 changed files with 23,376 additions and 343 deletions.
28 changes: 24 additions & 4 deletions glide.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions pkg/cli/restic.go
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,7 @@ func (w *ResticWrapper) run(cmd string, args []interface{}) error {
if len(parts) > 1 {
parts = parts[len(parts)-1:]
return errors.New(parts[0])
} else {
return err
}
}
return nil
return err
}
11 changes: 3 additions & 8 deletions pkg/cmds/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ import (
"github.com/appscode/go/log"
stringz "github.com/appscode/go/strings"
v "github.com/appscode/go/version"
"github.com/appscode/kutil/discovery"
"github.com/appscode/pat"
api "github.com/appscode/stash/apis/stash"
cs "github.com/appscode/stash/client/typed/stash/v1alpha1"
"github.com/appscode/stash/pkg/controller"
"github.com/appscode/stash/pkg/docker"
"github.com/hashicorp/go-version"
"github.com/prometheus/client_golang/prometheus/promhttp"
"github.com/spf13/cobra"
crd_cs "k8s.io/apiextensions-apiserver/pkg/client/clientset/clientset/typed/apiextensions/v1beta1"
Expand Down Expand Up @@ -49,15 +49,10 @@ func NewCmdRun() *cobra.Command {
crdClient := crd_cs.NewForConfigOrDie(config)

// get kube api server version
info, err := kubeClient.Discovery().ServerVersion()
opts.KubectlImageTag, err = discovery.GetBaseVersion(kubeClient.Discovery())
if err != nil {
log.Fatalf("Error getting server version, reason: %s\n", err)
log.Fatalf("Failed to detect server version, reason: %s\n", err)
}
gv, err := version.NewVersion(info.GitVersion)
if err != nil {
log.Fatalf("Failed to parse server version, reason: %s\n", err)
}
opts.KubectlImageTag = gv.ToMutator().ResetMetadata().ResetPrerelease().ResetPatch().String()

ctrl := controller.New(kubeClient, crdClient, stashClient, opts)
err = ctrl.Setup()
Expand Down
4 changes: 2 additions & 2 deletions test/e2e/e2e_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"time"

logs "github.com/appscode/go/log/golog"
"github.com/appscode/kutil/discovery"
api "github.com/appscode/stash/apis/stash"
"github.com/appscode/stash/client/scheme"
_ "github.com/appscode/stash/client/scheme"
Expand Down Expand Up @@ -75,9 +76,8 @@ var _ = BeforeSuite(func() {
}

// get kube api server version
version, err := kubeClient.Discovery().ServerVersion()
opts.KubectlImageTag, err = discovery.GetBaseVersion(kubeClient.Discovery())
Expect(err).NotTo(HaveOccurred())
opts.KubectlImageTag = version.Major + "." + version.Minor + ".0"

ctrl = controller.New(kubeClient, crdClient, stashClient, opts)
By("Registering CRD group " + api.GroupName)
Expand Down
1 change: 1 addition & 0 deletions test/e2e/framework/framework.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package framework

import (
"path/filepath"

"github.com/appscode/go/crypto/rand"
"github.com/appscode/kutil/tools/certstore"
cs "github.com/appscode/stash/client/typed/stash/v1alpha1"
Expand Down
62 changes: 62 additions & 0 deletions vendor/github.com/appscode/kutil/discovery/lib.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

78 changes: 78 additions & 0 deletions vendor/github.com/appscode/kutil/extensions/v1beta1/ingress.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

34 changes: 34 additions & 0 deletions vendor/github.com/appscode/kutil/meta/cmp.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 08296cf

Please sign in to comment.