Skip to content

Commit

Permalink
Merge pull request #132 from wmedlar/issue-116
Browse files Browse the repository at this point in the history
Migrate dependency management to dep
  • Loading branch information
lizrice authored May 18, 2018
2 parents 82b1e05 + 6c7422a commit b502d09
Show file tree
Hide file tree
Showing 7 changed files with 185 additions and 95 deletions.
5 changes: 2 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@ before_install:
- gem install --no-ri --no-rdoc fpm

install:
- go get -v github.com/Masterminds/glide
- cd $GOPATH/src/github.com/Masterminds/glide && git checkout tags/v0.12.3 && go install && cd - # use a known good glide version
- glide install
- go get -v github.com/golang/dep/cmd/dep
- dep ensure -v -vendor-only

script:
- go test ./...
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM golang:1.9 AS build
WORKDIR /go/src/github.com/aquasecurity/kube-bench/
ADD glide.lock glide.yaml ./
RUN go get github.com/Masterminds/glide && glide install
ADD Gopkg.toml Gopkg.lock ./
RUN go get -v github.com/golang/dep/cmd/dep && dep ensure -v -vendor-only
ADD main.go .
ADD check/ check/
ADD cmd/ cmd/
Expand Down
153 changes: 153 additions & 0 deletions Gopkg.lock

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

23 changes: 23 additions & 0 deletions Gopkg.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
[[constraint]]
name = "github.com/fatih/color"
version = "1.5.0"

[[constraint]]
branch = "master"
name = "github.com/golang/glog"

[[constraint]]
name = "github.com/jinzhu/gorm"
version = "1.0.0"

[[constraint]]
name = "github.com/spf13/cobra"
version = "0.0.1"

[[constraint]]
name = "github.com/spf13/viper"
version = "1.0.0"

[prune]
go-tests = true
unused-packages = true
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,12 @@ You can then run `./kube-bench <master|node>`.

If Go is installed on the target machines, you can simply clone this repository and run as follows (assuming your [$GOPATH is set](https://github.com/golang/go/wiki/GOPATH)):

```go get github.com/aquasecurity/kube-bench
go get github.com/Masterminds/glide
```shell
go get github.com/aquasecurity/kube-bench
go get github.com/golang/dep/cmd/dep
cd $GOPATH/src/github.com/aquasecurity/kube-bench
$GOPATH/bin/glide install
go build -o kube-bench .
$GOPATH/bin/dep ensure -vendor-only
go build -o kube-bench .

# See all supported options
./kube-bench --help
Expand Down
72 changes: 0 additions & 72 deletions glide.lock

This file was deleted.

14 changes: 0 additions & 14 deletions glide.yaml

This file was deleted.

0 comments on commit b502d09

Please # to comment.