Skip to content

Commit

Permalink
Merge pull request #15 from sapcc/fix-deps
Browse files Browse the repository at this point in the history
Fix dependency issues
  • Loading branch information
talal committed Jul 7, 2021
2 parents dd3346c + 51b871d commit 443a96b
Show file tree
Hide file tree
Showing 3,237 changed files with 268 additions and 1,198,423 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
29 changes: 24 additions & 5 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,19 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: "1.15"
go-version: "1.16"

- name: Cache Go modules
uses: actions/cache@v2
with:
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
path: |
~/go/pkg/mod
~/.cache/go-build
restore-keys: ${{ runner.os }}-go-

- name: Make build
run: GO_BUILDFLAGS='-mod vendor' make build-all
run: make build-all

lint:
name: Lint
Expand All @@ -43,7 +53,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: "1.15"
go-version: "1.16"

- name: Run golangci-lint
uses: golangci/golangci-lint-action@v2
Expand All @@ -63,16 +73,25 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: "1.15"
go-version: "1.16"

- name: Cache kubebuilder control plane binaries
uses: actions/cache@v2
with:
path: test/bin
key: ${{ runner.os }}-kubebuilder-${{ hashFiles('test/.kubebuilder-version') }}

- name: Cache Go modules
uses: actions/cache@v2
with:
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
path: |
~/go/pkg/mod
~/.cache/go-build
restore-keys: ${{ runner.os }}-go-

- name: Run tests and generate coverage report
run: GO_BUILDFLAGS='-mod vendor' make build/cover.out
run: make build/cover.out

- name: Upload coverage report to Coveralls
env:
Expand Down
1 change: 0 additions & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
run:
modules-download-mode: vendor
deadline: 2m # 1m by default

linters:
Expand Down
5 changes: 2 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ build/release-info: build CHANGELOG.md

build-all: build/absent-metrics-operator

GO_BUILDFLAGS = -mod vendor
GO_BUILDFLAGS =
GO_LDFLAGS = -X main.version=$(VERSION) -X main.commit=$(COMMIT_HASH) -X main.date=$(BUILD_DATE)
GO_TESTENV =

Expand Down Expand Up @@ -72,9 +72,8 @@ build/cover.html: build/cover.out
build:
@mkdir $@

vendor: FORCE
tidy-deps: FORCE
go mod tidy
go mod vendor
go mod verify

license-headers: FORCE
Expand Down
3 changes: 0 additions & 3 deletions Makefile.maker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ binaries:
fromPackage: .
installTo: bin/

vendoring:
enabled: true

staticCheck:
golangciLint: true

Expand Down
13 changes: 5 additions & 8 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/sapcc/absent-metrics-operator

go 1.15
go 1.16

// Note: ensure that the "k8s.io/*" and "github.com/prometheus/*" dependencies
// have the same versions as used by github.com/prometheus-operator/prometheus-operator.
Expand All @@ -9,22 +9,19 @@ require (
github.com/onsi/ginkgo v1.16.4
github.com/onsi/gomega v1.13.0
github.com/pkg/errors v0.9.1
github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.48.1
github.com/prometheus-operator/prometheus-operator/pkg/client v0.48.1
github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.49.0
github.com/prometheus-operator/prometheus-operator/pkg/client v0.49.0
github.com/prometheus/client_golang v1.11.0
github.com/prometheus/prometheus v1.8.2-0.20210421143221-52df5ef7a3be
github.com/prometheus/prometheus v1.8.2-0.20210701133801-b0944590a1c9
github.com/sapcc/go-bits v0.0.0-20210518135053-8a9465bb1339
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c
k8s.io/api v0.21.2
k8s.io/apimachinery v0.21.2
k8s.io/client-go v12.0.0+incompatible
k8s.io/client-go v0.21.2
sigs.k8s.io/controller-runtime v0.9.2
)

replace (
// A replace directive is needed for k8s.io/client-go because Cortex (which
// is an indirect dependency through Thanos) has a requirement on v12.0.0.
k8s.io/client-go => k8s.io/client-go v0.21.0
// Override the official klog package with this one. This simply replaces
// the code in vendor/k8s.io/klog with the code of this package.
k8s.io/klog => github.com/simonpasquier/klog-gokit v0.3.0
Expand Down
283 changes: 237 additions & 46 deletions go.sum

Large diffs are not rendered by default.

20 changes: 0 additions & 20 deletions vendor/github.com/beorn7/perks/LICENSE

This file was deleted.

Loading

0 comments on commit 443a96b

Please sign in to comment.