diff --git a/README.md b/README.md index 3ffbb76..9a747b5 100644 --- a/README.md +++ b/README.md @@ -270,10 +270,10 @@ Steve Features -------------- Steve's main use is as an opinionated consumer of -[rancher/apiserver](https://gitlab.devops.telekom.de/caas/rancher/apiserver), which it uses to +[rancher/apiserver](https://github.com/caas-team/apiserver), which it uses to dynamically register every Kubernetes API as its own. It implements apiserver -[Stores](https://pkg.go.dev/gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types#Store) to +[Stores](https://pkg.go.dev/github.com/caas-team/apiserver/pkg/types#Store) to use Kubernetes as its data store. ### Stores @@ -345,7 +345,7 @@ resource for preference storage instead. Counts keeps track of the number of resources and updates the count in a buffered stream that the dashboard can subscribe to. -#### [Subscribe](https://gitlab.devops.telekom.de/caas/rancher/apiserver/tree/master/pkg/subscribe) +#### [Subscribe](https://github.com/caas-team/apiserver/tree/master/pkg/subscribe) Steve exposes a websocket endpoint on /v1/subscribe for sending streams of events. Connect to the endpoint using a websocket client like websocat: @@ -354,7 +354,7 @@ events. Connect to the endpoint using a websocket client like websocat: websocat -k wss://127.0.0.1:9443/v1/subscribe ``` -Review the [apiserver](https://gitlab.devops.telekom.de/caas/rancher/apiserver#subscribe) guide +Review the [apiserver](https://github.com/caas-team/apiserver#subscribe) guide for details. In addition to regular Kubernetes resources, steve allows you to subscribe to @@ -375,8 +375,8 @@ data is always redacted, you could implement a store like this: ```go import ( - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/empty" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/store/empty" + "github.com/caas-team/apiserver/pkg/types" ) type redactStore struct { @@ -461,7 +461,7 @@ Steve implements access control on schemas based on the user's RBAC in Kubernetes. The apiserver -[`Server`](https://pkg.go.dev/gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/server#Server) +[`Server`](https://pkg.go.dev/github.com/caas-team/apiserver/pkg/server#Server) object exposes an AccessControl field which is used to customize how access control is performed on server requests. @@ -482,7 +482,7 @@ checked for existence in the AccessSet, and filtered out if it is not available. This final set of schemas is inserted into the -[`types.APIRequest`](https://pkg.go.dev/gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types#APIRequest) +[`types.APIRequest`](https://pkg.go.dev/github.com/caas-team/apiserver/pkg/types#APIRequest) object and passed to the apiserver handler. ### Authentication @@ -683,13 +683,13 @@ From here, the list is passed to the [listprocessor](https://pkg.go.dev/github.com/caas-team/steve/pkg/stores/partition/listprocessor) to filter, sort, and paginate the list. The partition store formats the list as a -[types.APIObjectList](https://pkg.go.dev/gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types#APIObjectList) +[types.APIObjectList](https://pkg.go.dev/github.com/caas-team/apiserver/pkg/types#APIObjectList) and it is returned up the chain of nested stores. Most stores in steve are implementations of the apiserver -[Store](https://pkg.go.dev/gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types#Store) +[Store](https://pkg.go.dev/github.com/caas-team/apiserver/pkg/types#Store) interface, which returns apiserver -[types](https://pkg.go.dev/gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types). The +[types](https://pkg.go.dev/github.com/caas-team/apiserver/pkg/types). The partitioner implements its own store type called [UnstructuredStore](https://pkg.go.dev/github.com/caas-team/steve/pkg/stores/partition#UnstructuredStore) which returns diff --git a/go.sum b/go.sum index dc68a6e..f7ca000 100644 --- a/go.sum +++ b/go.sum @@ -608,8 +608,8 @@ github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9dec github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= -gitlab.devops.telekom.de/caas/rancher/apiserver v0.0.0-20240124101749-f82a882c4527 h1:2E3Uh1cuLrb1p/E395AkI2KvYxmJMXQJiyaO8Gg7QEI= -gitlab.devops.telekom.de/caas/rancher/apiserver v0.0.0-20240124101749-f82a882c4527/go.mod h1:wLYNaze/kRkrq0snLLVUMrrKQRaF1SKPUGEyq1ADuR0= +github.com/caas-team/apiserver v0.0.0-20240124101749-f82a882c4527 h1:2E3Uh1cuLrb1p/E395AkI2KvYxmJMXQJiyaO8Gg7QEI= +github.com/caas-team/apiserver v0.0.0-20240124101749-f82a882c4527/go.mod h1:wLYNaze/kRkrq0snLLVUMrrKQRaF1SKPUGEyq1ADuR0= go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4= go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= diff --git a/pkg/accesscontrol/access_control.go b/pkg/accesscontrol/access_control.go index 94fd76a..199031c 100644 --- a/pkg/accesscontrol/access_control.go +++ b/pkg/accesscontrol/access_control.go @@ -1,10 +1,10 @@ package accesscontrol import ( + apiserver "github.com/caas-team/apiserver/pkg/server" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/rancher/wrangler/pkg/kv" - apiserver "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/server" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/runtime/schema" ) diff --git a/pkg/accesscontrol/access_set.go b/pkg/accesscontrol/access_set.go index 729d5bd..aaf3b74 100644 --- a/pkg/accesscontrol/access_set.go +++ b/pkg/accesscontrol/access_set.go @@ -3,8 +3,8 @@ package accesscontrol import ( "sort" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/util/sets" ) diff --git a/pkg/attributes/attributes.go b/pkg/attributes/attributes.go index b171b7d..e3fffe6 100644 --- a/pkg/attributes/attributes.go +++ b/pkg/attributes/attributes.go @@ -3,8 +3,8 @@ package attributes import ( "fmt" + "github.com/caas-team/apiserver/pkg/types" "github.com/rancher/wrangler/pkg/data/convert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" ) diff --git a/pkg/client/factory.go b/pkg/client/factory.go index 776f709..0d77986 100644 --- a/pkg/client/factory.go +++ b/pkg/client/factory.go @@ -5,8 +5,8 @@ import ( "net/http" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/client-go/dynamic" "k8s.io/client-go/kubernetes" diff --git a/pkg/clustercache/controller.go b/pkg/clustercache/controller.go index 7279014..d8cde94 100644 --- a/pkg/clustercache/controller.go +++ b/pkg/clustercache/controller.go @@ -5,13 +5,13 @@ import ( "sync" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/schema" "github.com/rancher/wrangler/pkg/merr" "github.com/rancher/wrangler/pkg/summary/client" "github.com/rancher/wrangler/pkg/summary/informer" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" diff --git a/pkg/controllers/schema/schemas.go b/pkg/controllers/schema/schemas.go index acfd318..135cdd0 100644 --- a/pkg/controllers/schema/schemas.go +++ b/pkg/controllers/schema/schemas.go @@ -6,6 +6,7 @@ import ( "sync/atomic" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/resources/common" schema2 "github.com/caas-team/steve/pkg/schema" @@ -13,7 +14,6 @@ import ( apiextcontrollerv1 "github.com/rancher/wrangler/pkg/generated/controllers/apiextensions.k8s.io/v1" v1 "github.com/rancher/wrangler/pkg/generated/controllers/apiregistration.k8s.io/v1" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "golang.org/x/sync/errgroup" "golang.org/x/sync/semaphore" authorizationv1 "k8s.io/api/authorization/v1" diff --git a/pkg/metrics/metrics.go b/pkg/metrics/metrics.go index 5ac2962..2c24b77 100644 --- a/pkg/metrics/metrics.go +++ b/pkg/metrics/metrics.go @@ -4,8 +4,8 @@ import ( "net/http" "strconv" + "github.com/caas-team/apiserver/pkg/apierror" "github.com/prometheus/client_golang/prometheus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/apierror" ) type MetricLogger struct { diff --git a/pkg/resources/apigroups/apigroup.go b/pkg/resources/apigroups/apigroup.go index 7a3257b..2c9ccc7 100644 --- a/pkg/resources/apigroups/apigroup.go +++ b/pkg/resources/apigroups/apigroup.go @@ -5,8 +5,8 @@ import ( "github.com/caas-team/steve/pkg/schema" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/empty" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/store/empty" + "github.com/caas-team/apiserver/pkg/types" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/discovery" ) diff --git a/pkg/resources/cluster/apply.go b/pkg/resources/cluster/apply.go index ad69a1b..960b1d7 100644 --- a/pkg/resources/cluster/apply.go +++ b/pkg/resources/cluster/apply.go @@ -6,13 +6,13 @@ import ( "fmt" "net/http" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" steveschema "github.com/caas-team/steve/pkg/schema" "github.com/caas-team/steve/pkg/stores/proxy" "github.com/pborman/uuid" "github.com/rancher/wrangler/pkg/apply" "github.com/rancher/wrangler/pkg/yaml" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/api/meta" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/pkg/resources/cluster/cluster.go b/pkg/resources/cluster/cluster.go index 43a33a6..88ca07d 100644 --- a/pkg/resources/cluster/cluster.go +++ b/pkg/resources/cluster/cluster.go @@ -4,6 +4,8 @@ import ( "context" "net/http" + "github.com/caas-team/apiserver/pkg/store/empty" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" steveschema "github.com/caas-team/steve/pkg/schema" @@ -11,8 +13,6 @@ import ( detector "github.com/rancher/kubernetes-provider-detector" "github.com/rancher/wrangler/pkg/genericcondition" "github.com/rancher/wrangler/pkg/schemas" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/empty" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" schema2 "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/version" diff --git a/pkg/resources/common/dynamiccolumns.go b/pkg/resources/common/dynamiccolumns.go index 3810d8d..2c86c6c 100644 --- a/pkg/resources/common/dynamiccolumns.go +++ b/pkg/resources/common/dynamiccolumns.go @@ -4,9 +4,9 @@ import ( "context" "fmt" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/rancher/wrangler/pkg/ratelimit" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/apis/meta/internalversion" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" metav1beta1 "k8s.io/apimachinery/pkg/apis/meta/v1beta1" diff --git a/pkg/resources/common/formatter.go b/pkg/resources/common/formatter.go index 0816f0d..3fe2f3e 100644 --- a/pkg/resources/common/formatter.go +++ b/pkg/resources/common/formatter.go @@ -3,6 +3,7 @@ package common import ( "strings" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/schema" @@ -13,7 +14,6 @@ import ( corecontrollers "github.com/rancher/wrangler/pkg/generated/controllers/core/v1" "github.com/rancher/wrangler/pkg/slice" "github.com/rancher/wrangler/pkg/summary" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" diff --git a/pkg/resources/common/formatter_test.go b/pkg/resources/common/formatter_test.go index b0e35bf..a449b22 100644 --- a/pkg/resources/common/formatter_test.go +++ b/pkg/resources/common/formatter_test.go @@ -4,8 +4,8 @@ import ( "net/url" "testing" + "github.com/caas-team/apiserver/pkg/types" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" schema2 "k8s.io/apimachinery/pkg/runtime/schema" ) diff --git a/pkg/resources/counts/buffer.go b/pkg/resources/counts/buffer.go index 5f07966..afa42c0 100644 --- a/pkg/resources/counts/buffer.go +++ b/pkg/resources/counts/buffer.go @@ -3,7 +3,7 @@ package counts import ( "time" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/types" ) // debounceDuration determines how long events will be held before they are sent to the consumer diff --git a/pkg/resources/counts/buffer_test.go b/pkg/resources/counts/buffer_test.go index 3f9b34f..a859ce7 100644 --- a/pkg/resources/counts/buffer_test.go +++ b/pkg/resources/counts/buffer_test.go @@ -6,8 +6,8 @@ import ( "testing" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" ) func Test_countsBuffer(t *testing.T) { diff --git a/pkg/resources/counts/counts.go b/pkg/resources/counts/counts.go index 7c8299f..9fd2202 100644 --- a/pkg/resources/counts/counts.go +++ b/pkg/resources/counts/counts.go @@ -5,12 +5,12 @@ import ( "strconv" "sync" + "github.com/caas-team/apiserver/pkg/store/empty" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/clustercache" "github.com/rancher/wrangler/pkg/summary" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/empty" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/api/meta" "k8s.io/apimachinery/pkg/runtime" schema2 "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/pkg/resources/counts/counts_test.go b/pkg/resources/counts/counts_test.go index 58bccac..185af71 100644 --- a/pkg/resources/counts/counts_test.go +++ b/pkg/resources/counts/counts_test.go @@ -7,6 +7,9 @@ import ( "testing" "time" + "github.com/caas-team/apiserver/pkg/server" + "github.com/caas-team/apiserver/pkg/store/empty" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/clustercache" @@ -15,9 +18,6 @@ import ( "github.com/rancher/wrangler/pkg/schemas" "github.com/rancher/wrangler/pkg/summary" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/server" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/empty" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" schema2 "k8s.io/apimachinery/pkg/runtime/schema" ) diff --git a/pkg/resources/formatters/formatter.go b/pkg/resources/formatters/formatter.go index d49a483..b1a1b4b 100644 --- a/pkg/resources/formatters/formatter.go +++ b/pkg/resources/formatters/formatter.go @@ -1,8 +1,8 @@ package formatters import ( + "github.com/caas-team/apiserver/pkg/types" "github.com/rancher/norman/types/convert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" ) func DropHelmData(request *types.APIRequest, resource *types.RawResource) { diff --git a/pkg/resources/schema.go b/pkg/resources/schema.go index b2a9035..270f20d 100644 --- a/pkg/resources/schema.go +++ b/pkg/resources/schema.go @@ -3,6 +3,9 @@ package resources import ( "context" + "github.com/caas-team/apiserver/pkg/store/apiroot" + "github.com/caas-team/apiserver/pkg/subscribe" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/client" "github.com/caas-team/steve/pkg/clustercache" @@ -17,9 +20,6 @@ import ( "github.com/caas-team/steve/pkg/stores/proxy" "github.com/caas-team/steve/pkg/summarycache" corecontrollers "github.com/rancher/wrangler/pkg/generated/controllers/core/v1" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/apiroot" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/subscribe" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/client-go/discovery" ) diff --git a/pkg/resources/schemas/template.go b/pkg/resources/schemas/template.go index 3dd8d7f..0fb45ce 100644 --- a/pkg/resources/schemas/template.go +++ b/pkg/resources/schemas/template.go @@ -7,14 +7,14 @@ import ( "sync" "time" + "github.com/caas-team/apiserver/pkg/builtin" + schemastore "github.com/caas-team/apiserver/pkg/store/schema" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/schema" "github.com/rancher/wrangler/pkg/broadcast" "github.com/rancher/wrangler/pkg/schemas/validation" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/builtin" - schemastore "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/schema" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/api/equality" "k8s.io/apiserver/pkg/authentication/user" "k8s.io/apiserver/pkg/endpoints/request" diff --git a/pkg/resources/schemas/template_test.go b/pkg/resources/schemas/template_test.go index 52554a2..031bbe5 100644 --- a/pkg/resources/schemas/template_test.go +++ b/pkg/resources/schemas/template_test.go @@ -8,6 +8,7 @@ import ( "testing" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" acfake "github.com/caas-team/steve/pkg/accesscontrol/fake" "github.com/caas-team/steve/pkg/attributes" @@ -16,7 +17,6 @@ import ( "github.com/golang/mock/gomock" v1schema "github.com/rancher/wrangler/pkg/schemas" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apiserver/pkg/authentication/user" "k8s.io/apiserver/pkg/endpoints/request" ) diff --git a/pkg/resources/userpreferences/localpref.go b/pkg/resources/userpreferences/localpref.go index 26e6cef..4b77b0d 100644 --- a/pkg/resources/userpreferences/localpref.go +++ b/pkg/resources/userpreferences/localpref.go @@ -7,8 +7,8 @@ import ( "path/filepath" "github.com/adrg/xdg" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/store/empty" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/store/empty" + "github.com/caas-team/apiserver/pkg/types" "k8s.io/apiserver/pkg/endpoints/request" ) diff --git a/pkg/resources/userpreferences/userpreferences.go b/pkg/resources/userpreferences/userpreferences.go index 0e41f29..80550f2 100644 --- a/pkg/resources/userpreferences/userpreferences.go +++ b/pkg/resources/userpreferences/userpreferences.go @@ -3,7 +3,7 @@ package userpreferences import ( "net/http" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/types" ) type UserPreference struct { diff --git a/pkg/schema/collection.go b/pkg/schema/collection.go index 9e449e7..3728259 100644 --- a/pkg/schema/collection.go +++ b/pkg/schema/collection.go @@ -6,12 +6,12 @@ import ( "strings" "sync" + apiserver "github.com/caas-team/apiserver/pkg/server" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" "github.com/rancher/wrangler/pkg/name" "github.com/sirupsen/logrus" - apiserver "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/server" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/util/cache" "k8s.io/apiserver/pkg/endpoints/request" diff --git a/pkg/schema/converter/crd.go b/pkg/schema/converter/crd.go index 17b84da..44dde67 100644 --- a/pkg/schema/converter/crd.go +++ b/pkg/schema/converter/crd.go @@ -1,11 +1,11 @@ package converter import ( + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/schema/table" apiextv1 "github.com/rancher/wrangler/pkg/generated/controllers/apiextensions.k8s.io/v1" "github.com/rancher/wrangler/pkg/schemas" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" v1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/pkg/schema/converter/discovery.go b/pkg/schema/converter/discovery.go index 5baae2f..2f9a3a4 100644 --- a/pkg/schema/converter/discovery.go +++ b/pkg/schema/converter/discovery.go @@ -3,11 +3,11 @@ package converter import ( "strings" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/rancher/wrangler/pkg/merr" "github.com/rancher/wrangler/pkg/schemas" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" diff --git a/pkg/schema/converter/k8stonorman.go b/pkg/schema/converter/k8stonorman.go index f654eb0..29bdfa8 100644 --- a/pkg/schema/converter/k8stonorman.go +++ b/pkg/schema/converter/k8stonorman.go @@ -4,8 +4,8 @@ import ( "fmt" "strings" + "github.com/caas-team/apiserver/pkg/types" v1 "github.com/rancher/wrangler/pkg/generated/controllers/apiextensions.k8s.io/v1" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" ) diff --git a/pkg/schema/converter/openapi.go b/pkg/schema/converter/openapi.go index 2f272d0..9ffb495 100644 --- a/pkg/schema/converter/openapi.go +++ b/pkg/schema/converter/openapi.go @@ -1,11 +1,11 @@ package converter import ( + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/rancher/wrangler/pkg/data/convert" "github.com/rancher/wrangler/pkg/schemas" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" "k8s.io/kube-openapi/pkg/util/proto" diff --git a/pkg/schema/converter/openapiv3.go b/pkg/schema/converter/openapiv3.go index 09ae764..15b0545 100644 --- a/pkg/schema/converter/openapiv3.go +++ b/pkg/schema/converter/openapiv3.go @@ -1,8 +1,8 @@ package converter import ( + "github.com/caas-team/apiserver/pkg/types" "github.com/rancher/wrangler/pkg/schemas" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" v1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" ) diff --git a/pkg/schema/factory.go b/pkg/schema/factory.go index d85565e..c4239e4 100644 --- a/pkg/schema/factory.go +++ b/pkg/schema/factory.go @@ -7,10 +7,10 @@ import ( "net/http" "time" + "github.com/caas-team/apiserver/pkg/builtin" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/builtin" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apiserver/pkg/authentication/user" ) diff --git a/pkg/schema/factory_test.go b/pkg/schema/factory_test.go index 973f1c9..d3dffcc 100644 --- a/pkg/schema/factory_test.go +++ b/pkg/schema/factory_test.go @@ -5,8 +5,8 @@ import ( "github.com/stretchr/testify/assert" "testing" + "github.com/caas-team/apiserver/pkg/types" "github.com/rancher/wrangler/pkg/schemas" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" k8sSchema "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apiserver/pkg/authentication/user" ) diff --git a/pkg/schema/fake/factory.go b/pkg/schema/fake/factory.go index a8e071c..296a010 100644 --- a/pkg/schema/fake/factory.go +++ b/pkg/schema/fake/factory.go @@ -9,7 +9,7 @@ import ( reflect "reflect" gomock "github.com/golang/mock/gomock" - types "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + types "github.com/caas-team/apiserver/pkg/types" schema "github.com/caas-team/steve/pkg/schema" schema0 "k8s.io/apimachinery/pkg/runtime/schema" user "k8s.io/apiserver/pkg/authentication/user" diff --git a/pkg/schema/table/mapper.go b/pkg/schema/table/mapper.go index 037df61..0286d9d 100644 --- a/pkg/schema/table/mapper.go +++ b/pkg/schema/table/mapper.go @@ -1,11 +1,11 @@ package table import ( + types2 "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/rancher/wrangler/pkg/data" types "github.com/rancher/wrangler/pkg/schemas" "github.com/rancher/wrangler/pkg/schemas/mappers" - types2 "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" ) type Column struct { diff --git a/pkg/server/handler/apiserver.go b/pkg/server/handler/apiserver.go index 82a7e32..f0b9659 100644 --- a/pkg/server/handler/apiserver.go +++ b/pkg/server/handler/apiserver.go @@ -3,15 +3,15 @@ package handler import ( "net/http" + apiserver "github.com/caas-team/apiserver/pkg/server" + "github.com/caas-team/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/urlbuilder" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/auth" k8sproxy "github.com/caas-team/steve/pkg/proxy" "github.com/caas-team/steve/pkg/schema" "github.com/caas-team/steve/pkg/server/router" "github.com/sirupsen/logrus" - apiserver "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/server" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/urlbuilder" "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/client-go/rest" ) diff --git a/pkg/server/handler/handlers.go b/pkg/server/handler/handlers.go index f7094e8..9146a24 100644 --- a/pkg/server/handler/handlers.go +++ b/pkg/server/handler/handlers.go @@ -1,10 +1,10 @@ package handler import ( + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/schema" "github.com/gorilla/mux" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" ) func k8sAPI(sf schema.Factory, apiOp *types.APIRequest) { diff --git a/pkg/server/router/router.go b/pkg/server/router/router.go index a566065..c5be26c 100644 --- a/pkg/server/router/router.go +++ b/pkg/server/router/router.go @@ -3,8 +3,8 @@ package router import ( "net/http" + "github.com/caas-team/apiserver/pkg/urlbuilder" "github.com/gorilla/mux" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/urlbuilder" ) type RouterFunc func(h Handlers) http.Handler diff --git a/pkg/server/server.go b/pkg/server/server.go index 3a2d3f5..35af6f7 100644 --- a/pkg/server/server.go +++ b/pkg/server/server.go @@ -5,6 +5,8 @@ import ( "errors" "net/http" + apiserver "github.com/caas-team/apiserver/pkg/server" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/aggregation" "github.com/caas-team/steve/pkg/auth" @@ -19,8 +21,6 @@ import ( "github.com/caas-team/steve/pkg/server/router" "github.com/caas-team/steve/pkg/summarycache" "github.com/rancher/dynamiclistener/server" - apiserver "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/server" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/client-go/rest" ) diff --git a/pkg/stores/metrics/metrics_client.go b/pkg/stores/metrics/metrics_client.go index ed32b6f..d975523 100644 --- a/pkg/stores/metrics/metrics_client.go +++ b/pkg/stores/metrics/metrics_client.go @@ -3,8 +3,8 @@ package metrics import ( "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/metrics" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" k8stypes "k8s.io/apimachinery/pkg/types" diff --git a/pkg/stores/metrics/metrics_store.go b/pkg/stores/metrics/metrics_store.go index b1c256c..fc755a0 100644 --- a/pkg/stores/metrics/metrics_store.go +++ b/pkg/stores/metrics/metrics_store.go @@ -3,8 +3,8 @@ package metrics import ( "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/metrics" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" ) type Store struct { diff --git a/pkg/stores/partition/listprocessor/processor.go b/pkg/stores/partition/listprocessor/processor.go index f9385a3..b624c83 100644 --- a/pkg/stores/partition/listprocessor/processor.go +++ b/pkg/stores/partition/listprocessor/processor.go @@ -7,10 +7,10 @@ import ( "strconv" "strings" + "github.com/caas-team/apiserver/pkg/types" "github.com/rancher/wrangler/pkg/data" "github.com/rancher/wrangler/pkg/data/convert" corecontrollers "github.com/rancher/wrangler/pkg/generated/controllers/core/v1" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" ) diff --git a/pkg/stores/partition/parallel.go b/pkg/stores/partition/parallel.go index fbe115c..90f76fd 100644 --- a/pkg/stores/partition/parallel.go +++ b/pkg/stores/partition/parallel.go @@ -5,7 +5,7 @@ import ( "encoding/base64" "encoding/json" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/types" "golang.org/x/sync/errgroup" "golang.org/x/sync/semaphore" diff --git a/pkg/stores/partition/store.go b/pkg/stores/partition/store.go index 7e1bff1..c858d47 100644 --- a/pkg/stores/partition/store.go +++ b/pkg/stores/partition/store.go @@ -10,11 +10,11 @@ import ( "strconv" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/stores/partition/listprocessor" corecontrollers "github.com/rancher/wrangler/pkg/generated/controllers/core/v1" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "golang.org/x/sync/errgroup" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/pkg/stores/partition/store_test.go b/pkg/stores/partition/store_test.go index af706dd..7d11013 100644 --- a/pkg/stores/partition/store_test.go +++ b/pkg/stores/partition/store_test.go @@ -10,11 +10,11 @@ import ( "strconv" "testing" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/rancher/wrangler/pkg/generic" "github.com/rancher/wrangler/pkg/schemas" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" diff --git a/pkg/stores/proxy/error_wrapper.go b/pkg/stores/proxy/error_wrapper.go index 5cb2004..665bcf8 100644 --- a/pkg/stores/proxy/error_wrapper.go +++ b/pkg/stores/proxy/error_wrapper.go @@ -1,9 +1,9 @@ package proxy import ( + "github.com/caas-team/apiserver/pkg/apierror" + "github.com/caas-team/apiserver/pkg/types" "github.com/rancher/wrangler/pkg/schemas/validation" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/apierror" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/api/errors" ) diff --git a/pkg/stores/proxy/proxy_store.go b/pkg/stores/proxy/proxy_store.go index 244bdbc..6e70894 100644 --- a/pkg/stores/proxy/proxy_store.go +++ b/pkg/stores/proxy/proxy_store.go @@ -12,6 +12,7 @@ import ( "regexp" "strconv" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" metricsStore "github.com/caas-team/steve/pkg/stores/metrics" @@ -22,7 +23,6 @@ import ( "github.com/rancher/wrangler/pkg/schemas/validation" "github.com/rancher/wrangler/pkg/summary" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "golang.org/x/sync/errgroup" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/pkg/stores/proxy/proxy_store_test.go b/pkg/stores/proxy/proxy_store_test.go index a0c7fbd..f40c151 100644 --- a/pkg/stores/proxy/proxy_store_test.go +++ b/pkg/stores/proxy/proxy_store_test.go @@ -6,11 +6,11 @@ import ( "testing" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/client" "github.com/pkg/errors" "github.com/rancher/wrangler/pkg/schemas" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "golang.org/x/sync/errgroup" v1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/pkg/stores/proxy/rbac_store.go b/pkg/stores/proxy/rbac_store.go index c4959a1..bdc1322 100644 --- a/pkg/stores/proxy/rbac_store.go +++ b/pkg/stores/proxy/rbac_store.go @@ -4,11 +4,11 @@ import ( "fmt" "sort" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/stores/partition" "github.com/rancher/wrangler/pkg/kv" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/watch" diff --git a/pkg/stores/proxy/rbac_store_test.go b/pkg/stores/proxy/rbac_store_test.go index fa8182c..c14d8cf 100644 --- a/pkg/stores/proxy/rbac_store_test.go +++ b/pkg/stores/proxy/rbac_store_test.go @@ -3,11 +3,11 @@ package proxy import ( "testing" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" "github.com/caas-team/steve/pkg/stores/partition" "github.com/rancher/wrangler/pkg/schemas" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/util/sets" ) diff --git a/pkg/stores/proxy/unformatter.go b/pkg/stores/proxy/unformatter.go index 36b62bb..97bea25 100644 --- a/pkg/stores/proxy/unformatter.go +++ b/pkg/stores/proxy/unformatter.go @@ -1,9 +1,9 @@ package proxy import ( + "github.com/caas-team/apiserver/pkg/types" "github.com/rancher/wrangler/pkg/data" "github.com/rancher/wrangler/pkg/data/convert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" ) // unformatterStore removes fields added by the formatter that kubernetes cannot recognize. diff --git a/pkg/stores/proxy/unformatter_test.go b/pkg/stores/proxy/unformatter_test.go index e56d693..4b67c67 100644 --- a/pkg/stores/proxy/unformatter_test.go +++ b/pkg/stores/proxy/unformatter_test.go @@ -3,8 +3,8 @@ package proxy import ( "testing" + "github.com/caas-team/apiserver/pkg/types" "github.com/stretchr/testify/assert" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" ) func Test_unformat(t *testing.T) { diff --git a/pkg/stores/proxy/watch_refresh.go b/pkg/stores/proxy/watch_refresh.go index b68bb7e..0e58d0e 100644 --- a/pkg/stores/proxy/watch_refresh.go +++ b/pkg/stores/proxy/watch_refresh.go @@ -4,8 +4,8 @@ import ( "context" "time" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/accesscontrol" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apiserver/pkg/endpoints/request" ) diff --git a/pkg/stores/selector/selector.go b/pkg/stores/selector/selector.go index fe7b734..e54cae9 100644 --- a/pkg/stores/selector/selector.go +++ b/pkg/stores/selector/selector.go @@ -1,7 +1,7 @@ package selector import ( - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/types" "k8s.io/apimachinery/pkg/labels" ) diff --git a/pkg/stores/switchschema/store.go b/pkg/stores/switchschema/store.go index 2017d65..4370a0c 100644 --- a/pkg/stores/switchschema/store.go +++ b/pkg/stores/switchschema/store.go @@ -1,7 +1,7 @@ package switchschema import ( - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" + "github.com/caas-team/apiserver/pkg/types" ) type Store struct { diff --git a/pkg/summarycache/summarycache.go b/pkg/summarycache/summarycache.go index a176695..3960e7a 100644 --- a/pkg/summarycache/summarycache.go +++ b/pkg/summarycache/summarycache.go @@ -5,13 +5,13 @@ import ( "strings" "sync" + "github.com/caas-team/apiserver/pkg/types" "github.com/caas-team/steve/pkg/attributes" "github.com/caas-team/steve/pkg/clustercache" "github.com/caas-team/steve/pkg/schema" "github.com/caas-team/steve/pkg/schema/converter" "github.com/rancher/wrangler/pkg/slice" "github.com/rancher/wrangler/pkg/summary" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/types" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" diff --git a/pkg/ui/handler.go b/pkg/ui/handler.go index 49161dd..b25fd06 100644 --- a/pkg/ui/handler.go +++ b/pkg/ui/handler.go @@ -9,8 +9,8 @@ import ( "path/filepath" "sync" + "github.com/caas-team/apiserver/pkg/middleware" "github.com/sirupsen/logrus" - "gitlab.devops.telekom.de/caas/rancher/apiserver/pkg/middleware" ) var (