Skip to content

Commit

Permalink
Merge pull request #127 from weaveworks/dev
Browse files Browse the repository at this point in the history
release version 2.0.0
  • Loading branch information
Ahmed El-Sayed authored Nov 9, 2022
2 parents 2de8aad + a30a6c3 commit b4c76a2
Show file tree
Hide file tree
Showing 47 changed files with 4,458 additions and 155 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
env:
CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}}
run: |
go test -v -cover -covermode=atomic -coverprofile=coverage.txt ./...
make test
bash <(curl -s https://codecov.io/bash) -F unit
- name: Build docker image
Expand Down
10 changes: 7 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ manifests: controller-gen ## Generate WebhookConfiguration, ClusterRole and Cust
cd api && $(CONTROLLER_GEN) rbac:roleName=manager-role crd webhook paths="./..." output:crd:artifacts:config=../config/crd/bases
cp config/crd/bases/pac.weave.works_policies.yaml helm/crds
cp config/crd/bases/pac.weave.works_policysets.yaml helm/crds
cp config/crd/bases/pac.weave.works_policyconfigs.yaml helm/crds


.PHONY: generate
generate: controller-gen ## Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
Expand All @@ -71,7 +73,7 @@ vet: ## Run go vet against code.

.PHONY: test
test: manifests generate fmt vet envtest ## Run tests.
KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) -p path)" go test ./... -coverprofile cover.out
KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) -p path)" go test -v ./... -coverprofile cover.out

##@ Build

Expand Down Expand Up @@ -127,12 +129,14 @@ deploy: manifests kustomize ## Deploy controller to the K8s cluster specified in
undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion.
$(KUSTOMIZE) build config/default | kubectl delete --ignore-not-found=$(ignore-not-found) -f -

CONTROLLER_GEN = $(shell pwd)/bin/controller-gen
LOCALBIN = $(shell pwd)/bin
KUSTOMIZE = $(LOCALBIN)/kustomize
CONTROLLER_GEN = $(LOCALBIN)/controller-gen

.PHONY: controller-gen
controller-gen: ## Download controller-gen locally if necessary.
$(call go-get-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/controller-gen@v0.8.0)

KUSTOMIZE = $(shell pwd)/bin/kustomize
.PHONY: kustomize
kustomize: ## Download kustomize locally if necessary.
$(call go-get-tool,$(KUSTOMIZE),sigs.k8s.io/kustomize/kustomize/v3@v3.8.7)
Expand Down
42 changes: 39 additions & 3 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,47 @@ resources:
- api:
crdVersion: v1
namespaced: false
- api:
domain: weave.works
kind: Policy
path: api/v1
version: v1
- api:
crdVersion: v2beta1
namespaced: false
domain: weave.works
kind: Policy
path: github.com/weaveworks/policy-agent/api/v1
version: v1
path: api/v1
version: v2beta1
- api:
crdVersion: v2beta1
namespaced: false
domain: weave.works
kind: PolicySet
path: api/v1
version: v2beta1
- api:
crdVersion: v2beta2
namespaced: false
domain: weave.works
kind: Policy
path: api/v1
version: v2beta2
- api:
crdVersion: v2beta2
namespaced: false
domain: weave.works
kind: PolicySet
path: api/v1
version: v2beta2
- api:
crdVersion: v2beta2
namespaced: false
domain: weave.works
kind: PolicyConfig
path: api/v1
version: v2beta2
webhooks:
# defaulting: true
validation: true
webhookVersion: v1
version: "3"
30 changes: 30 additions & 0 deletions api/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,49 @@ require (
)

require (
github.com/beorn7/perks v1.0.1 // indirect
github.com/cespare/xxhash/v2 v2.1.1 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/evanphx/json-patch v4.12.0+incompatible // indirect
github.com/fsnotify/fsnotify v1.5.1 // indirect
github.com/go-logr/logr v1.2.0 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/google/go-cmp v0.5.5 // indirect
github.com/google/gofuzz v1.1.0 // indirect
github.com/google/uuid v1.1.2 // indirect
github.com/googleapis/gnostic v0.5.5 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/prometheus/client_golang v1.11.0 // indirect
github.com/prometheus/client_model v0.2.0 // indirect
github.com/prometheus/common v0.28.0 // indirect
github.com/prometheus/procfs v0.6.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
golang.org/x/net v0.0.0-20211209124913-491a49abca63 // indirect
golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f // indirect
golang.org/x/sys v0.0.0-20211029165221-6e7872819dc8 // indirect
golang.org/x/term v0.0.0-20210615171337-6886f2dfbf5b // indirect
golang.org/x/text v0.3.7 // indirect
golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac // indirect
gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/protobuf v1.27.1 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
k8s.io/api v0.23.4 // indirect
k8s.io/client-go v0.23.4 // indirect
k8s.io/component-base v0.23.4 // indirect
k8s.io/klog/v2 v2.30.0 // indirect
k8s.io/kube-openapi v0.0.0-20211115234752-e816edb12b65 // indirect
k8s.io/utils v0.0.0-20211116205334-6203023598ed // indirect
sigs.k8s.io/json v0.0.0-20211020170558-c049b76a60c6 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.1 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
)
Loading

0 comments on commit b4c76a2

Please sign in to comment.