From 2402296e9aac298b8280bb95a116b4b54d14c1b9 Mon Sep 17 00:00:00 2001 From: Luca Muscariello Date: Fri, 17 Oct 2025 07:43:47 +0200 Subject: [PATCH] fix: migrate to Go module v2 for proper semantic versioning (#3462) * fix: migrate to Go module v2 for proper semantic versioning This change updates the module path from 'zotregistry.dev/zot' to 'zotregistry.dev/zot/v2' to comply with Go's semantic versioning rules. According to Go's module versioning requirements, major version v2+ must include the major version in the module path. The current module path 'zotregistry.dev/zot' only supports v0.x.x and v1.x.x versions, making existing v2.x.x tags (like v2.1.8) unusable. Changes: - Updated go.mod module path to zotregistry.dev/zot/v2 - Updated all internal import paths across 280+ Go source files - Updated configuration files (golangcilint.yaml, gqlgen.yml) - Updated README.md Go reference badge This fix enables proper use of existing v2.x.x Git tags and allows external packages to import zot v2+ versions without compatibility errors. Resolves: Go module import compatibility for v2+ versions Fixes: #3071 Signed-off-by: Luca Muscariello * fix: regenerate GraphQL files with updated v2 import paths The gqlgen tool needs to regenerate the GraphQL schema files after the module path change to use the new v2 imports. Signed-off-by: Luca Muscariello --------- Signed-off-by: Luca Muscariello --- README.md | 2 +- cmd/zb/helper.go | 4 +- cmd/zb/main.go | 4 +- cmd/zb/main_test.go | 4 +- cmd/zb/perf.go | 2 +- cmd/zli/main.go | 2 +- cmd/zli/main_test.go | 6 +- cmd/zot/main.go | 2 +- cmd/zot/main_test.go | 6 +- cmd/zxp/main.go | 2 +- go.mod | 2 +- golangcilint.yaml | 2 +- pkg/api/authn.go | 14 +- pkg/api/authn_test.go | 32 +-- pkg/api/authz.go | 12 +- pkg/api/bearer.go | 2 +- pkg/api/bearer_test.go | 4 +- pkg/api/config/config.go | 6 +- pkg/api/config/config_elevated_test.go | 2 +- pkg/api/config/config_test.go | 6 +- pkg/api/config/redis/redis.go | 4 +- pkg/api/config/redis/redis_test.go | 8 +- pkg/api/controller.go | 26 +- pkg/api/controller_test.go | 44 +-- pkg/api/cookiestore.go | 14 +- pkg/api/errors/errors.go | 2 +- pkg/api/errors/errors_test.go | 2 +- pkg/api/htpasswd.go | 2 +- pkg/api/htpasswd_test.go | 6 +- pkg/api/ldap.go | 4 +- pkg/api/proxy.go | 6 +- pkg/api/proxy_test.go | 2 +- pkg/api/recovery.go | 2 +- pkg/api/routes.go | 36 +-- pkg/api/routes_test.go | 20 +- pkg/api/runtime.go | 2 +- pkg/api/runtime_windows.go | 2 +- pkg/api/session.go | 4 +- pkg/cli/client/client.go | 4 +- pkg/cli/client/client_test.go | 12 +- pkg/cli/client/config_cmd.go | 2 +- pkg/cli/client/config_cmd_test.go | 4 +- pkg/cli/client/cve_cmd_internal_test.go | 12 +- pkg/cli/client/cve_cmd_test.go | 34 +-- pkg/cli/client/cves_sub_cmd.go | 4 +- pkg/cli/client/discover.go | 6 +- pkg/cli/client/elevated_test.go | 10 +- pkg/cli/client/flags.go | 4 +- pkg/cli/client/flags_test.go | 4 +- pkg/cli/client/gql_queries_test.go | 10 +- pkg/cli/client/image_cmd_internal_test.go | 16 +- pkg/cli/client/image_cmd_test.go | 18 +- pkg/cli/client/image_sub_cmd.go | 4 +- pkg/cli/client/repo_test.go | 10 +- pkg/cli/client/root.go | 4 +- pkg/cli/client/root_test.go | 2 +- pkg/cli/client/search_cmd_internal_test.go | 10 +- pkg/cli/client/search_cmd_test.go | 14 +- pkg/cli/client/search_functions.go | 4 +- .../client/search_functions_internal_test.go | 4 +- pkg/cli/client/search_sub_cmd.go | 4 +- pkg/cli/client/server_info_cmd.go | 4 +- pkg/cli/client/server_info_cmd_test.go | 12 +- pkg/cli/client/service.go | 6 +- pkg/cli/client/utils.go | 4 +- pkg/cli/client/utils_internal_test.go | 2 +- pkg/cli/server/config_reloader.go | 6 +- pkg/cli/server/config_reloader_test.go | 4 +- pkg/cli/server/extensions_test.go | 8 +- pkg/cli/server/root.go | 20 +- pkg/cli/server/root_test.go | 12 +- pkg/cli/server/stress_test.go | 8 +- pkg/cli/server/validate_sync_disabled.go | 6 +- pkg/cli/server/validate_sync_enabled.go | 8 +- pkg/cluster/cluster_test.go | 2 +- pkg/common/common_test.go | 4 +- pkg/common/healthz.go | 4 +- pkg/common/http_client_test.go | 4 +- pkg/common/http_server.go | 8 +- pkg/common/oci.go | 2 +- pkg/common/oci_test.go | 2 +- pkg/compat/compat.go | 2 +- pkg/compliance/v1_0_0/check.go | 10 +- pkg/compliance/v1_0_0/check_test.go | 10 +- pkg/debug/gqlplayground/gqlplayground.go | 8 +- .../gqlplayground/gqlplayground_disabled.go | 4 +- pkg/debug/pprof/pprof.go | 10 +- pkg/debug/pprof/pprof_disabled.go | 4 +- pkg/debug/pprof/pprof_test.go | 10 +- pkg/debug/swagger/swagger.go | 6 +- pkg/debug/swagger/swagger_disabled.go | 4 +- pkg/exporter/api/controller.go | 2 +- pkg/exporter/api/controller_test.go | 12 +- pkg/exporter/api/exporter.go | 4 +- pkg/exporter/cli/cli.go | 6 +- pkg/exporter/cli/cli_test.go | 2 +- pkg/extensions/config/config.go | 4 +- pkg/extensions/config/events/decoder.go | 2 +- pkg/extensions/events/builder.go | 2 +- pkg/extensions/events/events.go | 4 +- pkg/extensions/events/events_test.go | 8 +- pkg/extensions/events/extension.go | 4 +- pkg/extensions/events/http_sink.go | 4 +- pkg/extensions/events/http_sink_test.go | 6 +- pkg/extensions/events/nats_sink.go | 4 +- pkg/extensions/events/nats_sink_test.go | 6 +- pkg/extensions/extension_events.go | 10 +- pkg/extensions/extension_events_disabled.go | 8 +- .../extension_events_disabled_test.go | 10 +- pkg/extensions/extension_image_trust.go | 18 +- .../extension_image_trust_disabled.go | 8 +- .../extension_image_trust_disabled_test.go | 8 +- pkg/extensions/extension_image_trust_test.go | 28 +- pkg/extensions/extension_metrics.go | 6 +- pkg/extensions/extension_metrics_disabled.go | 8 +- pkg/extensions/extension_mgmt.go | 8 +- pkg/extensions/extension_mgmt_disabled.go | 4 +- pkg/extensions/extension_scrub.go | 12 +- pkg/extensions/extension_scrub_disabled.go | 8 +- pkg/extensions/extension_search.go | 20 +- pkg/extensions/extension_search_disabled.go | 10 +- pkg/extensions/extension_sync.go | 16 +- pkg/extensions/extension_sync_disabled.go | 12 +- pkg/extensions/extension_ui.go | 6 +- pkg/extensions/extension_ui_disabled.go | 4 +- pkg/extensions/extension_ui_test.go | 12 +- pkg/extensions/extension_userprefs.go | 12 +- pkg/extensions/extension_userprefs_disable.go | 6 +- pkg/extensions/extension_userprefs_test.go | 20 +- pkg/extensions/extensions_lint.go | 6 +- pkg/extensions/extensions_lint_disabled.go | 6 +- pkg/extensions/extensions_test.go | 16 +- pkg/extensions/get_extensions.go | 10 +- .../get_extensions_disabled_test.go | 10 +- pkg/extensions/imagetrust/cosign.go | 2 +- pkg/extensions/imagetrust/image_trust.go | 10 +- .../imagetrust/image_trust_disabled.go | 2 +- .../imagetrust/image_trust_disabled_test.go | 4 +- pkg/extensions/imagetrust/image_trust_test.go | 26 +- pkg/extensions/imagetrust/notation.go | 2 +- pkg/extensions/lint/lint.go | 8 +- pkg/extensions/lint/lint_disabled.go | 2 +- pkg/extensions/lint/lint_test.go | 20 +- pkg/extensions/monitoring/extension.go | 4 +- pkg/extensions/monitoring/minimal.go | 2 +- pkg/extensions/monitoring/minimal_client.go | 2 +- pkg/extensions/monitoring/monitoring_test.go | 20 +- pkg/extensions/scrub/scrub.go | 6 +- pkg/extensions/scrub/scrub_test.go | 24 +- .../search/convert/convert_internal_test.go | 12 +- pkg/extensions/search/convert/convert_test.go | 20 +- pkg/extensions/search/convert/cve.go | 6 +- pkg/extensions/search/convert/metadb.go | 16 +- pkg/extensions/search/convert/oci.go | 4 +- pkg/extensions/search/convert/utils.go | 6 +- pkg/extensions/search/cve/cache/cache.go | 4 +- pkg/extensions/search/cve/cve.go | 16 +- .../search/cve/cve_internal_test.go | 6 +- pkg/extensions/search/cve/cve_test.go | 42 +-- pkg/extensions/search/cve/pagination.go | 6 +- pkg/extensions/search/cve/pagination_test.go | 12 +- pkg/extensions/search/cve/scan.go | 8 +- pkg/extensions/search/cve/scan_test.go | 34 +-- pkg/extensions/search/cve/trivy/scanner.go | 16 +- .../search/cve/trivy/scanner_internal_test.go | 32 +-- .../search/cve/trivy/scanner_test.go | 28 +- pkg/extensions/search/cve/update.go | 4 +- pkg/extensions/search/cve/update_test.go | 18 +- pkg/extensions/search/digest_test.go | 14 +- .../search/gql_generated/generated.go | 266 +++++++++--------- pkg/extensions/search/gqlgen.yml | 2 +- .../search/pagination/image_pagination.go | 6 +- .../search/pagination/pagination_test.go | 4 +- .../search/pagination/repo_pagination.go | 6 +- pkg/extensions/search/resolver.go | 22 +- pkg/extensions/search/resolver_test.go | 30 +- pkg/extensions/search/schema.resolvers.go | 8 +- pkg/extensions/search/search_test.go | 40 +-- pkg/extensions/search/userprefs_test.go | 18 +- pkg/extensions/sync/content.go | 6 +- pkg/extensions/sync/content_test.go | 6 +- pkg/extensions/sync/destination.go | 20 +- pkg/extensions/sync/ecr_credential_helper.go | 4 +- pkg/extensions/sync/oci_layout.go | 8 +- pkg/extensions/sync/on_demand.go | 6 +- pkg/extensions/sync/referrers.go | 2 +- pkg/extensions/sync/remote.go | 6 +- pkg/extensions/sync/service.go | 18 +- pkg/extensions/sync/sync.go | 6 +- pkg/extensions/sync/sync_disabled_test.go | 10 +- pkg/extensions/sync/sync_internal_test.go | 26 +- pkg/extensions/sync/sync_test.go | 36 +-- pkg/extensions/sync/utils.go | 2 +- pkg/log/log.go | 2 +- pkg/log/log_test.go | 10 +- pkg/meta/boltdb/boltdb.go | 22 +- pkg/meta/boltdb/boltdb_test.go | 14 +- pkg/meta/common/common.go | 10 +- pkg/meta/common/common_test.go | 4 +- pkg/meta/convert/convert.go | 8 +- pkg/meta/convert/convert_proto.go | 6 +- pkg/meta/convert/convert_test.go | 4 +- pkg/meta/dynamodb/dynamodb.go | 22 +- pkg/meta/dynamodb/dynamodb_internal_test.go | 6 +- pkg/meta/dynamodb/dynamodb_test.go | 14 +- pkg/meta/dynamodb/iterator.go | 2 +- pkg/meta/hooks.go | 10 +- pkg/meta/hooks_test.go | 16 +- pkg/meta/meta.go | 18 +- pkg/meta/meta_test.go | 36 +-- pkg/meta/parse.go | 14 +- pkg/meta/parse_test.go | 36 +-- pkg/meta/redis/redis.go | 22 +- pkg/meta/redis/redis_internal_test.go | 2 +- pkg/meta/redis/redis_test.go | 14 +- pkg/meta/version/version_test.go | 12 +- pkg/requestcontext/authn.go | 2 +- pkg/requestcontext/user_access_control.go | 4 +- pkg/retention/candidate.go | 4 +- pkg/retention/retention.go | 12 +- pkg/retention/rules.go | 2 +- pkg/retention/types/types.go | 2 +- pkg/scheduler/scheduler.go | 6 +- pkg/scheduler/scheduler_test.go | 8 +- pkg/storage/cache.go | 14 +- pkg/storage/cache/boltdb.go | 6 +- pkg/storage/cache/boltdb_internal_test.go | 4 +- pkg/storage/cache/boltdb_test.go | 8 +- pkg/storage/cache/dynamodb.go | 4 +- pkg/storage/cache/dynamodb_test.go | 8 +- pkg/storage/cache/redis.go | 6 +- pkg/storage/cache/redis_test.go | 12 +- pkg/storage/cache_benchmark_test.go | 10 +- pkg/storage/cache_test.go | 8 +- pkg/storage/common/common.go | 16 +- pkg/storage/common/common_test.go | 20 +- pkg/storage/common/lint_interface.go | 2 +- pkg/storage/gc/gc.go | 24 +- pkg/storage/gc/gc_internal_test.go | 24 +- pkg/storage/gc/gc_test.go | 32 +-- pkg/storage/imagestore/imagestore.go | 26 +- pkg/storage/local/driver.go | 6 +- pkg/storage/local/driver_test.go | 6 +- pkg/storage/local/local.go | 14 +- pkg/storage/local/local_elevated_test.go | 10 +- pkg/storage/local/local_test.go | 30 +- pkg/storage/s3/driver.go | 2 +- pkg/storage/s3/s3.go | 14 +- pkg/storage/s3/s3_test.go | 30 +- pkg/storage/scrub.go | 6 +- pkg/storage/scrub_test.go | 26 +- pkg/storage/storage.go | 22 +- pkg/storage/storage_controller.go | 2 +- pkg/storage/storage_test.go | 34 +-- pkg/storage/types/types.go | 2 +- pkg/test/auth/bearer.go | 2 +- pkg/test/auth/bearer_test.go | 2 +- pkg/test/common/fs_test.go | 2 +- pkg/test/common/utils_test.go | 6 +- pkg/test/image-utils/images.go | 6 +- pkg/test/image-utils/images_test.go | 4 +- pkg/test/image-utils/multiarch.go | 2 +- pkg/test/image-utils/upload.go | 4 +- pkg/test/image-utils/upload_test.go | 10 +- pkg/test/image-utils/utils.go | 2 +- pkg/test/image-utils/write.go | 2 +- pkg/test/image-utils/write_test.go | 6 +- pkg/test/inject/dev.go | 4 +- pkg/test/inject/inject_test.go | 2 +- pkg/test/mocks/cve_mock.go | 4 +- pkg/test/mocks/image_store_mock.go | 4 +- pkg/test/mocks/lint_mock.go | 2 +- pkg/test/mocks/oci_mock.go | 4 +- pkg/test/mocks/repo_db_mock.go | 2 +- pkg/test/oci-utils/oci_layout.go | 12 +- pkg/test/oci-utils/oci_layout_test.go | 28 +- pkg/test/oci-utils/repo.go | 8 +- pkg/test/oci-utils/repo_test.go | 8 +- pkg/test/oci-utils/store.go | 12 +- pkg/test/signature/notation.go | 2 +- pkg/test/signature/notation_test.go | 10 +- pkg/test/skip/skip_test.go | 2 +- swagger/docs_test.go | 2 +- 283 files changed, 1493 insertions(+), 1493 deletions(-) diff --git a/README.md b/README.md index 4014eba8..12fbb22e 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # zot -[![build](https://github.com/project-zot/zot/actions/workflows/build.yaml/badge.svg?branch=main)](https://github.com/project-zot/zot/actions/workflows/build.yaml) [![test](https://github.com/project-zot/zot/actions/workflows/test.yaml/badge.svg?branch=main)](https://github.com/project-zot/zot/actions/workflows/test.yaml) [![nightly jobs](https://github.com/project-zot/zot/actions/workflows/nightly.yaml/badge.svg)](https://github.com/project-zot/zot/actions/workflows/nightly.yaml) [![codecov](https://codecov.io/gh/project-zot/zot/branch/main/graph/badge.svg?token=US6rAoFYoc)](https://codecov.io/gh/project-zot/zot) [![conformance](https://github.com/project-zot/zot/actions/workflows/oci-conformance-action.yaml/badge.svg)](https://github.com/project-zot/zot/actions/workflows/oci-conformance-action.yaml) [![CodeQL](https://github.com/project-zot/zot/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/project-zot/zot/actions/workflows/codeql-analysis.yml) [![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/5425/badge)](https://bestpractices.coreinfrastructure.org/projects/5425) [![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/project-zot/zot/badge)](https://securityscorecards.dev/viewer/?uri=github.com/project-zot/zot) [![Go Reference](https://pkg.go.dev/badge/zotregistry.dev/zot.svg)](https://pkg.go.dev/zotregistry.dev/zot) [![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fproject-zot%2Fzot.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fproject-zot%2Fzot?ref=badge_shield) +[![build](https://github.com/project-zot/zot/actions/workflows/build.yaml/badge.svg?branch=main)](https://github.com/project-zot/zot/actions/workflows/build.yaml) [![test](https://github.com/project-zot/zot/actions/workflows/test.yaml/badge.svg?branch=main)](https://github.com/project-zot/zot/actions/workflows/test.yaml) [![nightly jobs](https://github.com/project-zot/zot/actions/workflows/nightly.yaml/badge.svg)](https://github.com/project-zot/zot/actions/workflows/nightly.yaml) [![codecov](https://codecov.io/gh/project-zot/zot/branch/main/graph/badge.svg?token=US6rAoFYoc)](https://codecov.io/gh/project-zot/zot) [![conformance](https://github.com/project-zot/zot/actions/workflows/oci-conformance-action.yaml/badge.svg)](https://github.com/project-zot/zot/actions/workflows/oci-conformance-action.yaml) [![CodeQL](https://github.com/project-zot/zot/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/project-zot/zot/actions/workflows/codeql-analysis.yml) [![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/5425/badge)](https://bestpractices.coreinfrastructure.org/projects/5425) [![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/project-zot/zot/badge)](https://securityscorecards.dev/viewer/?uri=github.com/project-zot/zot) [![Go Reference](https://pkg.go.dev/badge/zotregistry.dev/zot/v2.svg)](https://pkg.go.dev/zotregistry.dev/zot/v2) [![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fproject-zot%2Fzot.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fproject-zot%2Fzot?ref=badge_shield) **zot**: a production-ready vendor-neutral OCI image registry - images stored in [OCI image format](https://github.com/opencontainers/image-spec), [distribution specification](https://github.com/opencontainers/distribution-spec) on-the-wire, that's it! diff --git a/cmd/zb/helper.go b/cmd/zb/helper.go index 4941f56f..bc8f6b5d 100644 --- a/cmd/zb/helper.go +++ b/cmd/zb/helper.go @@ -21,8 +21,8 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" ) func makeHTTPGetRequest(url string, resultPtr interface{}, client *resty.Client) (http.Header, error) { diff --git a/cmd/zb/main.go b/cmd/zb/main.go index e10eff14..ca69e96d 100644 --- a/cmd/zb/main.go +++ b/cmd/zb/main.go @@ -6,8 +6,8 @@ import ( distspec "github.com/opencontainers/distribution-spec/specs-go" "github.com/spf13/cobra" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" ) // "zb" - performance benchmark and stress. diff --git a/cmd/zb/main_test.go b/cmd/zb/main_test.go index bcf1f580..5a7dd6d6 100644 --- a/cmd/zb/main_test.go +++ b/cmd/zb/main_test.go @@ -5,8 +5,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" ) func TestIntegration(t *testing.T) { diff --git a/cmd/zb/perf.go b/cmd/zb/perf.go index 4d9c0fa3..08633c08 100644 --- a/cmd/zb/perf.go +++ b/cmd/zb/perf.go @@ -21,7 +21,7 @@ import ( godigest "github.com/opencontainers/go-digest" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/api/constants" ) const ( diff --git a/cmd/zli/main.go b/cmd/zli/main.go index 822c992c..1a633d1b 100644 --- a/cmd/zli/main.go +++ b/cmd/zli/main.go @@ -6,7 +6,7 @@ package main import ( "os" - cli "zotregistry.dev/zot/pkg/cli/client" + cli "zotregistry.dev/zot/v2/pkg/cli/client" ) func main() { diff --git a/cmd/zli/main_test.go b/cmd/zli/main_test.go index 4b31b09c..a38bd515 100644 --- a/cmd/zli/main_test.go +++ b/cmd/zli/main_test.go @@ -8,9 +8,9 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - cli "zotregistry.dev/zot/pkg/cli/client" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + cli "zotregistry.dev/zot/v2/pkg/cli/client" ) func TestIntegration(t *testing.T) { diff --git a/cmd/zot/main.go b/cmd/zot/main.go index 543aa9f4..09f27c6b 100644 --- a/cmd/zot/main.go +++ b/cmd/zot/main.go @@ -3,7 +3,7 @@ package main import ( "os" - cli "zotregistry.dev/zot/pkg/cli/server" + cli "zotregistry.dev/zot/v2/pkg/cli/server" ) func main() { diff --git a/cmd/zot/main_test.go b/cmd/zot/main_test.go index dccca8f3..1c764f2b 100644 --- a/cmd/zot/main_test.go +++ b/cmd/zot/main_test.go @@ -5,9 +5,9 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - cli "zotregistry.dev/zot/pkg/cli/server" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + cli "zotregistry.dev/zot/v2/pkg/cli/server" ) func TestIntegration(t *testing.T) { diff --git a/cmd/zxp/main.go b/cmd/zxp/main.go index cd499085..e14940aa 100644 --- a/cmd/zxp/main.go +++ b/cmd/zxp/main.go @@ -6,7 +6,7 @@ package main import ( "os" - "zotregistry.dev/zot/pkg/exporter/cli" + "zotregistry.dev/zot/v2/pkg/exporter/cli" ) func main() { diff --git a/go.mod b/go.mod index eee791c6..74e91f05 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module zotregistry.dev/zot +module zotregistry.dev/zot/v2 go 1.24.4 diff --git a/golangcilint.yaml b/golangcilint.yaml index 31b43081..5ba1a568 100644 --- a/golangcilint.yaml +++ b/golangcilint.yaml @@ -105,7 +105,7 @@ formatters: sections: - standard - default - - prefix(zotregistry.dev/zot) + - prefix(zotregistry.dev/zot/v2) exclusions: generated: lax paths: diff --git a/pkg/api/authn.go b/pkg/api/authn.go index a36b9244..7a6c7aed 100644 --- a/pkg/api/authn.go +++ b/pkg/api/authn.go @@ -29,13 +29,13 @@ import ( "golang.org/x/oauth2" githubOAuth "golang.org/x/oauth2/github" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - apiErr "zotregistry.dev/zot/pkg/api/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + apiErr "zotregistry.dev/zot/v2/pkg/api/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" ) const ( diff --git a/pkg/api/authn_test.go b/pkg/api/authn_test.go index 376883f7..43702a60 100644 --- a/pkg/api/authn_test.go +++ b/pkg/api/authn_test.go @@ -22,22 +22,22 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/local" - authutils "zotregistry.dev/zot/pkg/test/auth" - test "zotregistry.dev/zot/pkg/test/common" - "zotregistry.dev/zot/pkg/test/mocks" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/local" + authutils "zotregistry.dev/zot/v2/pkg/test/auth" + test "zotregistry.dev/zot/v2/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrUnexpectedError = errors.New("error: unexpected error") diff --git a/pkg/api/authz.go b/pkg/api/authz.go index c41e0edc..81292664 100644 --- a/pkg/api/authz.go +++ b/pkg/api/authz.go @@ -7,12 +7,12 @@ import ( glob "github.com/bmatcuk/doublestar/v4" "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) const ( diff --git a/pkg/api/bearer.go b/pkg/api/bearer.go index 861654c0..824459f1 100644 --- a/pkg/api/bearer.go +++ b/pkg/api/bearer.go @@ -8,7 +8,7 @@ import ( "github.com/golang-jwt/jwt/v5" - zerr "zotregistry.dev/zot/errors" + zerr "zotregistry.dev/zot/v2/errors" ) var bearerTokenMatch = regexp.MustCompile("(?i)bearer (.*)") diff --git a/pkg/api/bearer_test.go b/pkg/api/bearer_test.go index 69d62d9e..12237635 100644 --- a/pkg/api/bearer_test.go +++ b/pkg/api/bearer_test.go @@ -9,8 +9,8 @@ import ( "github.com/golang-jwt/jwt/v5" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" ) func TestBearerAuthorizer(t *testing.T) { diff --git a/pkg/api/config/config.go b/pkg/api/config/config.go index 9b0efc7c..c5c9f360 100644 --- a/pkg/api/config/config.go +++ b/pkg/api/config/config.go @@ -7,9 +7,9 @@ import ( distspec "github.com/opencontainers/distribution-spec/specs-go" - "zotregistry.dev/zot/pkg/compat" - extconf "zotregistry.dev/zot/pkg/extensions/config" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/compat" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" ) var ( diff --git a/pkg/api/config/config_elevated_test.go b/pkg/api/config/config_elevated_test.go index 32ebee5b..e437cf24 100644 --- a/pkg/api/config/config_elevated_test.go +++ b/pkg/api/config/config_elevated_test.go @@ -9,7 +9,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/config" ) func TestMountConfig(t *testing.T) { diff --git a/pkg/api/config/config_test.go b/pkg/api/config/config_test.go index 5701ccda..8eaaabd6 100644 --- a/pkg/api/config/config_test.go +++ b/pkg/api/config/config_test.go @@ -6,9 +6,9 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/config/events" ) func TestConfig(t *testing.T) { diff --git a/pkg/api/config/redis/redis.go b/pkg/api/config/redis/redis.go index 47dd2142..f185c90f 100644 --- a/pkg/api/config/redis/redis.go +++ b/pkg/api/config/redis/redis.go @@ -10,8 +10,8 @@ import ( "github.com/redis/go-redis/v9" "github.com/spf13/cast" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" ) var once sync.Once //nolint: gochecknoglobals // redis.SetLogger modifies an unprotected global variable diff --git a/pkg/api/config/redis/redis_test.go b/pkg/api/config/redis/redis_test.go index 3267950c..ff57b765 100644 --- a/pkg/api/config/redis/redis_test.go +++ b/pkg/api/config/redis/redis_test.go @@ -11,10 +11,10 @@ import ( "github.com/redis/go-redis/v9" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api/config" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - "zotregistry.dev/zot/pkg/cli/server" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + "zotregistry.dev/zot/v2/pkg/cli/server" + "zotregistry.dev/zot/v2/pkg/log" ) func TestRedisLogger(t *testing.T) { diff --git a/pkg/api/controller.go b/pkg/api/controller.go index 46abe4f5..93df422e 100644 --- a/pkg/api/controller.go +++ b/pkg/api/controller.go @@ -18,19 +18,19 @@ import ( "github.com/gorilla/securecookie" "github.com/zitadel/oidc/v3/pkg/client/rp" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/common" - ext "zotregistry.dev/zot/pkg/extensions" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/gc" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/common" + ext "zotregistry.dev/zot/v2/pkg/extensions" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/gc" ) const ( diff --git a/pkg/api/controller_test.go b/pkg/api/controller_test.go index e5fedb99..cef57cc5 100644 --- a/pkg/api/controller_test.go +++ b/pkg/api/controller_test.go @@ -50,28 +50,28 @@ import ( "go.etcd.io/bbolt" "gopkg.in/resty.v1" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - apiErr "zotregistry.dev/zot/pkg/api/errors" - "zotregistry.dev/zot/pkg/cli/server" - "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/storage" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/gc" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - authutils "zotregistry.dev/zot/pkg/test/auth" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/inject" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" - "zotregistry.dev/zot/pkg/test/signature" - tskip "zotregistry.dev/zot/pkg/test/skip" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + apiErr "zotregistry.dev/zot/v2/pkg/api/errors" + "zotregistry.dev/zot/v2/pkg/cli/server" + "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/storage" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/gc" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + authutils "zotregistry.dev/zot/v2/pkg/test/auth" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/inject" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) const ( diff --git a/pkg/api/cookiestore.go b/pkg/api/cookiestore.go index e80345fb..4b312af4 100644 --- a/pkg/api/cookiestore.go +++ b/pkg/api/cookiestore.go @@ -14,13 +14,13 @@ import ( "github.com/gorilla/sessions" "github.com/rbcervilla/redisstore/v9" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" ) const cookiesMaxAge = 7200 // 2h diff --git a/pkg/api/errors/errors.go b/pkg/api/errors/errors.go index ca286e9c..bf80eb11 100644 --- a/pkg/api/errors/errors.go +++ b/pkg/api/errors/errors.go @@ -1,7 +1,7 @@ package errors import ( - "zotregistry.dev/zot/errors" + "zotregistry.dev/zot/v2/errors" ) type Error struct { diff --git a/pkg/api/errors/errors_test.go b/pkg/api/errors/errors_test.go index da938682..5a5d078d 100644 --- a/pkg/api/errors/errors_test.go +++ b/pkg/api/errors/errors_test.go @@ -5,7 +5,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - apiErr "zotregistry.dev/zot/pkg/api/errors" + apiErr "zotregistry.dev/zot/v2/pkg/api/errors" ) func TestUnknownCodeError(t *testing.T) { diff --git a/pkg/api/htpasswd.go b/pkg/api/htpasswd.go index 0c3032a8..6a6a6236 100644 --- a/pkg/api/htpasswd.go +++ b/pkg/api/htpasswd.go @@ -13,7 +13,7 @@ import ( "github.com/fsnotify/fsnotify" "golang.org/x/crypto/bcrypt" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) // HTPasswd user auth store diff --git a/pkg/api/htpasswd_test.go b/pkg/api/htpasswd_test.go index be787ff7..f37bd2ff 100644 --- a/pkg/api/htpasswd_test.go +++ b/pkg/api/htpasswd_test.go @@ -7,9 +7,9 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/log" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/log" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestHTPasswdWatcher(t *testing.T) { diff --git a/pkg/api/ldap.go b/pkg/api/ldap.go index 9eb1e2d6..18438fc5 100644 --- a/pkg/api/ldap.go +++ b/pkg/api/ldap.go @@ -11,8 +11,8 @@ import ( "github.com/go-ldap/ldap/v3" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" ) type LDAPClient struct { diff --git a/pkg/api/proxy.go b/pkg/api/proxy.go index 96d35bfb..407231ab 100644 --- a/pkg/api/proxy.go +++ b/pkg/api/proxy.go @@ -10,9 +10,9 @@ import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/cluster" - "zotregistry.dev/zot/pkg/common" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/cluster" + "zotregistry.dev/zot/v2/pkg/common" ) // ClusterProxy wraps an http.HandlerFunc which requires proxying between zot instances to ensure diff --git a/pkg/api/proxy_test.go b/pkg/api/proxy_test.go index f11daede..c0a75743 100644 --- a/pkg/api/proxy_test.go +++ b/pkg/api/proxy_test.go @@ -8,7 +8,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" + "zotregistry.dev/zot/v2/pkg/api" ) func TestGetLocalMemberClusterSocket(t *testing.T) { diff --git a/pkg/api/recovery.go b/pkg/api/recovery.go index 3f2aceb8..55889cf8 100644 --- a/pkg/api/recovery.go +++ b/pkg/api/recovery.go @@ -7,7 +7,7 @@ import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) type Stack struct { diff --git a/pkg/api/routes.go b/pkg/api/routes.go index f115362f..a0d24ad8 100644 --- a/pkg/api/routes.go +++ b/pkg/api/routes.go @@ -33,24 +33,24 @@ import ( "github.com/zitadel/oidc/v3/pkg/client/rp" "github.com/zitadel/oidc/v3/pkg/oidc" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - apiErr "zotregistry.dev/zot/pkg/api/errors" - zcommon "zotregistry.dev/zot/pkg/common" - gqlPlayground "zotregistry.dev/zot/pkg/debug/gqlplayground" - "zotregistry.dev/zot/pkg/debug/pprof" - debug "zotregistry.dev/zot/pkg/debug/swagger" - ext "zotregistry.dev/zot/pkg/extensions" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - mTypes "zotregistry.dev/zot/pkg/meta/types" - zreg "zotregistry.dev/zot/pkg/regexp" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - "zotregistry.dev/zot/pkg/storage" - storageCommon "zotregistry.dev/zot/pkg/storage/common" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - "zotregistry.dev/zot/pkg/test/inject" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + apiErr "zotregistry.dev/zot/v2/pkg/api/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + gqlPlayground "zotregistry.dev/zot/v2/pkg/debug/gqlplayground" + "zotregistry.dev/zot/v2/pkg/debug/pprof" + debug "zotregistry.dev/zot/v2/pkg/debug/swagger" + ext "zotregistry.dev/zot/v2/pkg/extensions" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + zreg "zotregistry.dev/zot/v2/pkg/regexp" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + "zotregistry.dev/zot/v2/pkg/storage" + storageCommon "zotregistry.dev/zot/v2/pkg/storage/common" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/test/inject" ) type RouteHandler struct { diff --git a/pkg/api/routes_test.go b/pkg/api/routes_test.go index 96c97627..60d5d5f4 100644 --- a/pkg/api/routes_test.go +++ b/pkg/api/routes_test.go @@ -23,16 +23,16 @@ import ( "github.com/zitadel/oidc/v3/pkg/oidc" "golang.org/x/oauth2" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - test "zotregistry.dev/zot/pkg/test/common" - "zotregistry.dev/zot/pkg/test/mocks" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + test "zotregistry.dev/zot/v2/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) const sessionStr = "session" diff --git a/pkg/api/runtime.go b/pkg/api/runtime.go index e2c9023f..92577e34 100644 --- a/pkg/api/runtime.go +++ b/pkg/api/runtime.go @@ -9,7 +9,7 @@ import ( "strings" "syscall" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) // DumpRuntimeParams dumps important runtime state such as file and socket limits. diff --git a/pkg/api/runtime_windows.go b/pkg/api/runtime_windows.go index 6b7d67dd..51325cc0 100644 --- a/pkg/api/runtime_windows.go +++ b/pkg/api/runtime_windows.go @@ -8,7 +8,7 @@ import ( "syscall" "unsafe" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) func getCurrentHandleCount() (uint32, error) { diff --git a/pkg/api/session.go b/pkg/api/session.go index fdb3e6c9..b99ae39c 100644 --- a/pkg/api/session.go +++ b/pkg/api/session.go @@ -10,8 +10,8 @@ import ( "github.com/didip/tollbooth/v7" "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" ) type statusWriter struct { diff --git a/pkg/cli/client/client.go b/pkg/cli/client/client.go index 56a674a5..0a88f863 100644 --- a/pkg/cli/client/client.go +++ b/pkg/cli/client/client.go @@ -19,8 +19,8 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/sigstore/cosign/v2/pkg/oci/remote" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" ) var ( diff --git a/pkg/cli/client/client_test.go b/pkg/cli/client/client_test.go index 89da85c6..7beefd8c 100644 --- a/pkg/cli/client/client_test.go +++ b/pkg/cli/client/client_test.go @@ -16,12 +16,12 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/cli/client" - extConf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/cli/client" + extConf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" ) const ( diff --git a/pkg/cli/client/config_cmd.go b/pkg/cli/client/config_cmd.go index a53f61d1..91e503d2 100644 --- a/pkg/cli/client/config_cmd.go +++ b/pkg/cli/client/config_cmd.go @@ -15,7 +15,7 @@ import ( jsoniter "github.com/json-iterator/go" "github.com/spf13/cobra" - zerr "zotregistry.dev/zot/errors" + zerr "zotregistry.dev/zot/v2/errors" ) const ( diff --git a/pkg/cli/client/config_cmd_test.go b/pkg/cli/client/config_cmd_test.go index f4825c0a..371c2ea4 100644 --- a/pkg/cli/client/config_cmd_test.go +++ b/pkg/cli/client/config_cmd_test.go @@ -13,8 +13,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/cli/client" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/cli/client" ) func TestConfigCmdBasics(t *testing.T) { diff --git a/pkg/cli/client/cve_cmd_internal_test.go b/pkg/cli/client/cve_cmd_internal_test.go index 6f365941..238f5b5b 100644 --- a/pkg/cli/client/cve_cmd_internal_test.go +++ b/pkg/cli/client/cve_cmd_internal_test.go @@ -16,12 +16,12 @@ import ( . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestSearchCVECmd(t *testing.T) { diff --git a/pkg/cli/client/cve_cmd_test.go b/pkg/cli/client/cve_cmd_test.go index cfa52fd3..8abc53ad 100644 --- a/pkg/cli/client/cve_cmd_test.go +++ b/pkg/cli/client/cve_cmd_test.go @@ -22,23 +22,23 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/cli/client" - zcommon "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/cli/client" + zcommon "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) func TestNegativeServerResponse(t *testing.T) { diff --git a/pkg/cli/client/cves_sub_cmd.go b/pkg/cli/client/cves_sub_cmd.go index 171d0dd1..7577776d 100644 --- a/pkg/cli/client/cves_sub_cmd.go +++ b/pkg/cli/client/cves_sub_cmd.go @@ -9,8 +9,8 @@ import ( "github.com/spf13/cobra" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" ) const ( diff --git a/pkg/cli/client/discover.go b/pkg/cli/client/discover.go index 21be4925..08ed4398 100644 --- a/pkg/cli/client/discover.go +++ b/pkg/cli/client/discover.go @@ -9,9 +9,9 @@ import ( distext "github.com/opencontainers/distribution-spec/specs-go/v1/extensions" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" ) type field struct { diff --git a/pkg/cli/client/elevated_test.go b/pkg/cli/client/elevated_test.go index e9ef3395..be4fe442 100644 --- a/pkg/cli/client/elevated_test.go +++ b/pkg/cli/client/elevated_test.go @@ -16,11 +16,11 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/cli/client" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/cli/client" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestElevatedPrivilegesTLSNewControllerPrivilegedCert(t *testing.T) { diff --git a/pkg/cli/client/flags.go b/pkg/cli/client/flags.go index 639aa121..fd204d43 100644 --- a/pkg/cli/client/flags.go +++ b/pkg/cli/client/flags.go @@ -7,8 +7,8 @@ import ( "fmt" "strings" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" ) const ( diff --git a/pkg/cli/client/flags_test.go b/pkg/cli/client/flags_test.go index 1fe80b16..356d5ec7 100644 --- a/pkg/cli/client/flags_test.go +++ b/pkg/cli/client/flags_test.go @@ -8,8 +8,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - . "zotregistry.dev/zot/pkg/cli/client" - gql_gen "zotregistry.dev/zot/pkg/extensions/search/gql_generated" + . "zotregistry.dev/zot/v2/pkg/cli/client" + gql_gen "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" ) func TestSortFlagsMapping(t *testing.T) { diff --git a/pkg/cli/client/gql_queries_test.go b/pkg/cli/client/gql_queries_test.go index bce94150..c727665f 100644 --- a/pkg/cli/client/gql_queries_test.go +++ b/pkg/cli/client/gql_queries_test.go @@ -9,11 +9,11 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/cli/client" - extconf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/cli/client" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestGQLQueries(t *testing.T) { diff --git a/pkg/cli/client/image_cmd_internal_test.go b/pkg/cli/client/image_cmd_internal_test.go index f4ec4228..90c20a91 100644 --- a/pkg/cli/client/image_cmd_internal_test.go +++ b/pkg/cli/client/image_cmd_internal_test.go @@ -22,14 +22,14 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - stypes "zotregistry.dev/zot/pkg/storage/types" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + stypes "zotregistry.dev/zot/v2/pkg/storage/types" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) func TestSearchImageCmd(t *testing.T) { diff --git a/pkg/cli/client/image_cmd_test.go b/pkg/cli/client/image_cmd_test.go index 5f84c834..e1e4cb2e 100644 --- a/pkg/cli/client/image_cmd_test.go +++ b/pkg/cli/client/image_cmd_test.go @@ -24,15 +24,15 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/cli/client" - extconf "zotregistry.dev/zot/pkg/extensions/config" - zlog "zotregistry.dev/zot/pkg/log" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" - "zotregistry.dev/zot/pkg/test/signature" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/cli/client" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + zlog "zotregistry.dev/zot/v2/pkg/log" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" ) //nolint:dupl diff --git a/pkg/cli/client/image_sub_cmd.go b/pkg/cli/client/image_sub_cmd.go index 9b1202e7..88fb5950 100644 --- a/pkg/cli/client/image_sub_cmd.go +++ b/pkg/cli/client/image_sub_cmd.go @@ -8,8 +8,8 @@ import ( "github.com/spf13/cobra" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" ) func NewImageListCommand(searchService SearchService) *cobra.Command { diff --git a/pkg/cli/client/repo_test.go b/pkg/cli/client/repo_test.go index 908de7fe..568c1a7e 100644 --- a/pkg/cli/client/repo_test.go +++ b/pkg/cli/client/repo_test.go @@ -13,11 +13,11 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/cli/client" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/cli/client" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) func TestReposCommand(t *testing.T) { diff --git a/pkg/cli/client/root.go b/pkg/cli/client/root.go index dd75ae7f..d70792cb 100644 --- a/pkg/cli/client/root.go +++ b/pkg/cli/client/root.go @@ -7,8 +7,8 @@ import ( distspec "github.com/opencontainers/distribution-spec/specs-go" "github.com/spf13/cobra" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" ) // "zli" - client-side cli. diff --git a/pkg/cli/client/root_test.go b/pkg/cli/client/root_test.go index f7a0a1e1..aee303cc 100644 --- a/pkg/cli/client/root_test.go +++ b/pkg/cli/client/root_test.go @@ -9,7 +9,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/cli/client" + "zotregistry.dev/zot/v2/pkg/cli/client" ) func TestCliUsage(t *testing.T) { diff --git a/pkg/cli/client/search_cmd_internal_test.go b/pkg/cli/client/search_cmd_internal_test.go index 5cc628df..69502ea5 100644 --- a/pkg/cli/client/search_cmd_internal_test.go +++ b/pkg/cli/client/search_cmd_internal_test.go @@ -13,11 +13,11 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) func TestSearchCommandGQL(t *testing.T) { diff --git a/pkg/cli/client/search_cmd_test.go b/pkg/cli/client/search_cmd_test.go index 73608cfe..a322cb9a 100644 --- a/pkg/cli/client/search_cmd_test.go +++ b/pkg/cli/client/search_cmd_test.go @@ -15,13 +15,13 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/cli/client" - extconf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/cli/client" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) const ( diff --git a/pkg/cli/client/search_functions.go b/pkg/cli/client/search_functions.go index 5b9c55fc..e9f116ab 100644 --- a/pkg/cli/client/search_functions.go +++ b/pkg/cli/client/search_functions.go @@ -11,8 +11,8 @@ import ( "sync" "time" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" ) const CveDBRetryInterval = 3 diff --git a/pkg/cli/client/search_functions_internal_test.go b/pkg/cli/client/search_functions_internal_test.go index 97f5e163..196a7b1b 100644 --- a/pkg/cli/client/search_functions_internal_test.go +++ b/pkg/cli/client/search_functions_internal_test.go @@ -21,8 +21,8 @@ import ( . "github.com/smartystreets/goconvey/convey" "github.com/spf13/cobra" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" ) func TestSearchAllImages(t *testing.T) { diff --git a/pkg/cli/client/search_sub_cmd.go b/pkg/cli/client/search_sub_cmd.go index a94a5f03..dc31c6da 100644 --- a/pkg/cli/client/search_sub_cmd.go +++ b/pkg/cli/client/search_sub_cmd.go @@ -8,8 +8,8 @@ import ( "github.com/spf13/cobra" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" ) func NewSearchSubjectCommand(searchService SearchService) *cobra.Command { diff --git a/pkg/cli/client/server_info_cmd.go b/pkg/cli/client/server_info_cmd.go index a25bf8fd..d9967332 100644 --- a/pkg/cli/client/server_info_cmd.go +++ b/pkg/cli/client/server_info_cmd.go @@ -13,8 +13,8 @@ import ( "github.com/spf13/cobra" "gopkg.in/yaml.v3" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" ) const ( diff --git a/pkg/cli/client/server_info_cmd_test.go b/pkg/cli/client/server_info_cmd_test.go index 607bdf53..3307082b 100644 --- a/pkg/cli/client/server_info_cmd_test.go +++ b/pkg/cli/client/server_info_cmd_test.go @@ -14,12 +14,12 @@ import ( . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - extconf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestServerStatusCommand(t *testing.T) { diff --git a/pkg/cli/client/service.go b/pkg/cli/client/service.go index 830fb87d..3f6112eb 100644 --- a/pkg/cli/client/service.go +++ b/pkg/cli/client/service.go @@ -21,9 +21,9 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "gopkg.in/yaml.v3" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/common" ) const ( diff --git a/pkg/cli/client/utils.go b/pkg/cli/client/utils.go index 2cfc1053..394f05c3 100644 --- a/pkg/cli/client/utils.go +++ b/pkg/cli/client/utils.go @@ -18,8 +18,8 @@ import ( "github.com/olekukonko/tablewriter/tw" "github.com/spf13/cobra" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" ) const ( diff --git a/pkg/cli/client/utils_internal_test.go b/pkg/cli/client/utils_internal_test.go index 3144c36b..61c5378f 100644 --- a/pkg/cli/client/utils_internal_test.go +++ b/pkg/cli/client/utils_internal_test.go @@ -17,7 +17,7 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - test "zotregistry.dev/zot/pkg/test/common" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func getDefaultSearchConf(baseURL string) SearchConfig { diff --git a/pkg/cli/server/config_reloader.go b/pkg/cli/server/config_reloader.go index 55691021..3ddb9aed 100644 --- a/pkg/cli/server/config_reloader.go +++ b/pkg/cli/server/config_reloader.go @@ -8,9 +8,9 @@ import ( "github.com/fsnotify/fsnotify" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" ) type HotReloader struct { diff --git a/pkg/cli/server/config_reloader_test.go b/pkg/cli/server/config_reloader_test.go index ec49cea0..5de632e5 100644 --- a/pkg/cli/server/config_reloader_test.go +++ b/pkg/cli/server/config_reloader_test.go @@ -12,8 +12,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - cli "zotregistry.dev/zot/pkg/cli/server" - test "zotregistry.dev/zot/pkg/test/common" + cli "zotregistry.dev/zot/v2/pkg/cli/server" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestConfigReloader(t *testing.T) { diff --git a/pkg/cli/server/extensions_test.go b/pkg/cli/server/extensions_test.go index 6e41d7cd..385a9107 100644 --- a/pkg/cli/server/extensions_test.go +++ b/pkg/cli/server/extensions_test.go @@ -13,10 +13,10 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - cli "zotregistry.dev/zot/pkg/cli/server" - . "zotregistry.dev/zot/pkg/test/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + cli "zotregistry.dev/zot/v2/pkg/cli/server" + . "zotregistry.dev/zot/v2/pkg/test/common" ) const readLogFileTimeout = 5 * time.Second diff --git a/pkg/cli/server/root.go b/pkg/cli/server/root.go index a1d1e7ef..23263b33 100644 --- a/pkg/cli/server/root.go +++ b/pkg/cli/server/root.go @@ -20,16 +20,16 @@ import ( "github.com/spf13/cobra" "github.com/spf13/viper" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" ) // metadataConfig reports metadata after parsing, which we use to track diff --git a/pkg/cli/server/root_test.go b/pkg/cli/server/root_test.go index f49d8562..9b41106f 100644 --- a/pkg/cli/server/root_test.go +++ b/pkg/cli/server/root_test.go @@ -11,12 +11,12 @@ import ( . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - cli "zotregistry.dev/zot/pkg/cli/server" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - . "zotregistry.dev/zot/pkg/test/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + cli "zotregistry.dev/zot/v2/pkg/cli/server" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + . "zotregistry.dev/zot/v2/pkg/test/common" ) func TestServerUsage(t *testing.T) { diff --git a/pkg/cli/server/stress_test.go b/pkg/cli/server/stress_test.go index 6a13dc30..79c2c4df 100644 --- a/pkg/cli/server/stress_test.go +++ b/pkg/cli/server/stress_test.go @@ -14,10 +14,10 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - cli "zotregistry.dev/zot/pkg/cli/server" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + cli "zotregistry.dev/zot/v2/pkg/cli/server" + test "zotregistry.dev/zot/v2/pkg/test/common" ) const ( diff --git a/pkg/cli/server/validate_sync_disabled.go b/pkg/cli/server/validate_sync_disabled.go index ef791c7f..8c5da849 100644 --- a/pkg/cli/server/validate_sync_disabled.go +++ b/pkg/cli/server/validate_sync_disabled.go @@ -4,9 +4,9 @@ package server import ( - "zotregistry.dev/zot/pkg/api/config" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - zlog "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + zlog "zotregistry.dev/zot/v2/pkg/log" ) func validateRetentionSyncOverlaps(config *config.Config, content syncconf.Content, urls []string, log zlog.Logger) { diff --git a/pkg/cli/server/validate_sync_enabled.go b/pkg/cli/server/validate_sync_enabled.go index 56cdbd63..cd2aa69c 100644 --- a/pkg/cli/server/validate_sync_enabled.go +++ b/pkg/cli/server/validate_sync_enabled.go @@ -6,10 +6,10 @@ package server import ( "path" - "zotregistry.dev/zot/pkg/api/config" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/extensions/sync" - zlog "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/extensions/sync" + zlog "zotregistry.dev/zot/v2/pkg/log" ) func validateRetentionSyncOverlaps(config *config.Config, content syncconf.Content, urls []string, log zlog.Logger) { diff --git a/pkg/cluster/cluster_test.go b/pkg/cluster/cluster_test.go index 9252688e..0fd24c86 100644 --- a/pkg/cluster/cluster_test.go +++ b/pkg/cluster/cluster_test.go @@ -5,7 +5,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/cluster" + "zotregistry.dev/zot/v2/pkg/cluster" ) func TestComputeTargetMember(t *testing.T) { diff --git a/pkg/common/common_test.go b/pkg/common/common_test.go index e3a00fda..5dbb8773 100644 --- a/pkg/common/common_test.go +++ b/pkg/common/common_test.go @@ -9,8 +9,8 @@ import ( notreg "github.com/notaryproject/notation-go/registry" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/common" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/common" ) func TestCommon(t *testing.T) { diff --git a/pkg/common/healthz.go b/pkg/common/healthz.go index 878126cd..eb959ab6 100644 --- a/pkg/common/healthz.go +++ b/pkg/common/healthz.go @@ -6,8 +6,8 @@ import ( "sigs.k8s.io/controller-runtime/pkg/healthz" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" ) var errNotReady = errors.New("not ready yet") diff --git a/pkg/common/http_client_test.go b/pkg/common/http_client_test.go index c74473dd..14c38891 100644 --- a/pkg/common/http_client_test.go +++ b/pkg/common/http_client_test.go @@ -9,8 +9,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/common" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/common" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestHTTPClient(t *testing.T) { diff --git a/pkg/common/http_server.go b/pkg/common/http_server.go index 31551127..69b57fca 100644 --- a/pkg/common/http_server.go +++ b/pkg/common/http_server.go @@ -10,10 +10,10 @@ import ( "github.com/gorilla/mux" jsoniter "github.com/json-iterator/go" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - apiErr "zotregistry.dev/zot/pkg/api/errors" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + apiErr "zotregistry.dev/zot/v2/pkg/api/errors" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" ) func AllowedMethods(methods ...string) []string { diff --git a/pkg/common/oci.go b/pkg/common/oci.go index 6e3c518b..aa4645e1 100644 --- a/pkg/common/oci.go +++ b/pkg/common/oci.go @@ -7,7 +7,7 @@ import ( "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" + zerr "zotregistry.dev/zot/v2/errors" ) func GetImageDirAndTag(imageName string) (string, string) { diff --git a/pkg/common/oci_test.go b/pkg/common/oci_test.go index e01941ad..a4d20851 100644 --- a/pkg/common/oci_test.go +++ b/pkg/common/oci_test.go @@ -5,7 +5,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/common" + "zotregistry.dev/zot/v2/pkg/common" ) func TestOCI(t *testing.T) { diff --git a/pkg/compat/compat.go b/pkg/compat/compat.go index ae2db659..62801697 100644 --- a/pkg/compat/compat.go +++ b/pkg/compat/compat.go @@ -5,7 +5,7 @@ import ( docker "github.com/distribution/distribution/v3/manifest/schema2" v1 "github.com/opencontainers/image-spec/specs-go/v1" - "zotregistry.dev/zot/errors" + "zotregistry.dev/zot/v2/errors" ) // MediaCompatibility determines non-OCI media-compatilibility. diff --git a/pkg/compliance/v1_0_0/check.go b/pkg/compliance/v1_0_0/check.go index 6436987f..ef0bb926 100644 --- a/pkg/compliance/v1_0_0/check.go +++ b/pkg/compliance/v1_0_0/check.go @@ -19,11 +19,11 @@ import ( "github.com/smartystreets/goconvey/convey/reporting" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/compliance" - test "zotregistry.dev/zot/pkg/test/common" - "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/compliance" + test "zotregistry.dev/zot/v2/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/test/image-utils" ) func CheckWorkflows(t *testing.T, config *compliance.Config) { diff --git a/pkg/compliance/v1_0_0/check_test.go b/pkg/compliance/v1_0_0/check_test.go index d4821c08..dba901f9 100644 --- a/pkg/compliance/v1_0_0/check_test.go +++ b/pkg/compliance/v1_0_0/check_test.go @@ -9,11 +9,11 @@ import ( "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/compliance" - "zotregistry.dev/zot/pkg/compliance/v1_0_0" - . "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/compliance" + "zotregistry.dev/zot/v2/pkg/compliance/v1_0_0" + . "zotregistry.dev/zot/v2/pkg/test/common" ) //nolint:gochecknoglobals diff --git a/pkg/debug/gqlplayground/gqlplayground.go b/pkg/debug/gqlplayground/gqlplayground.go index 9d929d55..e119021c 100644 --- a/pkg/debug/gqlplayground/gqlplayground.go +++ b/pkg/debug/gqlplayground/gqlplayground.go @@ -10,10 +10,10 @@ import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/constants" - debugCst "zotregistry.dev/zot/pkg/debug/constants" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" + "zotregistry.dev/zot/v2/pkg/api/constants" + debugCst "zotregistry.dev/zot/v2/pkg/debug/constants" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" ) //go:embed index.html.tmpl diff --git a/pkg/debug/gqlplayground/gqlplayground_disabled.go b/pkg/debug/gqlplayground/gqlplayground_disabled.go index bec22002..c6006546 100644 --- a/pkg/debug/gqlplayground/gqlplayground_disabled.go +++ b/pkg/debug/gqlplayground/gqlplayground_disabled.go @@ -6,8 +6,8 @@ package debug import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" ) // SetupGQLPlaygroundRoutes ... diff --git a/pkg/debug/pprof/pprof.go b/pkg/debug/pprof/pprof.go index c722f106..ce37c7dc 100644 --- a/pkg/debug/pprof/pprof.go +++ b/pkg/debug/pprof/pprof.go @@ -17,11 +17,11 @@ import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - registryConst "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/debug/constants" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + registryConst "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/debug/constants" + "zotregistry.dev/zot/v2/pkg/log" ) type profileEntry struct { diff --git a/pkg/debug/pprof/pprof_disabled.go b/pkg/debug/pprof/pprof_disabled.go index ef553a11..8a907db0 100644 --- a/pkg/debug/pprof/pprof_disabled.go +++ b/pkg/debug/pprof/pprof_disabled.go @@ -6,8 +6,8 @@ package pprof import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" //nolint:goimports + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" //nolint:goimports ) func SetupPprofRoutes(conf *config.Config, router *mux.Router, authFunc mux.MiddlewareFunc, diff --git a/pkg/debug/pprof/pprof_test.go b/pkg/debug/pprof/pprof_test.go index 787eedba..048c2819 100644 --- a/pkg/debug/pprof/pprof_test.go +++ b/pkg/debug/pprof/pprof_test.go @@ -11,11 +11,11 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - debugConstants "zotregistry.dev/zot/pkg/debug/constants" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + debugConstants "zotregistry.dev/zot/v2/pkg/debug/constants" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestProfilingAuthz(t *testing.T) { diff --git a/pkg/debug/swagger/swagger.go b/pkg/debug/swagger/swagger.go index e59af94e..6f0761c7 100644 --- a/pkg/debug/swagger/swagger.go +++ b/pkg/debug/swagger/swagger.go @@ -11,10 +11,10 @@ import ( "github.com/gorilla/mux" httpSwagger "github.com/swaggo/http-swagger" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" //nolint:goimports + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" //nolint:goimports // as required by swaggo. - _ "zotregistry.dev/zot/swagger" + _ "zotregistry.dev/zot/v2/swagger" ) func SetupSwaggerRoutes(conf *config.Config, router *mux.Router, authFunc mux.MiddlewareFunc, diff --git a/pkg/debug/swagger/swagger_disabled.go b/pkg/debug/swagger/swagger_disabled.go index 9da16d07..a5b85239 100644 --- a/pkg/debug/swagger/swagger_disabled.go +++ b/pkg/debug/swagger/swagger_disabled.go @@ -10,8 +10,8 @@ package debug import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" ) func SetupSwaggerRoutes(conf *config.Config, router *mux.Router, authFunc mux.MiddlewareFunc, diff --git a/pkg/exporter/api/controller.go b/pkg/exporter/api/controller.go index b7a2a580..1da96c40 100644 --- a/pkg/exporter/api/controller.go +++ b/pkg/exporter/api/controller.go @@ -4,7 +4,7 @@ package api import ( - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) type Controller struct { diff --git a/pkg/exporter/api/controller_test.go b/pkg/exporter/api/controller_test.go index e5628119..92d62359 100644 --- a/pkg/exporter/api/controller_test.go +++ b/pkg/exporter/api/controller_test.go @@ -22,12 +22,12 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zotapi "zotregistry.dev/zot/pkg/api" - zotcfg "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/exporter/api" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/scheduler" - . "zotregistry.dev/zot/pkg/test/common" + zotapi "zotregistry.dev/zot/v2/pkg/api" + zotcfg "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/exporter/api" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/scheduler" + . "zotregistry.dev/zot/v2/pkg/test/common" ) func getRandomLatencyN(maxLatency int64) time.Duration { diff --git a/pkg/exporter/api/exporter.go b/pkg/exporter/api/exporter.go index 2f477c46..8b72ac3d 100644 --- a/pkg/exporter/api/exporter.go +++ b/pkg/exporter/api/exporter.go @@ -15,8 +15,8 @@ import ( "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promhttp" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" ) const ( diff --git a/pkg/exporter/cli/cli.go b/pkg/exporter/cli/cli.go index 421d3f8c..59c2ec33 100644 --- a/pkg/exporter/cli/cli.go +++ b/pkg/exporter/cli/cli.go @@ -8,9 +8,9 @@ import ( "github.com/spf13/cobra" "github.com/spf13/viper" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/exporter/api" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/exporter/api" + "zotregistry.dev/zot/v2/pkg/log" ) // metadataConfig reports metadata after parsing, which we use to track diff --git a/pkg/exporter/cli/cli_test.go b/pkg/exporter/cli/cli_test.go index 3ceee64c..071b3fb6 100644 --- a/pkg/exporter/cli/cli_test.go +++ b/pkg/exporter/cli/cli_test.go @@ -9,7 +9,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/exporter/cli" + "zotregistry.dev/zot/v2/pkg/exporter/cli" ) func TestExporterCli(t *testing.T) { diff --git a/pkg/extensions/config/config.go b/pkg/extensions/config/config.go index b1f422fe..8f139433 100644 --- a/pkg/extensions/config/config.go +++ b/pkg/extensions/config/config.go @@ -3,8 +3,8 @@ package config import ( "time" - "zotregistry.dev/zot/pkg/extensions/config/events" - "zotregistry.dev/zot/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/extensions/config/sync" ) // BaseConfig has params applicable to all extensions. diff --git a/pkg/extensions/config/events/decoder.go b/pkg/extensions/config/events/decoder.go index 6a6c2fe5..10091f06 100644 --- a/pkg/extensions/config/events/decoder.go +++ b/pkg/extensions/config/events/decoder.go @@ -5,7 +5,7 @@ import ( "github.com/mitchellh/mapstructure" - zerr "zotregistry.dev/zot/errors" + zerr "zotregistry.dev/zot/v2/errors" ) // SinkConfigDecoderHook provides a mapstructure hook for decoding SinkConfig interfaces. diff --git a/pkg/extensions/events/builder.go b/pkg/extensions/events/builder.go index 1bd66f62..524ad5cd 100644 --- a/pkg/extensions/events/builder.go +++ b/pkg/extensions/events/builder.go @@ -9,7 +9,7 @@ import ( cloudevents "github.com/cloudevents/sdk-go/v2" "github.com/google/uuid" - zerr "zotregistry.dev/zot/errors" + zerr "zotregistry.dev/zot/v2/errors" ) type eventBuilder struct { diff --git a/pkg/extensions/events/events.go b/pkg/extensions/events/events.go index d5b86abb..176b3e39 100644 --- a/pkg/extensions/events/events.go +++ b/pkg/extensions/events/events.go @@ -11,8 +11,8 @@ import ( cloudevents "github.com/cloudevents/sdk-go/v2" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" - "zotregistry.dev/zot/pkg/log" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/log" ) type eventRecorder struct { diff --git a/pkg/extensions/events/events_test.go b/pkg/extensions/events/events_test.go index 2b5024c1..b0c6805e 100644 --- a/pkg/extensions/events/events_test.go +++ b/pkg/extensions/events/events_test.go @@ -18,10 +18,10 @@ import ( . "github.com/smartystreets/goconvey/convey" "k8s.io/apimachinery/pkg/util/rand" - zerr "zotregistry.dev/zot/errors" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/log" ) type mockSink struct { diff --git a/pkg/extensions/events/extension.go b/pkg/extensions/events/extension.go index 976a50c3..59c2af7d 100644 --- a/pkg/extensions/events/extension.go +++ b/pkg/extensions/events/extension.go @@ -6,8 +6,8 @@ package events import ( cloudevents "github.com/cloudevents/sdk-go/v2" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" ) type Sink interface { diff --git a/pkg/extensions/events/http_sink.go b/pkg/extensions/events/http_sink.go index c342ef01..b50035ea 100644 --- a/pkg/extensions/events/http_sink.go +++ b/pkg/extensions/events/http_sink.go @@ -12,8 +12,8 @@ import ( cloudevents "github.com/cloudevents/sdk-go/v2" cehttp "github.com/cloudevents/sdk-go/v2/protocol/http" - zerr "zotregistry.dev/zot/errors" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" + zerr "zotregistry.dev/zot/v2/errors" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" ) type HTTPSink struct { diff --git a/pkg/extensions/events/http_sink_test.go b/pkg/extensions/events/http_sink_test.go index a06635a4..8ea4c9ee 100644 --- a/pkg/extensions/events/http_sink_test.go +++ b/pkg/extensions/events/http_sink_test.go @@ -10,9 +10,9 @@ import ( cloudevents "github.com/cloudevents/sdk-go/v2" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" - "zotregistry.dev/zot/pkg/extensions/events" + zerr "zotregistry.dev/zot/v2/errors" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/extensions/events" ) func TestHTTPSink(t *testing.T) { diff --git a/pkg/extensions/events/nats_sink.go b/pkg/extensions/events/nats_sink.go index 24cc8ed6..65452d86 100644 --- a/pkg/extensions/events/nats_sink.go +++ b/pkg/extensions/events/nats_sink.go @@ -11,8 +11,8 @@ import ( cloudevents "github.com/cloudevents/sdk-go/v2" "github.com/nats-io/nats.go" - zerr "zotregistry.dev/zot/errors" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" + zerr "zotregistry.dev/zot/v2/errors" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" ) // NATSSink implements a CloudEvents sink that publishes to NATS. diff --git a/pkg/extensions/events/nats_sink_test.go b/pkg/extensions/events/nats_sink_test.go index 1492287a..6c79a7ec 100644 --- a/pkg/extensions/events/nats_sink_test.go +++ b/pkg/extensions/events/nats_sink_test.go @@ -10,9 +10,9 @@ import ( cloudevents "github.com/cloudevents/sdk-go/v2" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" - "zotregistry.dev/zot/pkg/extensions/events" + zerr "zotregistry.dev/zot/v2/errors" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/extensions/events" ) func TestNATSSink(t *testing.T) { diff --git a/pkg/extensions/extension_events.go b/pkg/extensions/extension_events.go index 8b56786b..fffca7b0 100644 --- a/pkg/extensions/extension_events.go +++ b/pkg/extensions/extension_events.go @@ -4,11 +4,11 @@ package extensions import ( - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - eventsconfig "zotregistry.dev/zot/pkg/extensions/config/events" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + eventsconfig "zotregistry.dev/zot/v2/pkg/extensions/config/events" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/log" ) func NewEventRecorder(config *config.Config, log log.Logger) (events.Recorder, error) { diff --git a/pkg/extensions/extension_events_disabled.go b/pkg/extensions/extension_events_disabled.go index 407b86b1..9c5bbf06 100644 --- a/pkg/extensions/extension_events_disabled.go +++ b/pkg/extensions/extension_events_disabled.go @@ -4,10 +4,10 @@ package extensions import ( - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/log" ) func NewEventRecorder(config *config.Config, log log.Logger) (events.Recorder, error) { diff --git a/pkg/extensions/extension_events_disabled_test.go b/pkg/extensions/extension_events_disabled_test.go index acaa700a..3ae1882c 100644 --- a/pkg/extensions/extension_events_disabled_test.go +++ b/pkg/extensions/extension_events_disabled_test.go @@ -9,11 +9,11 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - eventsconf "zotregistry.dev/zot/pkg/extensions/config/events" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + eventsconf "zotregistry.dev/zot/v2/pkg/extensions/config/events" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestEventsExtension(t *testing.T) { diff --git a/pkg/extensions/extension_image_trust.go b/pkg/extensions/extension_image_trust.go index 709a6765..6713edf4 100644 --- a/pkg/extensions/extension_image_trust.go +++ b/pkg/extensions/extension_image_trust.go @@ -11,15 +11,15 @@ import ( "github.com/gorilla/mux" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/imagetrust" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - sconstants "zotregistry.dev/zot/pkg/storage/constants" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/imagetrust" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + sconstants "zotregistry.dev/zot/v2/pkg/storage/constants" ) func IsBuiltWithImageTrustExtension() bool { diff --git a/pkg/extensions/extension_image_trust_disabled.go b/pkg/extensions/extension_image_trust_disabled.go index baa424ef..1353905f 100644 --- a/pkg/extensions/extension_image_trust_disabled.go +++ b/pkg/extensions/extension_image_trust_disabled.go @@ -6,10 +6,10 @@ package extensions import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" ) func IsBuiltWithImageTrustExtension() bool { diff --git a/pkg/extensions/extension_image_trust_disabled_test.go b/pkg/extensions/extension_image_trust_disabled_test.go index bc860fc6..1c7f0f40 100644 --- a/pkg/extensions/extension_image_trust_disabled_test.go +++ b/pkg/extensions/extension_image_trust_disabled_test.go @@ -8,10 +8,10 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestImageTrustExtension(t *testing.T) { diff --git a/pkg/extensions/extension_image_trust_test.go b/pkg/extensions/extension_image_trust_test.go index 4373465f..3b537837 100644 --- a/pkg/extensions/extension_image_trust_test.go +++ b/pkg/extensions/extension_image_trust_test.go @@ -25,20 +25,20 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/signature" - tskip "zotregistry.dev/zot/pkg/test/skip" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) type errReader int diff --git a/pkg/extensions/extension_metrics.go b/pkg/extensions/extension_metrics.go index 0555ef0b..64beb284 100644 --- a/pkg/extensions/extension_metrics.go +++ b/pkg/extensions/extension_metrics.go @@ -7,9 +7,9 @@ import ( "github.com/gorilla/mux" "github.com/prometheus/client_golang/prometheus/promhttp" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" ) func EnableMetricsExtension(config *config.Config, log log.Logger, rootDir string) { diff --git a/pkg/extensions/extension_metrics_disabled.go b/pkg/extensions/extension_metrics_disabled.go index ec6460b2..cc6eabd5 100644 --- a/pkg/extensions/extension_metrics_disabled.go +++ b/pkg/extensions/extension_metrics_disabled.go @@ -8,10 +8,10 @@ import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" ) // EnableMetricsExtension ... diff --git a/pkg/extensions/extension_mgmt.go b/pkg/extensions/extension_mgmt.go index 85882ea1..3da8afb6 100644 --- a/pkg/extensions/extension_mgmt.go +++ b/pkg/extensions/extension_mgmt.go @@ -9,10 +9,10 @@ import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" ) type HTPasswd struct { diff --git a/pkg/extensions/extension_mgmt_disabled.go b/pkg/extensions/extension_mgmt_disabled.go index 59739c6b..dda8aa8f 100644 --- a/pkg/extensions/extension_mgmt_disabled.go +++ b/pkg/extensions/extension_mgmt_disabled.go @@ -6,8 +6,8 @@ package extensions import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" ) func IsBuiltWithMGMTExtension() bool { diff --git a/pkg/extensions/extension_scrub.go b/pkg/extensions/extension_scrub.go index 8ef1127e..6998eee6 100644 --- a/pkg/extensions/extension_scrub.go +++ b/pkg/extensions/extension_scrub.go @@ -6,12 +6,12 @@ package extensions import ( "time" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/scrub" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/scrub" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) // EnableScrubExtension enables scrub extension. diff --git a/pkg/extensions/extension_scrub_disabled.go b/pkg/extensions/extension_scrub_disabled.go index 33414aac..cd7a0969 100644 --- a/pkg/extensions/extension_scrub_disabled.go +++ b/pkg/extensions/extension_scrub_disabled.go @@ -4,10 +4,10 @@ package extensions import ( - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" ) // EnableScrubExtension ... diff --git a/pkg/extensions/extension_search.go b/pkg/extensions/extension_search.go index 6946c6b7..d45d22c0 100644 --- a/pkg/extensions/extension_search.go +++ b/pkg/extensions/extension_search.go @@ -10,16 +10,16 @@ import ( gqlHandler "github.com/99designs/gqlgen/graphql/handler" "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/search" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/search" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" ) const scanInterval = 15 * time.Minute diff --git a/pkg/extensions/extension_search_disabled.go b/pkg/extensions/extension_search_disabled.go index 6f57e34d..2a4ebe28 100644 --- a/pkg/extensions/extension_search_disabled.go +++ b/pkg/extensions/extension_search_disabled.go @@ -6,11 +6,11 @@ package extensions import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" ) type CveScanner interface{} diff --git a/pkg/extensions/extension_sync.go b/pkg/extensions/extension_sync.go index 5a0d0b4e..17619b39 100644 --- a/pkg/extensions/extension_sync.go +++ b/pkg/extensions/extension_sync.go @@ -8,14 +8,14 @@ import ( "net/url" "strings" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/extensions/sync" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/extensions/sync" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" ) func EnableSyncExtension(config *config.Config, metaDB mTypes.MetaDB, diff --git a/pkg/extensions/extension_sync_disabled.go b/pkg/extensions/extension_sync_disabled.go index 72511c0a..01d63be8 100644 --- a/pkg/extensions/extension_sync_disabled.go +++ b/pkg/extensions/extension_sync_disabled.go @@ -4,12 +4,12 @@ package extensions import ( - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/sync" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/sync" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" ) // EnableSyncExtension ... diff --git a/pkg/extensions/extension_ui.go b/pkg/extensions/extension_ui.go index 9fcaa93f..a4aa2741 100644 --- a/pkg/extensions/extension_ui.go +++ b/pkg/extensions/extension_ui.go @@ -11,9 +11,9 @@ import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" ) // content is our static web server content. diff --git a/pkg/extensions/extension_ui_disabled.go b/pkg/extensions/extension_ui_disabled.go index 76e765f8..be5adc0d 100644 --- a/pkg/extensions/extension_ui_disabled.go +++ b/pkg/extensions/extension_ui_disabled.go @@ -6,8 +6,8 @@ package extensions import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" ) func SetupUIRoutes(conf *config.Config, router *mux.Router, diff --git a/pkg/extensions/extension_ui_test.go b/pkg/extensions/extension_ui_test.go index 8f30587f..1735c243 100644 --- a/pkg/extensions/extension_ui_test.go +++ b/pkg/extensions/extension_ui_test.go @@ -13,12 +13,12 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/log" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/log" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) func TestUIExtension(t *testing.T) { diff --git a/pkg/extensions/extension_userprefs.go b/pkg/extensions/extension_userprefs.go index f21a0088..7823e135 100644 --- a/pkg/extensions/extension_userprefs.go +++ b/pkg/extensions/extension_userprefs.go @@ -9,12 +9,12 @@ import ( "github.com/gorilla/mux" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) const ( diff --git a/pkg/extensions/extension_userprefs_disable.go b/pkg/extensions/extension_userprefs_disable.go index 9c74fc3a..f0845d61 100644 --- a/pkg/extensions/extension_userprefs_disable.go +++ b/pkg/extensions/extension_userprefs_disable.go @@ -6,9 +6,9 @@ package extensions import ( "github.com/gorilla/mux" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) func IsBuiltWithUserPrefsExtension() bool { diff --git a/pkg/extensions/extension_userprefs_test.go b/pkg/extensions/extension_userprefs_test.go index 042fc81b..6db364fa 100644 --- a/pkg/extensions/extension_userprefs_test.go +++ b/pkg/extensions/extension_userprefs_test.go @@ -15,16 +15,16 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/extensions" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - test "zotregistry.dev/zot/pkg/test/common" - "zotregistry.dev/zot/pkg/test/mocks" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/extensions" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + test "zotregistry.dev/zot/v2/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrTestError = errors.New("TestError") diff --git a/pkg/extensions/extensions_lint.go b/pkg/extensions/extensions_lint.go index ba74ecab..1cd6da5f 100644 --- a/pkg/extensions/extensions_lint.go +++ b/pkg/extensions/extensions_lint.go @@ -4,9 +4,9 @@ package extensions import ( - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/lint" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/lint" + "zotregistry.dev/zot/v2/pkg/log" ) func GetLinter(config *config.Config, log log.Logger) *lint.Linter { diff --git a/pkg/extensions/extensions_lint_disabled.go b/pkg/extensions/extensions_lint_disabled.go index 757dbae1..fb03180f 100644 --- a/pkg/extensions/extensions_lint_disabled.go +++ b/pkg/extensions/extensions_lint_disabled.go @@ -4,9 +4,9 @@ package extensions import ( - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/lint" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/lint" + "zotregistry.dev/zot/v2/pkg/log" ) func GetLinter(config *config.Config, log log.Logger) *lint.Linter { diff --git a/pkg/extensions/extensions_test.go b/pkg/extensions/extensions_test.go index d1fed0c7..401f600d 100644 --- a/pkg/extensions/extensions_test.go +++ b/pkg/extensions/extensions_test.go @@ -15,14 +15,14 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/extensions" - extconf "zotregistry.dev/zot/pkg/extensions/config" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - authutils "zotregistry.dev/zot/pkg/test/auth" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/extensions" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + authutils "zotregistry.dev/zot/v2/pkg/test/auth" + test "zotregistry.dev/zot/v2/pkg/test/common" ) const ( diff --git a/pkg/extensions/get_extensions.go b/pkg/extensions/get_extensions.go index 47dfef13..1fe54c43 100644 --- a/pkg/extensions/get_extensions.go +++ b/pkg/extensions/get_extensions.go @@ -3,11 +3,11 @@ package extensions import ( distext "github.com/opencontainers/distribution-spec/specs-go/v1/extensions" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" ) func GetExtensions(config *config.Config) distext.ExtensionList { diff --git a/pkg/extensions/get_extensions_disabled_test.go b/pkg/extensions/get_extensions_disabled_test.go index 203c974b..8e791193 100644 --- a/pkg/extensions/get_extensions_disabled_test.go +++ b/pkg/extensions/get_extensions_disabled_test.go @@ -11,11 +11,11 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - extconf "zotregistry.dev/zot/pkg/extensions/config" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestGetExensionsDisabled(t *testing.T) { diff --git a/pkg/extensions/imagetrust/cosign.go b/pkg/extensions/imagetrust/cosign.go index 8c8ddbc5..c1cf5b37 100644 --- a/pkg/extensions/imagetrust/cosign.go +++ b/pkg/extensions/imagetrust/cosign.go @@ -22,7 +22,7 @@ import ( sigstoreSigs "github.com/sigstore/sigstore/pkg/signature" "github.com/sigstore/sigstore/pkg/signature/options" - zerr "zotregistry.dev/zot/errors" + zerr "zotregistry.dev/zot/v2/errors" ) const cosignDirRelativePath = "_cosign" diff --git a/pkg/extensions/imagetrust/image_trust.go b/pkg/extensions/imagetrust/image_trust.go index a6e35000..03dd0f2f 100644 --- a/pkg/extensions/imagetrust/image_trust.go +++ b/pkg/extensions/imagetrust/image_trust.go @@ -22,11 +22,11 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" ) const ( diff --git a/pkg/extensions/imagetrust/image_trust_disabled.go b/pkg/extensions/imagetrust/image_trust_disabled.go index b28fe694..3e845b6b 100644 --- a/pkg/extensions/imagetrust/image_trust_disabled.go +++ b/pkg/extensions/imagetrust/image_trust_disabled.go @@ -8,7 +8,7 @@ import ( godigest "github.com/opencontainers/go-digest" - mTypes "zotregistry.dev/zot/pkg/meta/types" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) func NewLocalImageTrustStore(dir string) (*imageTrustDisabled, error) { diff --git a/pkg/extensions/imagetrust/image_trust_disabled_test.go b/pkg/extensions/imagetrust/image_trust_disabled_test.go index 32242078..37869663 100644 --- a/pkg/extensions/imagetrust/image_trust_disabled_test.go +++ b/pkg/extensions/imagetrust/image_trust_disabled_test.go @@ -9,8 +9,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/extensions/imagetrust" - . "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/extensions/imagetrust" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) func TestImageTrust(t *testing.T) { diff --git a/pkg/extensions/imagetrust/image_trust_test.go b/pkg/extensions/imagetrust/image_trust_test.go index c0baafdd..679464bb 100644 --- a/pkg/extensions/imagetrust/image_trust_test.go +++ b/pkg/extensions/imagetrust/image_trust_test.go @@ -34,19 +34,19 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/imagetrust" - "zotregistry.dev/zot/pkg/log" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - "zotregistry.dev/zot/pkg/test/signature" - tskip "zotregistry.dev/zot/pkg/test/skip" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/imagetrust" + "zotregistry.dev/zot/v2/pkg/log" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/test/signature" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) var ( diff --git a/pkg/extensions/imagetrust/notation.go b/pkg/extensions/imagetrust/notation.go index f801e6b4..4959849b 100644 --- a/pkg/extensions/imagetrust/notation.go +++ b/pkg/extensions/imagetrust/notation.go @@ -31,7 +31,7 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" + zerr "zotregistry.dev/zot/v2/errors" ) const ( diff --git a/pkg/extensions/lint/lint.go b/pkg/extensions/lint/lint.go index 3ea0be74..1be3bafd 100644 --- a/pkg/extensions/lint/lint.go +++ b/pkg/extensions/lint/lint.go @@ -10,10 +10,10 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/log" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/log" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) type Linter struct { diff --git a/pkg/extensions/lint/lint_disabled.go b/pkg/extensions/lint/lint_disabled.go index 9e35bcf0..11095777 100644 --- a/pkg/extensions/lint/lint_disabled.go +++ b/pkg/extensions/lint/lint_disabled.go @@ -6,7 +6,7 @@ package lint import ( godigest "github.com/opencontainers/go-digest" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) type Linter struct{} diff --git a/pkg/extensions/lint/lint_test.go b/pkg/extensions/lint/lint_test.go index b3544361..d1e4a69f 100644 --- a/pkg/extensions/lint/lint_test.go +++ b/pkg/extensions/lint/lint_test.go @@ -17,16 +17,16 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/lint" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage/local" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/lint" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage/local" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) func TestVerifyMandatoryAnnotations(t *testing.T) { diff --git a/pkg/extensions/monitoring/extension.go b/pkg/extensions/monitoring/extension.go index 50c32097..b05d1f6c 100644 --- a/pkg/extensions/monitoring/extension.go +++ b/pkg/extensions/monitoring/extension.go @@ -10,8 +10,8 @@ import ( "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promauto" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" ) const metricsNamespace = "zot" diff --git a/pkg/extensions/monitoring/minimal.go b/pkg/extensions/monitoring/minimal.go index 15399d5f..4b90554c 100644 --- a/pkg/extensions/monitoring/minimal.go +++ b/pkg/extensions/monitoring/minimal.go @@ -12,7 +12,7 @@ import ( "sync" "time" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) const ( diff --git a/pkg/extensions/monitoring/minimal_client.go b/pkg/extensions/monitoring/minimal_client.go index 75957f74..c5d876e9 100644 --- a/pkg/extensions/monitoring/minimal_client.go +++ b/pkg/extensions/monitoring/minimal_client.go @@ -11,7 +11,7 @@ import ( "net/http" "time" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) const ( diff --git a/pkg/extensions/monitoring/monitoring_test.go b/pkg/extensions/monitoring/monitoring_test.go index d22c9032..d179717b 100644 --- a/pkg/extensions/monitoring/monitoring_test.go +++ b/pkg/extensions/monitoring/monitoring_test.go @@ -16,16 +16,16 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" - common "zotregistry.dev/zot/pkg/storage/common" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" + common "zotregistry.dev/zot/v2/pkg/storage/common" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) func TestExtensionMetrics(t *testing.T) { diff --git a/pkg/extensions/scrub/scrub.go b/pkg/extensions/scrub/scrub.go index 58bfcdc5..7a53f340 100644 --- a/pkg/extensions/scrub/scrub.go +++ b/pkg/extensions/scrub/scrub.go @@ -8,9 +8,9 @@ import ( "fmt" "path" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) // Scrub Extension for repo... diff --git a/pkg/extensions/scrub/scrub_test.go b/pkg/extensions/scrub/scrub_test.go index 81304ad7..fc299424 100644 --- a/pkg/extensions/scrub/scrub_test.go +++ b/pkg/extensions/scrub/scrub_test.go @@ -12,18 +12,18 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/extensions/scrub" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - "zotregistry.dev/zot/pkg/storage/local" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/extensions/scrub" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + "zotregistry.dev/zot/v2/pkg/storage/local" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) const ( diff --git a/pkg/extensions/search/convert/convert_internal_test.go b/pkg/extensions/search/convert/convert_internal_test.go index b75ee28d..af5324d3 100644 --- a/pkg/extensions/search/convert/convert_internal_test.go +++ b/pkg/extensions/search/convert/convert_internal_test.go @@ -11,12 +11,12 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/boltdb" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrTestError = errors.New("TestError") diff --git a/pkg/extensions/search/convert/convert_test.go b/pkg/extensions/search/convert/convert_test.go index c5d1a374..3a588616 100644 --- a/pkg/extensions/search/convert/convert_test.go +++ b/pkg/extensions/search/convert/convert_test.go @@ -12,16 +12,16 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/extensions/search/convert" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - "zotregistry.dev/zot/pkg/extensions/search/pagination" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/boltdb" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/extensions/search/convert" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + "zotregistry.dev/zot/v2/pkg/extensions/search/pagination" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) var ErrTestError = errors.New("TestError") diff --git a/pkg/extensions/search/convert/cve.go b/pkg/extensions/search/convert/cve.go index cea29793..47a5ba16 100644 --- a/pkg/extensions/search/convert/cve.go +++ b/pkg/extensions/search/convert/cve.go @@ -7,9 +7,9 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/vektah/gqlparser/v2/gqlerror" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" ) func updateRepoSummaryVulnerabilities( diff --git a/pkg/extensions/search/convert/metadb.go b/pkg/extensions/search/convert/metadb.go index 4c1f35fd..f2de6f85 100644 --- a/pkg/extensions/search/convert/metadb.go +++ b/pkg/extensions/search/convert/metadb.go @@ -10,14 +10,14 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/vektah/gqlparser/v2/gqlerror" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - "zotregistry.dev/zot/pkg/extensions/search/pagination" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + "zotregistry.dev/zot/v2/pkg/extensions/search/pagination" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" ) type SkipQGLField struct { diff --git a/pkg/extensions/search/convert/oci.go b/pkg/extensions/search/convert/oci.go index d5b7f11b..afb72c26 100644 --- a/pkg/extensions/search/convert/oci.go +++ b/pkg/extensions/search/convert/oci.go @@ -5,8 +5,8 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" ) func getLayersSummaries(manifestContent ispec.Manifest) []*gql_generated.LayerSummary { diff --git a/pkg/extensions/search/convert/utils.go b/pkg/extensions/search/convert/utils.go index 1bff44c1..662c8acc 100644 --- a/pkg/extensions/search/convert/utils.go +++ b/pkg/extensions/search/convert/utils.go @@ -1,9 +1,9 @@ package convert import ( - zcommon "zotregistry.dev/zot/pkg/common" - gql_gen "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - mTypes "zotregistry.dev/zot/pkg/meta/types" + zcommon "zotregistry.dev/zot/v2/pkg/common" + gql_gen "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) func ImgSumAcceptedByFilter(imageSummary *gql_gen.ImageSummary, filter mTypes.Filter) bool { diff --git a/pkg/extensions/search/cve/cache/cache.go b/pkg/extensions/search/cve/cache/cache.go index 92866d45..3a21e19f 100644 --- a/pkg/extensions/search/cve/cache/cache.go +++ b/pkg/extensions/search/cve/cache/cache.go @@ -3,8 +3,8 @@ package cache import ( lru "github.com/hashicorp/golang-lru/v2" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" ) type CveCache struct { diff --git a/pkg/extensions/search/cve/cve.go b/pkg/extensions/search/cve/cve.go index 922a9879..729338d5 100644 --- a/pkg/extensions/search/cve/cve.go +++ b/pkg/extensions/search/cve/cve.go @@ -9,14 +9,14 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/extensions/search/cve/trivy" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/extensions/search/cve/trivy" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" ) type CveInfo interface { diff --git a/pkg/extensions/search/cve/cve_internal_test.go b/pkg/extensions/search/cve/cve_internal_test.go index 4f902cfd..7d5ccd98 100644 --- a/pkg/extensions/search/cve/cve_internal_test.go +++ b/pkg/extensions/search/cve/cve_internal_test.go @@ -11,9 +11,9 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/test/mocks" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrTestError = errors.New("test error") diff --git a/pkg/extensions/search/cve/cve_test.go b/pkg/extensions/search/cve/cve_test.go index 5a8aef49..b95049b5 100644 --- a/pkg/extensions/search/cve/cve_test.go +++ b/pkg/extensions/search/cve/cve_test.go @@ -22,27 +22,27 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - apiErr "zotregistry.dev/zot/pkg/api/errors" - zcommon "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvecache "zotregistry.dev/zot/pkg/extensions/search/cve/cache" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + apiErr "zotregistry.dev/zot/v2/pkg/api/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvecache "zotregistry.dev/zot/v2/pkg/extensions/search/cve/cache" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) type CveResult struct { diff --git a/pkg/extensions/search/cve/pagination.go b/pkg/extensions/search/cve/pagination.go index 14d5c2f7..23dad926 100644 --- a/pkg/extensions/search/cve/pagination.go +++ b/pkg/extensions/search/cve/pagination.go @@ -4,9 +4,9 @@ import ( "fmt" "sort" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" ) const ( diff --git a/pkg/extensions/search/cve/pagination_test.go b/pkg/extensions/search/cve/pagination_test.go index 1041aaf2..6c612334 100644 --- a/pkg/extensions/search/cve/pagination_test.go +++ b/pkg/extensions/search/cve/pagination_test.go @@ -13,12 +13,12 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/boltdb" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) func TestCVEPagination(t *testing.T) { diff --git a/pkg/extensions/search/cve/scan.go b/pkg/extensions/search/cve/scan.go index 82d99100..5081a185 100644 --- a/pkg/extensions/search/cve/scan.go +++ b/pkg/extensions/search/cve/scan.go @@ -5,10 +5,10 @@ import ( "fmt" "sync" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - "zotregistry.dev/zot/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + "zotregistry.dev/zot/v2/pkg/scheduler" ) func NewScanTaskGenerator( diff --git a/pkg/extensions/search/cve/scan_test.go b/pkg/extensions/search/cve/scan_test.go index f0b679f8..e030b6b3 100644 --- a/pkg/extensions/search/cve/scan_test.go +++ b/pkg/extensions/search/cve/scan_test.go @@ -16,23 +16,23 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/monitoring" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvecache "zotregistry.dev/zot/pkg/extensions/search/cve/cache" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvecache "zotregistry.dev/zot/v2/pkg/extensions/search/cve/cache" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ( diff --git a/pkg/extensions/search/cve/trivy/scanner.go b/pkg/extensions/search/cve/trivy/scanner.go index 97b760e2..c038c81a 100644 --- a/pkg/extensions/search/cve/trivy/scanner.go +++ b/pkg/extensions/search/cve/trivy/scanner.go @@ -24,14 +24,14 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" _ "modernc.org/sqlite" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - cvecache "zotregistry.dev/zot/pkg/extensions/search/cve/cache" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + cvecache "zotregistry.dev/zot/v2/pkg/extensions/search/cve/cache" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" ) const cacheSize = 1000000 diff --git a/pkg/extensions/search/cve/trivy/scanner_internal_test.go b/pkg/extensions/search/cve/trivy/scanner_internal_test.go index 9ea6183e..8ab0be7c 100644 --- a/pkg/extensions/search/cve/trivy/scanner_internal_test.go +++ b/pkg/extensions/search/cve/trivy/scanner_internal_test.go @@ -14,22 +14,22 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/monitoring" - cvecache "zotregistry.dev/zot/pkg/extensions/search/cve/cache" - "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/imagestore" - "zotregistry.dev/zot/pkg/storage/local" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + cvecache "zotregistry.dev/zot/v2/pkg/extensions/search/cve/cache" + "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/imagestore" + "zotregistry.dev/zot/v2/pkg/storage/local" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) func generateTestImage(storeController storage.StoreController, imageName string) { diff --git a/pkg/extensions/search/cve/trivy/scanner_test.go b/pkg/extensions/search/cve/trivy/scanner_test.go index 117f5954..f0423228 100644 --- a/pkg/extensions/search/cve/trivy/scanner_test.go +++ b/pkg/extensions/search/cve/trivy/scanner_test.go @@ -13,20 +13,20 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/extensions/search/cve/trivy" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - . "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/extensions/search/cve/trivy" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + . "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrTestError = errors.New("test error") diff --git a/pkg/extensions/search/cve/update.go b/pkg/extensions/search/cve/update.go index 010599ba..ed635b97 100644 --- a/pkg/extensions/search/cve/update.go +++ b/pkg/extensions/search/cve/update.go @@ -6,8 +6,8 @@ import ( "sync" "time" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" ) type state int diff --git a/pkg/extensions/search/cve/update_test.go b/pkg/extensions/search/cve/update_test.go index e64847c7..0a3f0b34 100644 --- a/pkg/extensions/search/cve/update_test.go +++ b/pkg/extensions/search/cve/update_test.go @@ -13,15 +13,15 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - test "zotregistry.dev/zot/pkg/test/common" - "zotregistry.dev/zot/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + test "zotregistry.dev/zot/v2/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) func TestCVEDBGenerator(t *testing.T) { diff --git a/pkg/extensions/search/digest_test.go b/pkg/extensions/search/digest_test.go index 4ba252cc..a1e2d705 100644 --- a/pkg/extensions/search/digest_test.go +++ b/pkg/extensions/search/digest_test.go @@ -15,13 +15,13 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - . "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + . "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) type ImgResponseForDigest struct { diff --git a/pkg/extensions/search/gql_generated/generated.go b/pkg/extensions/search/gql_generated/generated.go index 2a0e6221..5fe72f90 100644 --- a/pkg/extensions/search/gql_generated/generated.go +++ b/pkg/extensions/search/gql_generated/generated.go @@ -2130,7 +2130,7 @@ func (ec *executionContext) field_Query_BaseImageList_args(ctx context.Context, return nil, err } args["digest"] = arg1 - arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2141,7 +2141,7 @@ func (ec *executionContext) field_Query_BaseImageList_args(ctx context.Context, func (ec *executionContext) field_Query_BookmarkedRepos_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) { var err error args := map[string]any{} - arg0, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg0, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2152,17 +2152,17 @@ func (ec *executionContext) field_Query_BookmarkedRepos_args(ctx context.Context func (ec *executionContext) field_Query_CVEDiffListForImages_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) { var err error args := map[string]any{} - arg0, err := graphql.ProcessArgField(ctx, rawArgs, "minuend", ec.unmarshalNImageInput2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageInput) + arg0, err := graphql.ProcessArgField(ctx, rawArgs, "minuend", ec.unmarshalNImageInput2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageInput) if err != nil { return nil, err } args["minuend"] = arg0 - arg1, err := graphql.ProcessArgField(ctx, rawArgs, "subtrahend", ec.unmarshalNImageInput2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageInput) + arg1, err := graphql.ProcessArgField(ctx, rawArgs, "subtrahend", ec.unmarshalNImageInput2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageInput) if err != nil { return nil, err } args["subtrahend"] = arg1 - arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2188,7 +2188,7 @@ func (ec *executionContext) field_Query_CVEListForImage_args(ctx context.Context return nil, err } args["image"] = arg0 - arg1, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg1, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2224,7 +2224,7 @@ func (ec *executionContext) field_Query_DerivedImageList_args(ctx context.Contex return nil, err } args["digest"] = arg1 - arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2251,12 +2251,12 @@ func (ec *executionContext) field_Query_GlobalSearch_args(ctx context.Context, r return nil, err } args["query"] = arg0 - arg1, err := graphql.ProcessArgField(ctx, rawArgs, "filter", ec.unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter) + arg1, err := graphql.ProcessArgField(ctx, rawArgs, "filter", ec.unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter) if err != nil { return nil, err } args["filter"] = arg1 - arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2272,12 +2272,12 @@ func (ec *executionContext) field_Query_ImageListForCVE_args(ctx context.Context return nil, err } args["id"] = arg0 - arg1, err := graphql.ProcessArgField(ctx, rawArgs, "filter", ec.unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter) + arg1, err := graphql.ProcessArgField(ctx, rawArgs, "filter", ec.unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter) if err != nil { return nil, err } args["filter"] = arg1 - arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg2, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2293,7 +2293,7 @@ func (ec *executionContext) field_Query_ImageListForDigest_args(ctx context.Cont return nil, err } args["id"] = arg0 - arg1, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg1, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2314,12 +2314,12 @@ func (ec *executionContext) field_Query_ImageListWithCVEFixed_args(ctx context.C return nil, err } args["image"] = arg1 - arg2, err := graphql.ProcessArgField(ctx, rawArgs, "filter", ec.unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter) + arg2, err := graphql.ProcessArgField(ctx, rawArgs, "filter", ec.unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter) if err != nil { return nil, err } args["filter"] = arg2 - arg3, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg3, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2335,7 +2335,7 @@ func (ec *executionContext) field_Query_ImageList_args(ctx context.Context, rawA return nil, err } args["repo"] = arg0 - arg1, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg1, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2378,7 +2378,7 @@ func (ec *executionContext) field_Query_Referrers_args(ctx context.Context, rawA func (ec *executionContext) field_Query_RepoListWithNewestImage_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) { var err error args := map[string]any{} - arg0, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg0, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2389,7 +2389,7 @@ func (ec *executionContext) field_Query_RepoListWithNewestImage_args(ctx context func (ec *executionContext) field_Query_StarredRepos_args(ctx context.Context, rawArgs map[string]any) (map[string]any, error) { var err error args := map[string]any{} - arg0, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) + arg0, err := graphql.ProcessArgField(ctx, rawArgs, "requestedPage", ec.unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput) if err != nil { return nil, err } @@ -2673,7 +2673,7 @@ func (ec *executionContext) _CVE_PackageList(ctx context.Context, field graphql. return obj.PackageList, nil }, nil, - ec.marshalOPackageInfo2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo, + ec.marshalOPackageInfo2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo, true, false, ) @@ -2712,7 +2712,7 @@ func (ec *executionContext) _CVEDiffResult_Minuend(ctx context.Context, field gr return obj.Minuend, nil }, nil, - ec.marshalNImageIdentifier2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageIdentifier, + ec.marshalNImageIdentifier2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageIdentifier, true, true, ) @@ -2751,7 +2751,7 @@ func (ec *executionContext) _CVEDiffResult_Subtrahend(ctx context.Context, field return obj.Subtrahend, nil }, nil, - ec.marshalNImageIdentifier2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageIdentifier, + ec.marshalNImageIdentifier2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageIdentifier, true, true, ) @@ -2790,7 +2790,7 @@ func (ec *executionContext) _CVEDiffResult_CVEList(ctx context.Context, field gr return obj.CVEList, nil }, nil, - ec.marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve, + ec.marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve, true, false, ) @@ -2833,7 +2833,7 @@ func (ec *executionContext) _CVEDiffResult_Summary(ctx context.Context, field gr return obj.Summary, nil }, nil, - ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, + ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, true, false, ) @@ -2878,7 +2878,7 @@ func (ec *executionContext) _CVEDiffResult_Page(ctx context.Context, field graph return obj.Page, nil }, nil, - ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, + ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, true, false, ) @@ -2942,7 +2942,7 @@ func (ec *executionContext) _CVEResultForImage_CVEList(ctx context.Context, fiel return obj.CVEList, nil }, nil, - ec.marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve, + ec.marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve, true, false, ) @@ -2985,7 +2985,7 @@ func (ec *executionContext) _CVEResultForImage_Summary(ctx context.Context, fiel return obj.Summary, nil }, nil, - ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, + ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, true, false, ) @@ -3030,7 +3030,7 @@ func (ec *executionContext) _CVEResultForImage_Page(ctx context.Context, field g return obj.Page, nil }, nil, - ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, + ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, true, false, ) @@ -3065,7 +3065,7 @@ func (ec *executionContext) _GlobalSearchResult_Page(ctx context.Context, field return obj.Page, nil }, nil, - ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, + ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, true, false, ) @@ -3100,7 +3100,7 @@ func (ec *executionContext) _GlobalSearchResult_Images(ctx context.Context, fiel return obj.Images, nil }, nil, - ec.marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, + ec.marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, true, false, ) @@ -3177,7 +3177,7 @@ func (ec *executionContext) _GlobalSearchResult_Repos(ctx context.Context, field return obj.Repos, nil }, nil, - ec.marshalORepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary, + ec.marshalORepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary, true, false, ) @@ -3230,7 +3230,7 @@ func (ec *executionContext) _GlobalSearchResult_Layers(ctx context.Context, fiel return obj.Layers, nil }, nil, - ec.marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary, + ec.marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary, true, false, ) @@ -3497,7 +3497,7 @@ func (ec *executionContext) _ImageIdentifier_Platform(ctx context.Context, field return obj.Platform, nil }, nil, - ec.marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform, + ec.marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform, true, false, ) @@ -3648,7 +3648,7 @@ func (ec *executionContext) _ImageSummary_Manifests(ctx context.Context, field g return obj.Manifests, nil }, nil, - ec.marshalOManifestSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary, + ec.marshalOManifestSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary, true, false, ) @@ -3908,7 +3908,7 @@ func (ec *executionContext) _ImageSummary_SignatureInfo(ctx context.Context, fie return obj.SignatureInfo, nil }, nil, - ec.marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary, + ec.marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary, true, false, ) @@ -4148,7 +4148,7 @@ func (ec *executionContext) _ImageSummary_Vulnerabilities(ctx context.Context, f return obj.Vulnerabilities, nil }, nil, - ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, + ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, true, false, ) @@ -4193,7 +4193,7 @@ func (ec *executionContext) _ImageSummary_Referrers(ctx context.Context, field g return obj.Referrers, nil }, nil, - ec.marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer, + ec.marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer, true, false, ) @@ -4466,7 +4466,7 @@ func (ec *executionContext) _LayerHistory_Layer(ctx context.Context, field graph return obj.Layer, nil }, nil, - ec.marshalOLayerSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary, + ec.marshalOLayerSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary, true, false, ) @@ -4501,7 +4501,7 @@ func (ec *executionContext) _LayerHistory_HistoryDescription(ctx context.Context return obj.HistoryDescription, nil }, nil, - ec.marshalOHistoryDescription2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐHistoryDescription, + ec.marshalOHistoryDescription2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐHistoryDescription, true, false, ) @@ -4745,7 +4745,7 @@ func (ec *executionContext) _ManifestSummary_SignatureInfo(ctx context.Context, return obj.SignatureInfo, nil }, nil, - ec.marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary, + ec.marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary, true, false, ) @@ -4782,7 +4782,7 @@ func (ec *executionContext) _ManifestSummary_Platform(ctx context.Context, field return obj.Platform, nil }, nil, - ec.marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform, + ec.marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform, true, false, ) @@ -4846,7 +4846,7 @@ func (ec *executionContext) _ManifestSummary_Layers(ctx context.Context, field g return obj.Layers, nil }, nil, - ec.marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary, + ec.marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary, true, false, ) @@ -4881,7 +4881,7 @@ func (ec *executionContext) _ManifestSummary_History(ctx context.Context, field return obj.History, nil }, nil, - ec.marshalOLayerHistory2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory, + ec.marshalOLayerHistory2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory, true, false, ) @@ -4916,7 +4916,7 @@ func (ec *executionContext) _ManifestSummary_Vulnerabilities(ctx context.Context return obj.Vulnerabilities, nil }, nil, - ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, + ec.marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary, true, false, ) @@ -4961,7 +4961,7 @@ func (ec *executionContext) _ManifestSummary_Referrers(ctx context.Context, fiel return obj.Referrers, nil }, nil, - ec.marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer, + ec.marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer, true, false, ) @@ -5205,7 +5205,7 @@ func (ec *executionContext) _PaginatedImagesResult_Page(ctx context.Context, fie return obj.Page, nil }, nil, - ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, + ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, true, false, ) @@ -5240,7 +5240,7 @@ func (ec *executionContext) _PaginatedImagesResult_Results(ctx context.Context, return obj.Results, nil }, nil, - ec.marshalNImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummaryᚄ, + ec.marshalNImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummaryᚄ, true, true, ) @@ -5317,7 +5317,7 @@ func (ec *executionContext) _PaginatedReposResult_Page(ctx context.Context, fiel return obj.Page, nil }, nil, - ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, + ec.marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo, true, false, ) @@ -5352,7 +5352,7 @@ func (ec *executionContext) _PaginatedReposResult_Results(ctx context.Context, f return obj.Results, nil }, nil, - ec.marshalNRepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummaryᚄ, + ec.marshalNRepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummaryᚄ, true, true, ) @@ -5464,7 +5464,7 @@ func (ec *executionContext) _Query_CVEListForImage(ctx context.Context, field gr return ec.resolvers.Query().CVEListForImage(ctx, fc.Args["image"].(string), fc.Args["requestedPage"].(*PageInput), fc.Args["searchedCVE"].(*string), fc.Args["excludedCVE"].(*string), fc.Args["severity"].(*string)) }, nil, - ec.marshalNCVEResultForImage2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEResultForImage, + ec.marshalNCVEResultForImage2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEResultForImage, true, true, ) @@ -5515,7 +5515,7 @@ func (ec *executionContext) _Query_CVEDiffListForImages(ctx context.Context, fie return ec.resolvers.Query().CVEDiffListForImages(ctx, fc.Args["minuend"].(ImageInput), fc.Args["subtrahend"].(ImageInput), fc.Args["requestedPage"].(*PageInput), fc.Args["searchedCVE"].(*string), fc.Args["excludedCVE"].(*string)) }, nil, - ec.marshalNCVEDiffResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEDiffResult, + ec.marshalNCVEDiffResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEDiffResult, true, true, ) @@ -5568,7 +5568,7 @@ func (ec *executionContext) _Query_ImageListForCVE(ctx context.Context, field gr return ec.resolvers.Query().ImageListForCve(ctx, fc.Args["id"].(string), fc.Args["filter"].(*Filter), fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, + ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, true, true, ) @@ -5615,7 +5615,7 @@ func (ec *executionContext) _Query_ImageListWithCVEFixed(ctx context.Context, fi return ec.resolvers.Query().ImageListWithCVEFixed(ctx, fc.Args["id"].(string), fc.Args["image"].(string), fc.Args["filter"].(*Filter), fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, + ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, true, true, ) @@ -5662,7 +5662,7 @@ func (ec *executionContext) _Query_ImageListForDigest(ctx context.Context, field return ec.resolvers.Query().ImageListForDigest(ctx, fc.Args["id"].(string), fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, + ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, true, true, ) @@ -5709,7 +5709,7 @@ func (ec *executionContext) _Query_RepoListWithNewestImage(ctx context.Context, return ec.resolvers.Query().RepoListWithNewestImage(ctx, fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult, + ec.marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult, true, true, ) @@ -5756,7 +5756,7 @@ func (ec *executionContext) _Query_ImageList(ctx context.Context, field graphql. return ec.resolvers.Query().ImageList(ctx, fc.Args["repo"].(string), fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, + ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, true, true, ) @@ -5803,7 +5803,7 @@ func (ec *executionContext) _Query_ExpandedRepoInfo(ctx context.Context, field g return ec.resolvers.Query().ExpandedRepoInfo(ctx, fc.Args["repo"].(string)) }, nil, - ec.marshalNRepoInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoInfo, + ec.marshalNRepoInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoInfo, true, true, ) @@ -5850,7 +5850,7 @@ func (ec *executionContext) _Query_GlobalSearch(ctx context.Context, field graph return ec.resolvers.Query().GlobalSearch(ctx, fc.Args["query"].(string), fc.Args["filter"].(*Filter), fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNGlobalSearchResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐGlobalSearchResult, + ec.marshalNGlobalSearchResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐGlobalSearchResult, true, true, ) @@ -5901,7 +5901,7 @@ func (ec *executionContext) _Query_DerivedImageList(ctx context.Context, field g return ec.resolvers.Query().DerivedImageList(ctx, fc.Args["image"].(string), fc.Args["digest"].(*string), fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, + ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, true, true, ) @@ -5948,7 +5948,7 @@ func (ec *executionContext) _Query_BaseImageList(ctx context.Context, field grap return ec.resolvers.Query().BaseImageList(ctx, fc.Args["image"].(string), fc.Args["digest"].(*string), fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, + ec.marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult, true, true, ) @@ -5995,7 +5995,7 @@ func (ec *executionContext) _Query_Image(ctx context.Context, field graphql.Coll return ec.resolvers.Query().Image(ctx, fc.Args["image"].(string)) }, nil, - ec.marshalNImageSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, + ec.marshalNImageSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, true, true, ) @@ -6084,7 +6084,7 @@ func (ec *executionContext) _Query_Referrers(ctx context.Context, field graphql. return ec.resolvers.Query().Referrers(ctx, fc.Args["repo"].(string), fc.Args["digest"].(string), fc.Args["type"].([]string)) }, nil, - ec.marshalNReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer, + ec.marshalNReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer, true, true, ) @@ -6137,7 +6137,7 @@ func (ec *executionContext) _Query_StarredRepos(ctx context.Context, field graph return ec.resolvers.Query().StarredRepos(ctx, fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult, + ec.marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult, true, true, ) @@ -6184,7 +6184,7 @@ func (ec *executionContext) _Query_BookmarkedRepos(ctx context.Context, field gr return ec.resolvers.Query().BookmarkedRepos(ctx, fc.Args["requestedPage"].(*PageInput)) }, nil, - ec.marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult, + ec.marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult, true, true, ) @@ -6454,7 +6454,7 @@ func (ec *executionContext) _Referrer_Annotations(ctx context.Context, field gra return obj.Annotations, nil }, nil, - ec.marshalNAnnotation2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation, + ec.marshalNAnnotation2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation, true, true, ) @@ -6489,7 +6489,7 @@ func (ec *executionContext) _RepoInfo_Images(ctx context.Context, field graphql. return obj.Images, nil }, nil, - ec.marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, + ec.marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, true, false, ) @@ -6566,7 +6566,7 @@ func (ec *executionContext) _RepoInfo_Summary(ctx context.Context, field graphql return obj.Summary, nil }, nil, - ec.marshalORepoSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary, + ec.marshalORepoSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary, true, false, ) @@ -6706,7 +6706,7 @@ func (ec *executionContext) _RepoSummary_Platforms(ctx context.Context, field gr return obj.Platforms, nil }, nil, - ec.marshalOPlatform2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform, + ec.marshalOPlatform2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform, true, false, ) @@ -6770,7 +6770,7 @@ func (ec *executionContext) _RepoSummary_NewestImage(ctx context.Context, field return obj.NewestImage, nil }, nil, - ec.marshalOImageSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, + ec.marshalOImageSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary, true, false, ) @@ -8607,7 +8607,7 @@ func (ec *executionContext) unmarshalInputImageInput(ctx context.Context, obj an it.Digest = data case "Platform": ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("Platform")) - data, err := ec.unmarshalOPlatformInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatformInput(ctx, v) + data, err := ec.unmarshalOPlatformInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatformInput(ctx, v) if err != nil { return it, err } @@ -8648,7 +8648,7 @@ func (ec *executionContext) unmarshalInputPageInput(ctx context.Context, obj any it.Offset = data case "sortBy": ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("sortBy")) - data, err := ec.unmarshalOSortCriteria2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSortCriteria(ctx, v) + data, err := ec.unmarshalOSortCriteria2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSortCriteria(ctx, v) if err != nil { return it, err } @@ -10377,7 +10377,7 @@ func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, o // region ***************************** type.gotpl ***************************** -func (ec *executionContext) marshalNAnnotation2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation(ctx context.Context, sel ast.SelectionSet, v []*Annotation) graphql.Marshaler { +func (ec *executionContext) marshalNAnnotation2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation(ctx context.Context, sel ast.SelectionSet, v []*Annotation) graphql.Marshaler { ret := make(graphql.Array, len(v)) var wg sync.WaitGroup isLen1 := len(v) == 1 @@ -10401,7 +10401,7 @@ func (ec *executionContext) marshalNAnnotation2ᚕᚖzotregistryᚗdevᚋzotᚋp if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOAnnotation2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation(ctx, sel, v[i]) + ret[i] = ec.marshalOAnnotation2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation(ctx, sel, v[i]) } if isLen1 { f(i) @@ -10431,11 +10431,11 @@ func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.Se return res } -func (ec *executionContext) marshalNCVEDiffResult2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEDiffResult(ctx context.Context, sel ast.SelectionSet, v CVEDiffResult) graphql.Marshaler { +func (ec *executionContext) marshalNCVEDiffResult2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEDiffResult(ctx context.Context, sel ast.SelectionSet, v CVEDiffResult) graphql.Marshaler { return ec._CVEDiffResult(ctx, sel, &v) } -func (ec *executionContext) marshalNCVEDiffResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEDiffResult(ctx context.Context, sel ast.SelectionSet, v *CVEDiffResult) graphql.Marshaler { +func (ec *executionContext) marshalNCVEDiffResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEDiffResult(ctx context.Context, sel ast.SelectionSet, v *CVEDiffResult) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10445,11 +10445,11 @@ func (ec *executionContext) marshalNCVEDiffResult2ᚖzotregistryᚗdevᚋzotᚋp return ec._CVEDiffResult(ctx, sel, v) } -func (ec *executionContext) marshalNCVEResultForImage2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEResultForImage(ctx context.Context, sel ast.SelectionSet, v CVEResultForImage) graphql.Marshaler { +func (ec *executionContext) marshalNCVEResultForImage2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEResultForImage(ctx context.Context, sel ast.SelectionSet, v CVEResultForImage) graphql.Marshaler { return ec._CVEResultForImage(ctx, sel, &v) } -func (ec *executionContext) marshalNCVEResultForImage2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEResultForImage(ctx context.Context, sel ast.SelectionSet, v *CVEResultForImage) graphql.Marshaler { +func (ec *executionContext) marshalNCVEResultForImage2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCVEResultForImage(ctx context.Context, sel ast.SelectionSet, v *CVEResultForImage) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10459,11 +10459,11 @@ func (ec *executionContext) marshalNCVEResultForImage2ᚖzotregistryᚗdevᚋzot return ec._CVEResultForImage(ctx, sel, v) } -func (ec *executionContext) marshalNGlobalSearchResult2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐGlobalSearchResult(ctx context.Context, sel ast.SelectionSet, v GlobalSearchResult) graphql.Marshaler { +func (ec *executionContext) marshalNGlobalSearchResult2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐGlobalSearchResult(ctx context.Context, sel ast.SelectionSet, v GlobalSearchResult) graphql.Marshaler { return ec._GlobalSearchResult(ctx, sel, &v) } -func (ec *executionContext) marshalNGlobalSearchResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐGlobalSearchResult(ctx context.Context, sel ast.SelectionSet, v *GlobalSearchResult) graphql.Marshaler { +func (ec *executionContext) marshalNGlobalSearchResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐGlobalSearchResult(ctx context.Context, sel ast.SelectionSet, v *GlobalSearchResult) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10473,7 +10473,7 @@ func (ec *executionContext) marshalNGlobalSearchResult2ᚖzotregistryᚗdevᚋzo return ec._GlobalSearchResult(ctx, sel, v) } -func (ec *executionContext) marshalNImageIdentifier2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageIdentifier(ctx context.Context, sel ast.SelectionSet, v *ImageIdentifier) graphql.Marshaler { +func (ec *executionContext) marshalNImageIdentifier2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageIdentifier(ctx context.Context, sel ast.SelectionSet, v *ImageIdentifier) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10483,16 +10483,16 @@ func (ec *executionContext) marshalNImageIdentifier2ᚖzotregistryᚗdevᚋzot return ec._ImageIdentifier(ctx, sel, v) } -func (ec *executionContext) unmarshalNImageInput2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageInput(ctx context.Context, v any) (ImageInput, error) { +func (ec *executionContext) unmarshalNImageInput2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageInput(ctx context.Context, v any) (ImageInput, error) { res, err := ec.unmarshalInputImageInput(ctx, v) return res, graphql.ErrorOnPath(ctx, err) } -func (ec *executionContext) marshalNImageSummary2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v ImageSummary) graphql.Marshaler { +func (ec *executionContext) marshalNImageSummary2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v ImageSummary) graphql.Marshaler { return ec._ImageSummary(ctx, sel, &v) } -func (ec *executionContext) marshalNImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummaryᚄ(ctx context.Context, sel ast.SelectionSet, v []*ImageSummary) graphql.Marshaler { +func (ec *executionContext) marshalNImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummaryᚄ(ctx context.Context, sel ast.SelectionSet, v []*ImageSummary) graphql.Marshaler { ret := make(graphql.Array, len(v)) var wg sync.WaitGroup isLen1 := len(v) == 1 @@ -10516,7 +10516,7 @@ func (ec *executionContext) marshalNImageSummary2ᚕᚖzotregistryᚗdevᚋzot if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalNImageSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx, sel, v[i]) + ret[i] = ec.marshalNImageSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx, sel, v[i]) } if isLen1 { f(i) @@ -10536,7 +10536,7 @@ func (ec *executionContext) marshalNImageSummary2ᚕᚖzotregistryᚗdevᚋzot return ret } -func (ec *executionContext) marshalNImageSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v *ImageSummary) graphql.Marshaler { +func (ec *executionContext) marshalNImageSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v *ImageSummary) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10562,11 +10562,11 @@ func (ec *executionContext) marshalNInt2int(ctx context.Context, sel ast.Selecti return res } -func (ec *executionContext) marshalNPaginatedImagesResult2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult(ctx context.Context, sel ast.SelectionSet, v PaginatedImagesResult) graphql.Marshaler { +func (ec *executionContext) marshalNPaginatedImagesResult2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult(ctx context.Context, sel ast.SelectionSet, v PaginatedImagesResult) graphql.Marshaler { return ec._PaginatedImagesResult(ctx, sel, &v) } -func (ec *executionContext) marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult(ctx context.Context, sel ast.SelectionSet, v *PaginatedImagesResult) graphql.Marshaler { +func (ec *executionContext) marshalNPaginatedImagesResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedImagesResult(ctx context.Context, sel ast.SelectionSet, v *PaginatedImagesResult) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10576,11 +10576,11 @@ func (ec *executionContext) marshalNPaginatedImagesResult2ᚖzotregistryᚗdev return ec._PaginatedImagesResult(ctx, sel, v) } -func (ec *executionContext) marshalNPaginatedReposResult2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult(ctx context.Context, sel ast.SelectionSet, v PaginatedReposResult) graphql.Marshaler { +func (ec *executionContext) marshalNPaginatedReposResult2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult(ctx context.Context, sel ast.SelectionSet, v PaginatedReposResult) graphql.Marshaler { return ec._PaginatedReposResult(ctx, sel, &v) } -func (ec *executionContext) marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult(ctx context.Context, sel ast.SelectionSet, v *PaginatedReposResult) graphql.Marshaler { +func (ec *executionContext) marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPaginatedReposResult(ctx context.Context, sel ast.SelectionSet, v *PaginatedReposResult) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10590,7 +10590,7 @@ func (ec *executionContext) marshalNPaginatedReposResult2ᚖzotregistryᚗdevᚋ return ec._PaginatedReposResult(ctx, sel, v) } -func (ec *executionContext) marshalNReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx context.Context, sel ast.SelectionSet, v []*Referrer) graphql.Marshaler { +func (ec *executionContext) marshalNReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx context.Context, sel ast.SelectionSet, v []*Referrer) graphql.Marshaler { ret := make(graphql.Array, len(v)) var wg sync.WaitGroup isLen1 := len(v) == 1 @@ -10614,7 +10614,7 @@ func (ec *executionContext) marshalNReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkg if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOReferrer2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx, sel, v[i]) + ret[i] = ec.marshalOReferrer2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx, sel, v[i]) } if isLen1 { f(i) @@ -10628,11 +10628,11 @@ func (ec *executionContext) marshalNReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkg return ret } -func (ec *executionContext) marshalNRepoInfo2zotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoInfo(ctx context.Context, sel ast.SelectionSet, v RepoInfo) graphql.Marshaler { +func (ec *executionContext) marshalNRepoInfo2zotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoInfo(ctx context.Context, sel ast.SelectionSet, v RepoInfo) graphql.Marshaler { return ec._RepoInfo(ctx, sel, &v) } -func (ec *executionContext) marshalNRepoInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoInfo(ctx context.Context, sel ast.SelectionSet, v *RepoInfo) graphql.Marshaler { +func (ec *executionContext) marshalNRepoInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoInfo(ctx context.Context, sel ast.SelectionSet, v *RepoInfo) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10642,7 +10642,7 @@ func (ec *executionContext) marshalNRepoInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋ return ec._RepoInfo(ctx, sel, v) } -func (ec *executionContext) marshalNRepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummaryᚄ(ctx context.Context, sel ast.SelectionSet, v []*RepoSummary) graphql.Marshaler { +func (ec *executionContext) marshalNRepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummaryᚄ(ctx context.Context, sel ast.SelectionSet, v []*RepoSummary) graphql.Marshaler { ret := make(graphql.Array, len(v)) var wg sync.WaitGroup isLen1 := len(v) == 1 @@ -10666,7 +10666,7 @@ func (ec *executionContext) marshalNRepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋ if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalNRepoSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx, sel, v[i]) + ret[i] = ec.marshalNRepoSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx, sel, v[i]) } if isLen1 { f(i) @@ -10686,7 +10686,7 @@ func (ec *executionContext) marshalNRepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋ return ret } -func (ec *executionContext) marshalNRepoSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx context.Context, sel ast.SelectionSet, v *RepoSummary) graphql.Marshaler { +func (ec *executionContext) marshalNRepoSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx context.Context, sel ast.SelectionSet, v *RepoSummary) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { ec.Errorf(ctx, "the requested element is null which the schema does not allow") @@ -10965,7 +10965,7 @@ func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel a return res } -func (ec *executionContext) marshalOAnnotation2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation(ctx context.Context, sel ast.SelectionSet, v *Annotation) graphql.Marshaler { +func (ec *executionContext) marshalOAnnotation2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐAnnotation(ctx context.Context, sel ast.SelectionSet, v *Annotation) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11002,7 +11002,7 @@ func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast return res } -func (ec *executionContext) marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve(ctx context.Context, sel ast.SelectionSet, v []*Cve) graphql.Marshaler { +func (ec *executionContext) marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve(ctx context.Context, sel ast.SelectionSet, v []*Cve) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11029,7 +11029,7 @@ func (ec *executionContext) marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋex if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOCVE2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve(ctx, sel, v[i]) + ret[i] = ec.marshalOCVE2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11043,14 +11043,14 @@ func (ec *executionContext) marshalOCVE2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋex return ret } -func (ec *executionContext) marshalOCVE2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve(ctx context.Context, sel ast.SelectionSet, v *Cve) graphql.Marshaler { +func (ec *executionContext) marshalOCVE2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐCve(ctx context.Context, sel ast.SelectionSet, v *Cve) graphql.Marshaler { if v == nil { return graphql.Null } return ec._CVE(ctx, sel, v) } -func (ec *executionContext) unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter(ctx context.Context, v any) (*Filter, error) { +func (ec *executionContext) unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐFilter(ctx context.Context, v any) (*Filter, error) { if v == nil { return nil, nil } @@ -11058,14 +11058,14 @@ func (ec *executionContext) unmarshalOFilter2ᚖzotregistryᚗdevᚋzotᚋpkgᚋ return &res, graphql.ErrorOnPath(ctx, err) } -func (ec *executionContext) marshalOHistoryDescription2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐHistoryDescription(ctx context.Context, sel ast.SelectionSet, v *HistoryDescription) graphql.Marshaler { +func (ec *executionContext) marshalOHistoryDescription2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐHistoryDescription(ctx context.Context, sel ast.SelectionSet, v *HistoryDescription) graphql.Marshaler { if v == nil { return graphql.Null } return ec._HistoryDescription(ctx, sel, v) } -func (ec *executionContext) marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v []*ImageSummary) graphql.Marshaler { +func (ec *executionContext) marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v []*ImageSummary) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11092,7 +11092,7 @@ func (ec *executionContext) marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzot if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOImageSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx, sel, v[i]) + ret[i] = ec.marshalOImageSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11106,14 +11106,14 @@ func (ec *executionContext) marshalOImageSummary2ᚕᚖzotregistryᚗdevᚋzot return ret } -func (ec *executionContext) marshalOImageSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v *ImageSummary) graphql.Marshaler { +func (ec *executionContext) marshalOImageSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageSummary(ctx context.Context, sel ast.SelectionSet, v *ImageSummary) graphql.Marshaler { if v == nil { return graphql.Null } return ec._ImageSummary(ctx, sel, v) } -func (ec *executionContext) marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary(ctx context.Context, sel ast.SelectionSet, v *ImageVulnerabilitySummary) graphql.Marshaler { +func (ec *executionContext) marshalOImageVulnerabilitySummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐImageVulnerabilitySummary(ctx context.Context, sel ast.SelectionSet, v *ImageVulnerabilitySummary) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11138,7 +11138,7 @@ func (ec *executionContext) marshalOInt2ᚖint(ctx context.Context, sel ast.Sele return res } -func (ec *executionContext) marshalOLayerHistory2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory(ctx context.Context, sel ast.SelectionSet, v []*LayerHistory) graphql.Marshaler { +func (ec *executionContext) marshalOLayerHistory2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory(ctx context.Context, sel ast.SelectionSet, v []*LayerHistory) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11165,7 +11165,7 @@ func (ec *executionContext) marshalOLayerHistory2ᚕᚖzotregistryᚗdevᚋzot if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOLayerHistory2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory(ctx, sel, v[i]) + ret[i] = ec.marshalOLayerHistory2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11179,14 +11179,14 @@ func (ec *executionContext) marshalOLayerHistory2ᚕᚖzotregistryᚗdevᚋzot return ret } -func (ec *executionContext) marshalOLayerHistory2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory(ctx context.Context, sel ast.SelectionSet, v *LayerHistory) graphql.Marshaler { +func (ec *executionContext) marshalOLayerHistory2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerHistory(ctx context.Context, sel ast.SelectionSet, v *LayerHistory) graphql.Marshaler { if v == nil { return graphql.Null } return ec._LayerHistory(ctx, sel, v) } -func (ec *executionContext) marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary(ctx context.Context, sel ast.SelectionSet, v []*LayerSummary) graphql.Marshaler { +func (ec *executionContext) marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary(ctx context.Context, sel ast.SelectionSet, v []*LayerSummary) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11213,7 +11213,7 @@ func (ec *executionContext) marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzot if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOLayerSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary(ctx, sel, v[i]) + ret[i] = ec.marshalOLayerSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11227,14 +11227,14 @@ func (ec *executionContext) marshalOLayerSummary2ᚕᚖzotregistryᚗdevᚋzot return ret } -func (ec *executionContext) marshalOLayerSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary(ctx context.Context, sel ast.SelectionSet, v *LayerSummary) graphql.Marshaler { +func (ec *executionContext) marshalOLayerSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐLayerSummary(ctx context.Context, sel ast.SelectionSet, v *LayerSummary) graphql.Marshaler { if v == nil { return graphql.Null } return ec._LayerSummary(ctx, sel, v) } -func (ec *executionContext) marshalOManifestSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary(ctx context.Context, sel ast.SelectionSet, v []*ManifestSummary) graphql.Marshaler { +func (ec *executionContext) marshalOManifestSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary(ctx context.Context, sel ast.SelectionSet, v []*ManifestSummary) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11261,7 +11261,7 @@ func (ec *executionContext) marshalOManifestSummary2ᚕᚖzotregistryᚗdevᚋzo if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOManifestSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary(ctx, sel, v[i]) + ret[i] = ec.marshalOManifestSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11275,14 +11275,14 @@ func (ec *executionContext) marshalOManifestSummary2ᚕᚖzotregistryᚗdevᚋzo return ret } -func (ec *executionContext) marshalOManifestSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary(ctx context.Context, sel ast.SelectionSet, v *ManifestSummary) graphql.Marshaler { +func (ec *executionContext) marshalOManifestSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐManifestSummary(ctx context.Context, sel ast.SelectionSet, v *ManifestSummary) graphql.Marshaler { if v == nil { return graphql.Null } return ec._ManifestSummary(ctx, sel, v) } -func (ec *executionContext) marshalOPackageInfo2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo(ctx context.Context, sel ast.SelectionSet, v []*PackageInfo) graphql.Marshaler { +func (ec *executionContext) marshalOPackageInfo2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo(ctx context.Context, sel ast.SelectionSet, v []*PackageInfo) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11309,7 +11309,7 @@ func (ec *executionContext) marshalOPackageInfo2ᚕᚖzotregistryᚗdevᚋzotᚋ if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOPackageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo(ctx, sel, v[i]) + ret[i] = ec.marshalOPackageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11323,21 +11323,21 @@ func (ec *executionContext) marshalOPackageInfo2ᚕᚖzotregistryᚗdevᚋzotᚋ return ret } -func (ec *executionContext) marshalOPackageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo(ctx context.Context, sel ast.SelectionSet, v *PackageInfo) graphql.Marshaler { +func (ec *executionContext) marshalOPackageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPackageInfo(ctx context.Context, sel ast.SelectionSet, v *PackageInfo) graphql.Marshaler { if v == nil { return graphql.Null } return ec._PackageInfo(ctx, sel, v) } -func (ec *executionContext) marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo(ctx context.Context, sel ast.SelectionSet, v *PageInfo) graphql.Marshaler { +func (ec *executionContext) marshalOPageInfo2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInfo(ctx context.Context, sel ast.SelectionSet, v *PageInfo) graphql.Marshaler { if v == nil { return graphql.Null } return ec._PageInfo(ctx, sel, v) } -func (ec *executionContext) unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput(ctx context.Context, v any) (*PageInput, error) { +func (ec *executionContext) unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPageInput(ctx context.Context, v any) (*PageInput, error) { if v == nil { return nil, nil } @@ -11345,7 +11345,7 @@ func (ec *executionContext) unmarshalOPageInput2ᚖzotregistryᚗdevᚋzotᚋpkg return &res, graphql.ErrorOnPath(ctx, err) } -func (ec *executionContext) marshalOPlatform2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform(ctx context.Context, sel ast.SelectionSet, v []*Platform) graphql.Marshaler { +func (ec *executionContext) marshalOPlatform2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform(ctx context.Context, sel ast.SelectionSet, v []*Platform) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11372,7 +11372,7 @@ func (ec *executionContext) marshalOPlatform2ᚕᚖzotregistryᚗdevᚋzotᚋpkg if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform(ctx, sel, v[i]) + ret[i] = ec.marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11386,14 +11386,14 @@ func (ec *executionContext) marshalOPlatform2ᚕᚖzotregistryᚗdevᚋzotᚋpkg return ret } -func (ec *executionContext) marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform(ctx context.Context, sel ast.SelectionSet, v *Platform) graphql.Marshaler { +func (ec *executionContext) marshalOPlatform2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatform(ctx context.Context, sel ast.SelectionSet, v *Platform) graphql.Marshaler { if v == nil { return graphql.Null } return ec._Platform(ctx, sel, v) } -func (ec *executionContext) unmarshalOPlatformInput2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatformInput(ctx context.Context, v any) (*PlatformInput, error) { +func (ec *executionContext) unmarshalOPlatformInput2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐPlatformInput(ctx context.Context, v any) (*PlatformInput, error) { if v == nil { return nil, nil } @@ -11401,7 +11401,7 @@ func (ec *executionContext) unmarshalOPlatformInput2ᚖzotregistryᚗdevᚋzot return &res, graphql.ErrorOnPath(ctx, err) } -func (ec *executionContext) marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx context.Context, sel ast.SelectionSet, v []*Referrer) graphql.Marshaler { +func (ec *executionContext) marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx context.Context, sel ast.SelectionSet, v []*Referrer) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11428,7 +11428,7 @@ func (ec *executionContext) marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkg if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOReferrer2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx, sel, v[i]) + ret[i] = ec.marshalOReferrer2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11442,14 +11442,14 @@ func (ec *executionContext) marshalOReferrer2ᚕᚖzotregistryᚗdevᚋzotᚋpkg return ret } -func (ec *executionContext) marshalOReferrer2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx context.Context, sel ast.SelectionSet, v *Referrer) graphql.Marshaler { +func (ec *executionContext) marshalOReferrer2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐReferrer(ctx context.Context, sel ast.SelectionSet, v *Referrer) graphql.Marshaler { if v == nil { return graphql.Null } return ec._Referrer(ctx, sel, v) } -func (ec *executionContext) marshalORepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx context.Context, sel ast.SelectionSet, v []*RepoSummary) graphql.Marshaler { +func (ec *executionContext) marshalORepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx context.Context, sel ast.SelectionSet, v []*RepoSummary) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11476,7 +11476,7 @@ func (ec *executionContext) marshalORepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋ if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalORepoSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx, sel, v[i]) + ret[i] = ec.marshalORepoSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11490,14 +11490,14 @@ func (ec *executionContext) marshalORepoSummary2ᚕᚖzotregistryᚗdevᚋzotᚋ return ret } -func (ec *executionContext) marshalORepoSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx context.Context, sel ast.SelectionSet, v *RepoSummary) graphql.Marshaler { +func (ec *executionContext) marshalORepoSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐRepoSummary(ctx context.Context, sel ast.SelectionSet, v *RepoSummary) graphql.Marshaler { if v == nil { return graphql.Null } return ec._RepoSummary(ctx, sel, v) } -func (ec *executionContext) marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary(ctx context.Context, sel ast.SelectionSet, v []*SignatureSummary) graphql.Marshaler { +func (ec *executionContext) marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary(ctx context.Context, sel ast.SelectionSet, v []*SignatureSummary) graphql.Marshaler { if v == nil { return graphql.Null } @@ -11524,7 +11524,7 @@ func (ec *executionContext) marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋz if !isLen1 { defer wg.Done() } - ret[i] = ec.marshalOSignatureSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary(ctx, sel, v[i]) + ret[i] = ec.marshalOSignatureSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary(ctx, sel, v[i]) } if isLen1 { f(i) @@ -11538,14 +11538,14 @@ func (ec *executionContext) marshalOSignatureSummary2ᚕᚖzotregistryᚗdevᚋz return ret } -func (ec *executionContext) marshalOSignatureSummary2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary(ctx context.Context, sel ast.SelectionSet, v *SignatureSummary) graphql.Marshaler { +func (ec *executionContext) marshalOSignatureSummary2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSignatureSummary(ctx context.Context, sel ast.SelectionSet, v *SignatureSummary) graphql.Marshaler { if v == nil { return graphql.Null } return ec._SignatureSummary(ctx, sel, v) } -func (ec *executionContext) unmarshalOSortCriteria2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSortCriteria(ctx context.Context, v any) (*SortCriteria, error) { +func (ec *executionContext) unmarshalOSortCriteria2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSortCriteria(ctx context.Context, v any) (*SortCriteria, error) { if v == nil { return nil, nil } @@ -11554,7 +11554,7 @@ func (ec *executionContext) unmarshalOSortCriteria2ᚖzotregistryᚗdevᚋzotᚋ return res, graphql.ErrorOnPath(ctx, err) } -func (ec *executionContext) marshalOSortCriteria2ᚖzotregistryᚗdevᚋzotᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSortCriteria(ctx context.Context, sel ast.SelectionSet, v *SortCriteria) graphql.Marshaler { +func (ec *executionContext) marshalOSortCriteria2ᚖzotregistryᚗdevᚋzotᚋv2ᚋpkgᚋextensionsᚋsearchᚋgql_generatedᚐSortCriteria(ctx context.Context, sel ast.SelectionSet, v *SortCriteria) graphql.Marshaler { if v == nil { return graphql.Null } diff --git a/pkg/extensions/search/gqlgen.yml b/pkg/extensions/search/gqlgen.yml index 0768cd47..63e9e039 100644 --- a/pkg/extensions/search/gqlgen.yml +++ b/pkg/extensions/search/gqlgen.yml @@ -42,7 +42,7 @@ resolver: # gqlgen will search for any type names in the schema in these go packages # if they match it will use them, otherwise it will generate them. autobind: -# - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" +# - "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" # This section declares type mapping between the GraphQL and go type systems # diff --git a/pkg/extensions/search/pagination/image_pagination.go b/pkg/extensions/search/pagination/image_pagination.go index eb9a02be..2989cf18 100644 --- a/pkg/extensions/search/pagination/image_pagination.go +++ b/pkg/extensions/search/pagination/image_pagination.go @@ -5,9 +5,9 @@ import ( "sort" "time" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - gql_gen "zotregistry.dev/zot/pkg/extensions/search/gql_generated" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + gql_gen "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" ) type ImageSummariesPageFinder struct { diff --git a/pkg/extensions/search/pagination/pagination_test.go b/pkg/extensions/search/pagination/pagination_test.go index 2a024e1d..32b65fe2 100644 --- a/pkg/extensions/search/pagination/pagination_test.go +++ b/pkg/extensions/search/pagination/pagination_test.go @@ -8,8 +8,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - "zotregistry.dev/zot/pkg/extensions/search/pagination" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + "zotregistry.dev/zot/v2/pkg/extensions/search/pagination" ) func TestImgSumPagination(t *testing.T) { diff --git a/pkg/extensions/search/pagination/repo_pagination.go b/pkg/extensions/search/pagination/repo_pagination.go index e27982d4..209b1057 100644 --- a/pkg/extensions/search/pagination/repo_pagination.go +++ b/pkg/extensions/search/pagination/repo_pagination.go @@ -4,9 +4,9 @@ import ( "fmt" "sort" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - gql_gen "zotregistry.dev/zot/pkg/extensions/search/gql_generated" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + gql_gen "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" ) type RepoSummariesPageFinder struct { diff --git a/pkg/extensions/search/resolver.go b/pkg/extensions/search/resolver.go index c3366cda..a82c48e6 100644 --- a/pkg/extensions/search/resolver.go +++ b/pkg/extensions/search/resolver.go @@ -15,17 +15,17 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/vektah/gqlparser/v2/gqlerror" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/search/convert" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - "zotregistry.dev/zot/pkg/extensions/search/pagination" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - "zotregistry.dev/zot/pkg/storage" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/search/convert" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + "zotregistry.dev/zot/v2/pkg/extensions/search/pagination" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + "zotregistry.dev/zot/v2/pkg/storage" ) // THIS CODE IS A STARTING POINT ONLY. IT WILL NOT BE UPDATED WITH SCHEMA CHANGES. diff --git a/pkg/extensions/search/resolver_test.go b/pkg/extensions/search/resolver_test.go index 3207fc38..66eb6364 100644 --- a/pkg/extensions/search/resolver_test.go +++ b/pkg/extensions/search/resolver_test.go @@ -15,21 +15,21 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/search/convert" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/boltdb" - mConvert "zotregistry.dev/zot/pkg/meta/convert" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - "zotregistry.dev/zot/pkg/storage" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/search/convert" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + mConvert "zotregistry.dev/zot/v2/pkg/meta/convert" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + "zotregistry.dev/zot/v2/pkg/storage" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) var ErrTestError = errors.New("TestError") diff --git a/pkg/extensions/search/schema.resolvers.go b/pkg/extensions/search/schema.resolvers.go index 75c94473..a356eefe 100644 --- a/pkg/extensions/search/schema.resolvers.go +++ b/pkg/extensions/search/schema.resolvers.go @@ -8,10 +8,10 @@ import ( "context" "github.com/vektah/gqlparser/v2/gqlerror" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/search/convert" - "zotregistry.dev/zot/pkg/extensions/search/gql_generated" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/search/convert" + "zotregistry.dev/zot/v2/pkg/extensions/search/gql_generated" ) // CVEListForImage is the resolver for the CVEListForImage field. diff --git a/pkg/extensions/search/search_test.go b/pkg/extensions/search/search_test.go index cc9f2859..7ae097bc 100644 --- a/pkg/extensions/search/search_test.go +++ b/pkg/extensions/search/search_test.go @@ -28,26 +28,26 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - cveinfo "zotregistry.dev/zot/pkg/extensions/search/cve" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - . "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" - "zotregistry.dev/zot/pkg/test/signature" - tskip "zotregistry.dev/zot/pkg/test/skip" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + cveinfo "zotregistry.dev/zot/v2/pkg/extensions/search/cve" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + . "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) const ( diff --git a/pkg/extensions/search/userprefs_test.go b/pkg/extensions/search/userprefs_test.go index 42a4f798..77807dad 100644 --- a/pkg/extensions/search/userprefs_test.go +++ b/pkg/extensions/search/userprefs_test.go @@ -13,15 +13,15 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/log" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - . "zotregistry.dev/zot/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/log" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + . "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) //nolint:dupl diff --git a/pkg/extensions/sync/content.go b/pkg/extensions/sync/content.go index 1be12124..4ba4c318 100644 --- a/pkg/extensions/sync/content.go +++ b/pkg/extensions/sync/content.go @@ -10,9 +10,9 @@ import ( "github.com/Masterminds/semver" glob "github.com/bmatcuk/doublestar/v4" - "zotregistry.dev/zot/pkg/common" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/common" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/log" ) /* ContentManager uses registry content configuration to filter repos/tags diff --git a/pkg/extensions/sync/content_test.go b/pkg/extensions/sync/content_test.go index 63a5c4c2..b231b3f3 100644 --- a/pkg/extensions/sync/content_test.go +++ b/pkg/extensions/sync/content_test.go @@ -8,9 +8,9 @@ import ( . "github.com/smartystreets/goconvey/convey" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/extensions/sync" - "zotregistry.dev/zot/pkg/log" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/extensions/sync" + "zotregistry.dev/zot/v2/pkg/log" ) func TestContentManager(t *testing.T) { diff --git a/pkg/extensions/sync/destination.go b/pkg/extensions/sync/destination.go index 057c07f5..784fb352 100644 --- a/pkg/extensions/sync/destination.go +++ b/pkg/extensions/sync/destination.go @@ -17,16 +17,16 @@ import ( "github.com/regclient/regclient/types/mediatype" "github.com/regclient/regclient/types/ref" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - storageCommon "zotregistry.dev/zot/pkg/storage/common" - "zotregistry.dev/zot/pkg/storage/local" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + storageCommon "zotregistry.dev/zot/v2/pkg/storage/common" + "zotregistry.dev/zot/v2/pkg/storage/local" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) type DestinationRegistry struct { diff --git a/pkg/extensions/sync/ecr_credential_helper.go b/pkg/extensions/sync/ecr_credential_helper.go index 4fd7b9fc..5e5395e9 100644 --- a/pkg/extensions/sync/ecr_credential_helper.go +++ b/pkg/extensions/sync/ecr_credential_helper.go @@ -14,8 +14,8 @@ import ( "github.com/aws/aws-sdk-go-v2/config" "github.com/aws/aws-sdk-go-v2/service/ecr" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/log" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/log" ) // ECR tokens are valid for 12 hours. The expiryWindow variable is set to 1 hour, diff --git a/pkg/extensions/sync/oci_layout.go b/pkg/extensions/sync/oci_layout.go index 0e4850b3..50f5ef37 100644 --- a/pkg/extensions/sync/oci_layout.go +++ b/pkg/extensions/sync/oci_layout.go @@ -10,10 +10,10 @@ import ( "github.com/gofrs/uuid" "github.com/regclient/regclient/types/ref" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/extensions/sync/constants" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/test/inject" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/extensions/sync/constants" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/test/inject" ) type OciLayoutStorageImpl struct { diff --git a/pkg/extensions/sync/on_demand.go b/pkg/extensions/sync/on_demand.go index 0e0f0036..d5619687 100644 --- a/pkg/extensions/sync/on_demand.go +++ b/pkg/extensions/sync/on_demand.go @@ -8,9 +8,9 @@ import ( "errors" "sync" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" ) type request struct { diff --git a/pkg/extensions/sync/referrers.go b/pkg/extensions/sync/referrers.go index a30d0af2..8c6a5234 100644 --- a/pkg/extensions/sync/referrers.go +++ b/pkg/extensions/sync/referrers.go @@ -7,7 +7,7 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/regclient/regclient/types/referrer" - "zotregistry.dev/zot/pkg/common" + "zotregistry.dev/zot/v2/pkg/common" ) const ( diff --git a/pkg/extensions/sync/remote.go b/pkg/extensions/sync/remote.go index 4dc760c0..07d6aa26 100644 --- a/pkg/extensions/sync/remote.go +++ b/pkg/extensions/sync/remote.go @@ -20,9 +20,9 @@ import ( "github.com/regclient/regclient/types/ref" "github.com/regclient/regclient/types/repo" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/log" ) type RemoteRegistry struct { diff --git a/pkg/extensions/sync/service.go b/pkg/extensions/sync/service.go index 9aaee7f3..e450ef82 100644 --- a/pkg/extensions/sync/service.go +++ b/pkg/extensions/sync/service.go @@ -20,15 +20,15 @@ import ( "github.com/regclient/regclient/scheme/reg" "github.com/regclient/regclient/types/ref" - zerr "zotregistry.dev/zot/errors" - zconfig "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/cluster" - "zotregistry.dev/zot/pkg/common" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" + zerr "zotregistry.dev/zot/v2/errors" + zconfig "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/cluster" + "zotregistry.dev/zot/v2/pkg/common" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" ) const defaultExpireMinutes = 30 * time.Minute diff --git a/pkg/extensions/sync/sync.go b/pkg/extensions/sync/sync.go index 88108b79..aee2cf1e 100644 --- a/pkg/extensions/sync/sync.go +++ b/pkg/extensions/sync/sync.go @@ -12,9 +12,9 @@ import ( godigest "github.com/opencontainers/go-digest" "github.com/regclient/regclient/types/ref" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" ) // below types are used by regclient to copy images diff --git a/pkg/extensions/sync/sync_disabled_test.go b/pkg/extensions/sync/sync_disabled_test.go index f9a274c6..458ece0e 100644 --- a/pkg/extensions/sync/sync_disabled_test.go +++ b/pkg/extensions/sync/sync_disabled_test.go @@ -10,11 +10,11 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + test "zotregistry.dev/zot/v2/pkg/test/common" ) func TestSyncExtension(t *testing.T) { diff --git a/pkg/extensions/sync/sync_internal_test.go b/pkg/extensions/sync/sync_internal_test.go index 5b983f72..b8773d0b 100644 --- a/pkg/extensions/sync/sync_internal_test.go +++ b/pkg/extensions/sync/sync_internal_test.go @@ -17,19 +17,19 @@ import ( "github.com/regclient/regclient/types/ref" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/extensions/config" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/extensions/lint" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/local" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/extensions/config" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/extensions/lint" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/local" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) func TestService(t *testing.T) { diff --git a/pkg/extensions/sync/sync_test.go b/pkg/extensions/sync/sync_test.go index 89da59c7..997dbe4c 100644 --- a/pkg/extensions/sync/sync_test.go +++ b/pkg/extensions/sync/sync_test.go @@ -35,24 +35,24 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - cli "zotregistry.dev/zot/pkg/cli/server" - zcommon "zotregistry.dev/zot/pkg/common" - extconf "zotregistry.dev/zot/pkg/extensions/config" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" - "zotregistry.dev/zot/pkg/extensions/sync" - syncConstants "zotregistry.dev/zot/pkg/extensions/sync/constants" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - authutils "zotregistry.dev/zot/pkg/test/auth" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" - "zotregistry.dev/zot/pkg/test/signature" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + cli "zotregistry.dev/zot/v2/pkg/cli/server" + zcommon "zotregistry.dev/zot/v2/pkg/common" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" + "zotregistry.dev/zot/v2/pkg/extensions/sync" + syncConstants "zotregistry.dev/zot/v2/pkg/extensions/sync/constants" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + authutils "zotregistry.dev/zot/v2/pkg/test/auth" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" ) const ( diff --git a/pkg/extensions/sync/utils.go b/pkg/extensions/sync/utils.go index 95281344..fb82a78a 100644 --- a/pkg/extensions/sync/utils.go +++ b/pkg/extensions/sync/utils.go @@ -13,7 +13,7 @@ import ( "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - syncconf "zotregistry.dev/zot/pkg/extensions/config/sync" + syncconf "zotregistry.dev/zot/v2/pkg/extensions/config/sync" ) // Get sync.FileCredentials from file. diff --git a/pkg/log/log.go b/pkg/log/log.go index c3d35f11..25b6ad75 100644 --- a/pkg/log/log.go +++ b/pkg/log/log.go @@ -11,7 +11,7 @@ import ( "strings" "time" - "zotregistry.dev/zot/errors" + "zotregistry.dev/zot/v2/errors" ) const ( diff --git a/pkg/log/log_test.go b/pkg/log/log_test.go index 8822241b..f9f23de0 100644 --- a/pkg/log/log_test.go +++ b/pkg/log/log_test.go @@ -19,11 +19,11 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/api/constants" - "zotregistry.dev/zot/pkg/log" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/api/constants" + "zotregistry.dev/zot/v2/pkg/log" + test "zotregistry.dev/zot/v2/pkg/test/common" ) type AuditLog struct { diff --git a/pkg/meta/boltdb/boltdb.go b/pkg/meta/boltdb/boltdb.go index 32be0b77..cbf6bb4f 100644 --- a/pkg/meta/boltdb/boltdb.go +++ b/pkg/meta/boltdb/boltdb.go @@ -14,17 +14,17 @@ import ( "google.golang.org/protobuf/proto" "google.golang.org/protobuf/types/known/timestamppb" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/common" - mConvert "zotregistry.dev/zot/pkg/meta/convert" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/meta/version" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/common" + mConvert "zotregistry.dev/zot/v2/pkg/meta/convert" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/meta/version" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" ) type BoltDB struct { diff --git a/pkg/meta/boltdb/boltdb_test.go b/pkg/meta/boltdb/boltdb_test.go index 56a66a57..cc35fff3 100644 --- a/pkg/meta/boltdb/boltdb_test.go +++ b/pkg/meta/boltdb/boltdb_test.go @@ -14,13 +14,13 @@ import ( "go.etcd.io/bbolt" "google.golang.org/protobuf/proto" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/boltdb" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - . "zotregistry.dev/zot/pkg/test/image-utils" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) type imgTrustStore struct{} diff --git a/pkg/meta/common/common.go b/pkg/meta/common/common.go index 67aefd3b..c9f69663 100644 --- a/pkg/meta/common/common.go +++ b/pkg/meta/common/common.go @@ -7,11 +7,11 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - mConvert "zotregistry.dev/zot/pkg/meta/convert" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - mTypes "zotregistry.dev/zot/pkg/meta/types" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + mConvert "zotregistry.dev/zot/v2/pkg/meta/convert" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) func SignatureAlreadyExists(signatureSlice []mTypes.SignatureInfo, sm mTypes.SignatureMetadata) bool { diff --git a/pkg/meta/common/common_test.go b/pkg/meta/common/common_test.go index 39c010d8..125a5327 100644 --- a/pkg/meta/common/common_test.go +++ b/pkg/meta/common/common_test.go @@ -7,8 +7,8 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/meta/common" - mTypes "zotregistry.dev/zot/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/meta/common" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) var ErrTestError = errors.New("test error") diff --git a/pkg/meta/convert/convert.go b/pkg/meta/convert/convert.go index b5a3798e..fb75b171 100644 --- a/pkg/meta/convert/convert.go +++ b/pkg/meta/convert/convert.go @@ -8,10 +8,10 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "google.golang.org/protobuf/types/known/timestamppb" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - mTypes "zotregistry.dev/zot/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) func GetHistory(history []*proto_go.History) []ispec.History { diff --git a/pkg/meta/convert/convert_proto.go b/pkg/meta/convert/convert_proto.go index b8985be3..f0f3493a 100644 --- a/pkg/meta/convert/convert_proto.go +++ b/pkg/meta/convert/convert_proto.go @@ -7,9 +7,9 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "google.golang.org/protobuf/types/known/timestamppb" - "zotregistry.dev/zot/pkg/common" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - mTypes "zotregistry.dev/zot/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/common" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) func GetProtoRepoMeta(repo mTypes.RepoMeta) *proto_go.RepoMeta { diff --git a/pkg/meta/convert/convert_test.go b/pkg/meta/convert/convert_test.go index b6a40274..af97dbe8 100644 --- a/pkg/meta/convert/convert_test.go +++ b/pkg/meta/convert/convert_test.go @@ -7,8 +7,8 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/meta/convert" - "zotregistry.dev/zot/pkg/meta/proto/gen" + "zotregistry.dev/zot/v2/pkg/meta/convert" + "zotregistry.dev/zot/v2/pkg/meta/proto/gen" ) func TestConvertErrors(t *testing.T) { diff --git a/pkg/meta/dynamodb/dynamodb.go b/pkg/meta/dynamodb/dynamodb.go index 9e2e31c4..a1d316fb 100644 --- a/pkg/meta/dynamodb/dynamodb.go +++ b/pkg/meta/dynamodb/dynamodb.go @@ -16,17 +16,17 @@ import ( "google.golang.org/protobuf/proto" "google.golang.org/protobuf/types/known/timestamppb" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/common" - mConvert "zotregistry.dev/zot/pkg/meta/convert" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/meta/version" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/common" + mConvert "zotregistry.dev/zot/v2/pkg/meta/convert" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/meta/version" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" ) type DynamoDB struct { diff --git a/pkg/meta/dynamodb/dynamodb_internal_test.go b/pkg/meta/dynamodb/dynamodb_internal_test.go index dbd37364..abde6b9c 100644 --- a/pkg/meta/dynamodb/dynamodb_internal_test.go +++ b/pkg/meta/dynamodb/dynamodb_internal_test.go @@ -11,9 +11,9 @@ import ( guuid "github.com/gofrs/uuid" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/version" - tskip "zotregistry.dev/zot/pkg/test/skip" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/version" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) func TestWrapperErrors(t *testing.T) { diff --git a/pkg/meta/dynamodb/dynamodb_test.go b/pkg/meta/dynamodb/dynamodb_test.go index b987a220..41bcf040 100644 --- a/pkg/meta/dynamodb/dynamodb_test.go +++ b/pkg/meta/dynamodb/dynamodb_test.go @@ -16,13 +16,13 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/extensions/imagetrust" - "zotregistry.dev/zot/pkg/log" - mdynamodb "zotregistry.dev/zot/pkg/meta/dynamodb" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - . "zotregistry.dev/zot/pkg/test/image-utils" - tskip "zotregistry.dev/zot/pkg/test/skip" + "zotregistry.dev/zot/v2/pkg/extensions/imagetrust" + "zotregistry.dev/zot/v2/pkg/log" + mdynamodb "zotregistry.dev/zot/v2/pkg/meta/dynamodb" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) const badTablename = "bad tablename" diff --git a/pkg/meta/dynamodb/iterator.go b/pkg/meta/dynamodb/iterator.go index 93f19246..afd1c13b 100644 --- a/pkg/meta/dynamodb/iterator.go +++ b/pkg/meta/dynamodb/iterator.go @@ -7,7 +7,7 @@ import ( "github.com/aws/aws-sdk-go-v2/service/dynamodb" "github.com/aws/aws-sdk-go-v2/service/dynamodb/types" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) type AttributesIterator interface { diff --git a/pkg/meta/hooks.go b/pkg/meta/hooks.go index 98660c55..186dcd3d 100644 --- a/pkg/meta/hooks.go +++ b/pkg/meta/hooks.go @@ -6,11 +6,11 @@ import ( godigest "github.com/opencontainers/go-digest" v1 "github.com/opencontainers/image-spec/specs-go/v1" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" ) // OnUpdateManifest is called when a new manifest is added. It updates metadb according to the type diff --git a/pkg/meta/hooks_test.go b/pkg/meta/hooks_test.go index 75720ed9..fefcc5ee 100644 --- a/pkg/meta/hooks_test.go +++ b/pkg/meta/hooks_test.go @@ -8,14 +8,14 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrTestError = errors.New("test error") diff --git a/pkg/meta/meta.go b/pkg/meta/meta.go index 522a5390..35be9408 100644 --- a/pkg/meta/meta.go +++ b/pkg/meta/meta.go @@ -3,15 +3,15 @@ package meta import ( "fmt" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/boltdb" - mdynamodb "zotregistry.dev/zot/pkg/meta/dynamodb" - "zotregistry.dev/zot/pkg/meta/redis" - mTypes "zotregistry.dev/zot/pkg/meta/types" - sconstants "zotregistry.dev/zot/pkg/storage/constants" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + mdynamodb "zotregistry.dev/zot/v2/pkg/meta/dynamodb" + "zotregistry.dev/zot/v2/pkg/meta/redis" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + sconstants "zotregistry.dev/zot/v2/pkg/storage/constants" ) func New(storageConfig config.StorageConfig, log log.Logger) (mTypes.MetaDB, error) { diff --git a/pkg/meta/meta_test.go b/pkg/meta/meta_test.go index 08764cdf..93606df8 100644 --- a/pkg/meta/meta_test.go +++ b/pkg/meta/meta_test.go @@ -22,24 +22,24 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/imagetrust" - "zotregistry.dev/zot/pkg/extensions/search/convert" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - "zotregistry.dev/zot/pkg/meta/common" - mdynamodb "zotregistry.dev/zot/pkg/meta/dynamodb" - "zotregistry.dev/zot/pkg/meta/redis" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - tCommon "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/signature" - tskip "zotregistry.dev/zot/pkg/test/skip" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/imagetrust" + "zotregistry.dev/zot/v2/pkg/extensions/search/convert" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + "zotregistry.dev/zot/v2/pkg/meta/common" + mdynamodb "zotregistry.dev/zot/v2/pkg/meta/dynamodb" + "zotregistry.dev/zot/v2/pkg/meta/redis" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + tCommon "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) const ( diff --git a/pkg/meta/parse.go b/pkg/meta/parse.go index 7bc4c628..2f469e0d 100644 --- a/pkg/meta/parse.go +++ b/pkg/meta/parse.go @@ -9,13 +9,13 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/convert" - mTypes "zotregistry.dev/zot/pkg/meta/types" - stypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/convert" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + stypes "zotregistry.dev/zot/v2/pkg/storage/types" ) const ( diff --git a/pkg/meta/parse_test.go b/pkg/meta/parse_test.go index fd728fa7..ba5c792a 100644 --- a/pkg/meta/parse_test.go +++ b/pkg/meta/parse_test.go @@ -16,24 +16,24 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - "zotregistry.dev/zot/pkg/meta/dynamodb" - "zotregistry.dev/zot/pkg/meta/redis" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - tcommon "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" - "zotregistry.dev/zot/pkg/test/signature" - tskip "zotregistry.dev/zot/pkg/test/skip" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + "zotregistry.dev/zot/v2/pkg/meta/dynamodb" + "zotregistry.dev/zot/v2/pkg/meta/redis" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) const repo = "repo" diff --git a/pkg/meta/redis/redis.go b/pkg/meta/redis/redis.go index b8d623f9..b01cd268 100644 --- a/pkg/meta/redis/redis.go +++ b/pkg/meta/redis/redis.go @@ -16,17 +16,17 @@ import ( "google.golang.org/protobuf/proto" "google.golang.org/protobuf/types/known/timestamppb" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/common" - mConvert "zotregistry.dev/zot/pkg/meta/convert" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/meta/version" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/common" + mConvert "zotregistry.dev/zot/v2/pkg/meta/convert" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/meta/version" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" ) const ( diff --git a/pkg/meta/redis/redis_internal_test.go b/pkg/meta/redis/redis_internal_test.go index 3cc795ad..831dc2b2 100644 --- a/pkg/meta/redis/redis_internal_test.go +++ b/pkg/meta/redis/redis_internal_test.go @@ -7,7 +7,7 @@ import ( "github.com/redis/go-redis/v9" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/log" ) func Test(t *testing.T) { diff --git a/pkg/meta/redis/redis_test.go b/pkg/meta/redis/redis_test.go index 311d0072..c2996c7e 100644 --- a/pkg/meta/redis/redis_test.go +++ b/pkg/meta/redis/redis_test.go @@ -16,13 +16,13 @@ import ( . "github.com/smartystreets/goconvey/convey" "google.golang.org/protobuf/proto" - "zotregistry.dev/zot/pkg/log" - proto_go "zotregistry.dev/zot/pkg/meta/proto/gen" - "zotregistry.dev/zot/pkg/meta/redis" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - test "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/log" + proto_go "zotregistry.dev/zot/v2/pkg/meta/proto/gen" + "zotregistry.dev/zot/v2/pkg/meta/redis" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + test "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) const keyPrefix = "zot" diff --git a/pkg/meta/version/version_test.go b/pkg/meta/version/version_test.go index 0d782909..0da2027f 100644 --- a/pkg/meta/version/version_test.go +++ b/pkg/meta/version/version_test.go @@ -18,12 +18,12 @@ import ( . "github.com/smartystreets/goconvey/convey" "go.etcd.io/bbolt" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/boltdb" - mdynamodb "zotregistry.dev/zot/pkg/meta/dynamodb" - "zotregistry.dev/zot/pkg/meta/redis" - "zotregistry.dev/zot/pkg/meta/version" - tskip "zotregistry.dev/zot/pkg/test/skip" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + mdynamodb "zotregistry.dev/zot/v2/pkg/meta/dynamodb" + "zotregistry.dev/zot/v2/pkg/meta/redis" + "zotregistry.dev/zot/v2/pkg/meta/version" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) var ErrTestError = errors.New("test error") diff --git a/pkg/requestcontext/authn.go b/pkg/requestcontext/authn.go index cc4a3416..89a82ad3 100644 --- a/pkg/requestcontext/authn.go +++ b/pkg/requestcontext/authn.go @@ -3,7 +3,7 @@ package uac import ( "context" - "zotregistry.dev/zot/errors" + "zotregistry.dev/zot/v2/errors" ) // request-local context key. diff --git a/pkg/requestcontext/user_access_control.go b/pkg/requestcontext/user_access_control.go index 794111f7..c0065b3e 100644 --- a/pkg/requestcontext/user_access_control.go +++ b/pkg/requestcontext/user_access_control.go @@ -6,8 +6,8 @@ import ( glob "github.com/bmatcuk/doublestar/v4" //nolint:gci - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/constants" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/constants" ) type Key int diff --git a/pkg/retention/candidate.go b/pkg/retention/candidate.go index 73abc172..ad470414 100644 --- a/pkg/retention/candidate.go +++ b/pkg/retention/candidate.go @@ -3,8 +3,8 @@ package retention import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/retention/types" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/retention/types" ) func GetCandidates(repoMeta mTypes.RepoMeta) []*types.Candidate { diff --git a/pkg/retention/retention.go b/pkg/retention/retention.go index 510f19ba..bcc16f16 100644 --- a/pkg/retention/retention.go +++ b/pkg/retention/retention.go @@ -7,12 +7,12 @@ import ( glob "github.com/bmatcuk/doublestar/v4" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - zlog "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/retention/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + zlog "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/retention/types" ) const ( diff --git a/pkg/retention/rules.go b/pkg/retention/rules.go index 51be0119..0be888c8 100644 --- a/pkg/retention/rules.go +++ b/pkg/retention/rules.go @@ -5,7 +5,7 @@ import ( "sort" "time" - "zotregistry.dev/zot/pkg/retention/types" + "zotregistry.dev/zot/v2/pkg/retention/types" ) const ( diff --git a/pkg/retention/types/types.go b/pkg/retention/types/types.go index 6686d38f..3d77b7a1 100644 --- a/pkg/retention/types/types.go +++ b/pkg/retention/types/types.go @@ -6,7 +6,7 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" - mTypes "zotregistry.dev/zot/pkg/meta/types" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) type Candidate struct { diff --git a/pkg/scheduler/scheduler.go b/pkg/scheduler/scheduler.go index 83a358d0..ea2ab9ed 100644 --- a/pkg/scheduler/scheduler.go +++ b/pkg/scheduler/scheduler.go @@ -9,9 +9,9 @@ import ( "sync/atomic" "time" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" ) type Task interface { diff --git a/pkg/scheduler/scheduler_test.go b/pkg/scheduler/scheduler_test.go index 0a4b1068..89a537fe 100644 --- a/pkg/scheduler/scheduler_test.go +++ b/pkg/scheduler/scheduler_test.go @@ -12,10 +12,10 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" ) type task struct { diff --git a/pkg/storage/cache.go b/pkg/storage/cache.go index b5bd8afd..c1d579fa 100644 --- a/pkg/storage/cache.go +++ b/pkg/storage/cache.go @@ -3,13 +3,13 @@ package storage import ( "fmt" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage/cache" - "zotregistry.dev/zot/pkg/storage/constants" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage/cache" + "zotregistry.dev/zot/v2/pkg/storage/constants" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) func CreateCacheDatabaseDriver(storageConfig config.StorageConfig, log zlog.Logger) (storageTypes.Cache, error) { diff --git a/pkg/storage/cache/boltdb.go b/pkg/storage/cache/boltdb.go index 8d0fc8be..fae73c45 100644 --- a/pkg/storage/cache/boltdb.go +++ b/pkg/storage/cache/boltdb.go @@ -10,9 +10,9 @@ import ( godigest "github.com/opencontainers/go-digest" "go.etcd.io/bbolt" - zerr "zotregistry.dev/zot/errors" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage/constants" + zerr "zotregistry.dev/zot/v2/errors" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage/constants" ) type BoltDBDriver struct { diff --git a/pkg/storage/cache/boltdb_internal_test.go b/pkg/storage/cache/boltdb_internal_test.go index 917c6dd4..a6642fe3 100644 --- a/pkg/storage/cache/boltdb_internal_test.go +++ b/pkg/storage/cache/boltdb_internal_test.go @@ -9,8 +9,8 @@ import ( . "github.com/smartystreets/goconvey/convey" "go.etcd.io/bbolt" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage/constants" ) func TestBoltDriverErrors(t *testing.T) { diff --git a/pkg/storage/cache/boltdb_test.go b/pkg/storage/cache/boltdb_test.go index 8160c72a..8d46bfa3 100644 --- a/pkg/storage/cache/boltdb_test.go +++ b/pkg/storage/cache/boltdb_test.go @@ -6,10 +6,10 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" ) func TestBoltDBCache(t *testing.T) { diff --git a/pkg/storage/cache/dynamodb.go b/pkg/storage/cache/dynamodb.go index 6f536145..d3111ea7 100644 --- a/pkg/storage/cache/dynamodb.go +++ b/pkg/storage/cache/dynamodb.go @@ -11,8 +11,8 @@ import ( "github.com/aws/aws-sdk-go-v2/service/dynamodb/types" godigest "github.com/opencontainers/go-digest" - zerr "zotregistry.dev/zot/errors" - zlog "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + zlog "zotregistry.dev/zot/v2/pkg/log" ) type DynamoDBDriver struct { diff --git a/pkg/storage/cache/dynamodb_test.go b/pkg/storage/cache/dynamodb_test.go index b587ea18..5a4dc3c1 100644 --- a/pkg/storage/cache/dynamodb_test.go +++ b/pkg/storage/cache/dynamodb_test.go @@ -8,10 +8,10 @@ import ( godigest "github.com/opencontainers/go-digest" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - tskip "zotregistry.dev/zot/pkg/test/skip" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) func TestDynamoDB(t *testing.T) { diff --git a/pkg/storage/cache/redis.go b/pkg/storage/cache/redis.go index ae37e6e2..bc777e5c 100644 --- a/pkg/storage/cache/redis.go +++ b/pkg/storage/cache/redis.go @@ -11,9 +11,9 @@ import ( godigest "github.com/opencontainers/go-digest" "github.com/redis/go-redis/v9" - zerr "zotregistry.dev/zot/errors" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage/constants" + zerr "zotregistry.dev/zot/v2/errors" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage/constants" ) type RedisDriver struct { diff --git a/pkg/storage/cache/redis_test.go b/pkg/storage/cache/redis_test.go index 2cfbe38a..71a9c914 100644 --- a/pkg/storage/cache/redis_test.go +++ b/pkg/storage/cache/redis_test.go @@ -12,12 +12,12 @@ import ( "github.com/redis/go-redis/v9" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - "zotregistry.dev/zot/pkg/storage/constants" - test "zotregistry.dev/zot/pkg/test/common" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + "zotregistry.dev/zot/v2/pkg/storage/constants" + test "zotregistry.dev/zot/v2/pkg/test/common" ) var ErrTestError = errors.New("TestError") diff --git a/pkg/storage/cache_benchmark_test.go b/pkg/storage/cache_benchmark_test.go index 7288369a..5d295410 100644 --- a/pkg/storage/cache_benchmark_test.go +++ b/pkg/storage/cache_benchmark_test.go @@ -8,11 +8,11 @@ import ( godigest "github.com/opencontainers/go-digest" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - test "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + test "zotregistry.dev/zot/v2/pkg/test/common" ) const ( diff --git a/pkg/storage/cache_test.go b/pkg/storage/cache_test.go index 79106673..44ec458c 100644 --- a/pkg/storage/cache_test.go +++ b/pkg/storage/cache_test.go @@ -6,10 +6,10 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" + "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" ) func TestCache(t *testing.T) { diff --git a/pkg/storage/common/common.go b/pkg/storage/common/common.go index 18113008..3a6b0a4f 100644 --- a/pkg/storage/common/common.go +++ b/pkg/storage/common/common.go @@ -20,14 +20,14 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/santhosh-tekuri/jsonschema/v5" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) const ( diff --git a/pkg/storage/common/common_test.go b/pkg/storage/common/common_test.go index 2a6c436c..dcaff99c 100644 --- a/pkg/storage/common/common_test.go +++ b/pkg/storage/common/common_test.go @@ -11,16 +11,16 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - common "zotregistry.dev/zot/pkg/storage/common" - "zotregistry.dev/zot/pkg/storage/imagestore" - "zotregistry.dev/zot/pkg/storage/local" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + common "zotregistry.dev/zot/v2/pkg/storage/common" + "zotregistry.dev/zot/v2/pkg/storage/imagestore" + "zotregistry.dev/zot/v2/pkg/storage/local" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrTestError = errors.New("TestError") diff --git a/pkg/storage/common/lint_interface.go b/pkg/storage/common/lint_interface.go index 3d5890e0..5d2efa86 100644 --- a/pkg/storage/common/lint_interface.go +++ b/pkg/storage/common/lint_interface.go @@ -3,7 +3,7 @@ package storage import ( godigest "github.com/opencontainers/go-digest" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) type Lint interface { diff --git a/pkg/storage/gc/gc.go b/pkg/storage/gc/gc.go index 01da30fa..79f15714 100644 --- a/pkg/storage/gc/gc.go +++ b/pkg/storage/gc/gc.go @@ -14,18 +14,18 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - zlog "zotregistry.dev/zot/pkg/log" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/retention" - rTypes "zotregistry.dev/zot/pkg/retention/types" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - common "zotregistry.dev/zot/pkg/storage/common" - "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + zlog "zotregistry.dev/zot/v2/pkg/log" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/retention" + rTypes "zotregistry.dev/zot/v2/pkg/retention/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + common "zotregistry.dev/zot/v2/pkg/storage/common" + "zotregistry.dev/zot/v2/pkg/storage/types" ) const ( diff --git a/pkg/storage/gc/gc_internal_test.go b/pkg/storage/gc/gc_internal_test.go index d92f4947..8d9808ca 100644 --- a/pkg/storage/gc/gc_internal_test.go +++ b/pkg/storage/gc/gc_internal_test.go @@ -14,18 +14,18 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - common "zotregistry.dev/zot/pkg/storage/common" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/local" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + common "zotregistry.dev/zot/v2/pkg/storage/common" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/local" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ( diff --git a/pkg/storage/gc/gc_test.go b/pkg/storage/gc/gc_test.go index aa89e903..592a5fb5 100644 --- a/pkg/storage/gc/gc_test.go +++ b/pkg/storage/gc/gc_test.go @@ -19,22 +19,22 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/meta" - "zotregistry.dev/zot/pkg/meta/boltdb" - "zotregistry.dev/zot/pkg/meta/dynamodb" - mTypes "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/storage" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/gc" - "zotregistry.dev/zot/pkg/storage/local" - "zotregistry.dev/zot/pkg/storage/s3" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - . "zotregistry.dev/zot/pkg/test/image-utils" - tskip "zotregistry.dev/zot/pkg/test/skip" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/meta" + "zotregistry.dev/zot/v2/pkg/meta/boltdb" + "zotregistry.dev/zot/v2/pkg/meta/dynamodb" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/storage" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/gc" + "zotregistry.dev/zot/v2/pkg/storage/local" + "zotregistry.dev/zot/v2/pkg/storage/s3" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) const ( diff --git a/pkg/storage/imagestore/imagestore.go b/pkg/storage/imagestore/imagestore.go index 790e31a3..359e87b5 100644 --- a/pkg/storage/imagestore/imagestore.go +++ b/pkg/storage/imagestore/imagestore.go @@ -19,19 +19,19 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/extensions/monitoring" - syncConstants "zotregistry.dev/zot/pkg/extensions/sync/constants" - zlog "zotregistry.dev/zot/pkg/log" - zreg "zotregistry.dev/zot/pkg/regexp" - "zotregistry.dev/zot/pkg/scheduler" - common "zotregistry.dev/zot/pkg/storage/common" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - "zotregistry.dev/zot/pkg/test/inject" + zerr "zotregistry.dev/zot/v2/errors" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + syncConstants "zotregistry.dev/zot/v2/pkg/extensions/sync/constants" + zlog "zotregistry.dev/zot/v2/pkg/log" + zreg "zotregistry.dev/zot/v2/pkg/regexp" + "zotregistry.dev/zot/v2/pkg/scheduler" + common "zotregistry.dev/zot/v2/pkg/storage/common" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/test/inject" ) const ( diff --git a/pkg/storage/local/driver.go b/pkg/storage/local/driver.go index 107236ee..07adf274 100644 --- a/pkg/storage/local/driver.go +++ b/pkg/storage/local/driver.go @@ -14,9 +14,9 @@ import ( storagedriver "github.com/distribution/distribution/v3/registry/storage/driver" - zerr "zotregistry.dev/zot/errors" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/test/inject" + zerr "zotregistry.dev/zot/v2/errors" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/test/inject" ) type Driver struct { diff --git a/pkg/storage/local/driver_test.go b/pkg/storage/local/driver_test.go index 85d606e5..5b97ec4d 100644 --- a/pkg/storage/local/driver_test.go +++ b/pkg/storage/local/driver_test.go @@ -13,9 +13,9 @@ import ( storagedriver "github.com/distribution/distribution/v3/registry/storage/driver" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/local" + zerr "zotregistry.dev/zot/v2/errors" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/local" ) func TestStorageDriver(t *testing.T) { diff --git a/pkg/storage/local/local.go b/pkg/storage/local/local.go index 2267b7eb..b8a1a911 100644 --- a/pkg/storage/local/local.go +++ b/pkg/storage/local/local.go @@ -1,13 +1,13 @@ package local import ( - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - common "zotregistry.dev/zot/pkg/storage/common" - "zotregistry.dev/zot/pkg/storage/imagestore" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + common "zotregistry.dev/zot/v2/pkg/storage/common" + "zotregistry.dev/zot/v2/pkg/storage/imagestore" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) // NewImageStore returns a new image store backed by a file storage. diff --git a/pkg/storage/local/local_elevated_test.go b/pkg/storage/local/local_elevated_test.go index ca8cd333..27ed05f4 100644 --- a/pkg/storage/local/local_elevated_test.go +++ b/pkg/storage/local/local_elevated_test.go @@ -15,11 +15,11 @@ import ( godigest "github.com/opencontainers/go-digest" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - "zotregistry.dev/zot/pkg/storage/local" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + "zotregistry.dev/zot/v2/pkg/storage/local" ) func TestElevatedPrivilegesInvalidDedupe(t *testing.T) { diff --git a/pkg/storage/local/local_test.go b/pkg/storage/local/local_test.go index 00067558..bd31a426 100644 --- a/pkg/storage/local/local_test.go +++ b/pkg/storage/local/local_test.go @@ -23,21 +23,21 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/gc" - "zotregistry.dev/zot/pkg/storage/local" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - "zotregistry.dev/zot/pkg/test/signature" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/gc" + "zotregistry.dev/zot/v2/pkg/storage/local" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/test/signature" ) const ( diff --git a/pkg/storage/s3/driver.go b/pkg/storage/s3/driver.go index e1a94fdf..87663c65 100644 --- a/pkg/storage/s3/driver.go +++ b/pkg/storage/s3/driver.go @@ -8,7 +8,7 @@ import ( "github.com/distribution/distribution/v3/registry/storage/driver" _ "github.com/distribution/distribution/v3/registry/storage/driver/s3-aws" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" ) type Driver struct { diff --git a/pkg/storage/s3/s3.go b/pkg/storage/s3/s3.go index 20188aec..3d49f0f5 100644 --- a/pkg/storage/s3/s3.go +++ b/pkg/storage/s3/s3.go @@ -6,13 +6,13 @@ import ( // Load s3 driver. _ "github.com/distribution/distribution/v3/registry/storage/driver/s3-aws" - "zotregistry.dev/zot/pkg/compat" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - common "zotregistry.dev/zot/pkg/storage/common" - "zotregistry.dev/zot/pkg/storage/imagestore" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/compat" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + common "zotregistry.dev/zot/v2/pkg/storage/common" + "zotregistry.dev/zot/v2/pkg/storage/imagestore" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) // NewObjectStorage returns a new image store backed by cloud storages. diff --git a/pkg/storage/s3/s3_test.go b/pkg/storage/s3/s3_test.go index 05d927fb..b75b68c0 100644 --- a/pkg/storage/s3/s3_test.go +++ b/pkg/storage/s3/s3_test.go @@ -24,21 +24,21 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/scheduler" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/s3" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/inject" - "zotregistry.dev/zot/pkg/test/mocks" - tskip "zotregistry.dev/zot/pkg/test/skip" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/s3" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/inject" + "zotregistry.dev/zot/v2/pkg/test/mocks" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) //nolint:gochecknoglobals diff --git a/pkg/storage/scrub.go b/pkg/storage/scrub.go index 18892c98..6b0a80de 100644 --- a/pkg/storage/scrub.go +++ b/pkg/storage/scrub.go @@ -14,9 +14,9 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) const ( diff --git a/pkg/storage/scrub_test.go b/pkg/storage/scrub_test.go index 2b5c3019..44364a5b 100644 --- a/pkg/storage/scrub_test.go +++ b/pkg/storage/scrub_test.go @@ -17,19 +17,19 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - common "zotregistry.dev/zot/pkg/storage/common" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/local" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - tskip "zotregistry.dev/zot/pkg/test/skip" + zerr "zotregistry.dev/zot/v2/errors" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + common "zotregistry.dev/zot/v2/pkg/storage/common" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/local" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) const ( diff --git a/pkg/storage/storage.go b/pkg/storage/storage.go index 5a3f109a..de7cf558 100644 --- a/pkg/storage/storage.go +++ b/pkg/storage/storage.go @@ -10,17 +10,17 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - zcommon "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/events" - "zotregistry.dev/zot/pkg/extensions/monitoring" - "zotregistry.dev/zot/pkg/log" - common "zotregistry.dev/zot/pkg/storage/common" - "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/local" - "zotregistry.dev/zot/pkg/storage/s3" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + zcommon "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/events" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + "zotregistry.dev/zot/v2/pkg/log" + common "zotregistry.dev/zot/v2/pkg/storage/common" + "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/local" + "zotregistry.dev/zot/v2/pkg/storage/s3" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) func New(config *config.Config, linter common.Lint, metrics monitoring.MetricServer, diff --git a/pkg/storage/storage_controller.go b/pkg/storage/storage_controller.go index 75f10f91..280fe338 100644 --- a/pkg/storage/storage_controller.go +++ b/pkg/storage/storage_controller.go @@ -3,7 +3,7 @@ package storage import ( "strings" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) const ( diff --git a/pkg/storage/storage_test.go b/pkg/storage/storage_test.go index 3ee7f463..076635de 100644 --- a/pkg/storage/storage_test.go +++ b/pkg/storage/storage_test.go @@ -26,23 +26,23 @@ import ( . "github.com/smartystreets/goconvey/convey" "gopkg.in/resty.v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api/config" - rediscfg "zotregistry.dev/zot/pkg/api/config/redis" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zlog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/cache" - storageCommon "zotregistry.dev/zot/pkg/storage/common" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" - "zotregistry.dev/zot/pkg/storage/gc" - "zotregistry.dev/zot/pkg/storage/imagestore" - "zotregistry.dev/zot/pkg/storage/local" - "zotregistry.dev/zot/pkg/storage/s3" - storageTypes "zotregistry.dev/zot/pkg/storage/types" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - tskip "zotregistry.dev/zot/pkg/test/skip" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api/config" + rediscfg "zotregistry.dev/zot/v2/pkg/api/config/redis" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zlog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/cache" + storageCommon "zotregistry.dev/zot/v2/pkg/storage/common" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/storage/gc" + "zotregistry.dev/zot/v2/pkg/storage/imagestore" + "zotregistry.dev/zot/v2/pkg/storage/local" + "zotregistry.dev/zot/v2/pkg/storage/s3" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) var trueVal bool = true //nolint: gochecknoglobals diff --git a/pkg/storage/types/types.go b/pkg/storage/types/types.go index 828a2080..237d8e40 100644 --- a/pkg/storage/types/types.go +++ b/pkg/storage/types/types.go @@ -9,7 +9,7 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - "zotregistry.dev/zot/pkg/scheduler" + "zotregistry.dev/zot/v2/pkg/scheduler" ) type FilterRepoFunc func(repo string) (bool, error) diff --git a/pkg/test/auth/bearer.go b/pkg/test/auth/bearer.go index 641f435e..2ddc3d1b 100644 --- a/pkg/test/auth/bearer.go +++ b/pkg/test/auth/bearer.go @@ -14,7 +14,7 @@ import ( "github.com/golang-jwt/jwt/v5" "github.com/mitchellh/mapstructure" - "zotregistry.dev/zot/pkg/api" + "zotregistry.dev/zot/v2/pkg/api" ) type ( diff --git a/pkg/test/auth/bearer_test.go b/pkg/test/auth/bearer_test.go index 9fcea60c..95582fc3 100644 --- a/pkg/test/auth/bearer_test.go +++ b/pkg/test/auth/bearer_test.go @@ -5,7 +5,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - auth "zotregistry.dev/zot/pkg/test/auth" + auth "zotregistry.dev/zot/v2/pkg/test/auth" ) func TestBearerServer(t *testing.T) { diff --git a/pkg/test/common/fs_test.go b/pkg/test/common/fs_test.go index 256f96e5..c784bb7b 100644 --- a/pkg/test/common/fs_test.go +++ b/pkg/test/common/fs_test.go @@ -13,7 +13,7 @@ import ( . "github.com/smartystreets/goconvey/convey" "golang.org/x/crypto/bcrypt" - tcommon "zotregistry.dev/zot/pkg/test/common" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" ) var ErrTestError = errors.New("ErrTestError") diff --git a/pkg/test/common/utils_test.go b/pkg/test/common/utils_test.go index c863b07c..28df644f 100644 --- a/pkg/test/common/utils_test.go +++ b/pkg/test/common/utils_test.go @@ -8,9 +8,9 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - tcommon "zotregistry.dev/zot/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" ) func TestWaitTillTrivyDBDownloadStarted(t *testing.T) { diff --git a/pkg/test/image-utils/images.go b/pkg/test/image-utils/images.go index 8e3f57d1..419df31c 100644 --- a/pkg/test/image-utils/images.go +++ b/pkg/test/image-utils/images.go @@ -12,9 +12,9 @@ import ( "github.com/opencontainers/image-spec/specs-go" ispec "github.com/opencontainers/image-spec/specs-go/v1" - "zotregistry.dev/zot/pkg/common" - mTypes "zotregistry.dev/zot/pkg/meta/types" - storageConstants "zotregistry.dev/zot/pkg/storage/constants" + "zotregistry.dev/zot/v2/pkg/common" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + storageConstants "zotregistry.dev/zot/v2/pkg/storage/constants" ) const ( diff --git a/pkg/test/image-utils/images_test.go b/pkg/test/image-utils/images_test.go index 2b93baf0..74df4eec 100644 --- a/pkg/test/image-utils/images_test.go +++ b/pkg/test/image-utils/images_test.go @@ -9,8 +9,8 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/common" - . "zotregistry.dev/zot/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" ) func TestImageBuilder(t *testing.T) { diff --git a/pkg/test/image-utils/multiarch.go b/pkg/test/image-utils/multiarch.go index b32cd7ad..378992fd 100644 --- a/pkg/test/image-utils/multiarch.go +++ b/pkg/test/image-utils/multiarch.go @@ -8,7 +8,7 @@ import ( "github.com/opencontainers/image-spec/specs-go" ispec "github.com/opencontainers/image-spec/specs-go/v1" - mTypes "zotregistry.dev/zot/pkg/meta/types" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) type MultiarchImage struct { diff --git a/pkg/test/image-utils/upload.go b/pkg/test/image-utils/upload.go index f35dc18d..43bd520c 100644 --- a/pkg/test/image-utils/upload.go +++ b/pkg/test/image-utils/upload.go @@ -11,8 +11,8 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" "gopkg.in/resty.v1" - tcommon "zotregistry.dev/zot/pkg/test/common" - "zotregistry.dev/zot/pkg/test/inject" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" + "zotregistry.dev/zot/v2/pkg/test/inject" ) var ( diff --git a/pkg/test/image-utils/upload_test.go b/pkg/test/image-utils/upload_test.go index e7ae8eee..94f737f1 100644 --- a/pkg/test/image-utils/upload_test.go +++ b/pkg/test/image-utils/upload_test.go @@ -11,11 +11,11 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - tcommon "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/inject" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/inject" ) func TestUploadImage(t *testing.T) { diff --git a/pkg/test/image-utils/utils.go b/pkg/test/image-utils/utils.go index aa39e5a4..a5348b72 100644 --- a/pkg/test/image-utils/utils.go +++ b/pkg/test/image-utils/utils.go @@ -13,7 +13,7 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - tcommon "zotregistry.dev/zot/pkg/test/common" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" ) var vulnerableLayer []byte //nolint: gochecknoglobals diff --git a/pkg/test/image-utils/write.go b/pkg/test/image-utils/write.go index 3a7b5678..827aaa8a 100644 --- a/pkg/test/image-utils/write.go +++ b/pkg/test/image-utils/write.go @@ -6,7 +6,7 @@ import ( godigest "github.com/opencontainers/go-digest" - stypes "zotregistry.dev/zot/pkg/storage/types" + stypes "zotregistry.dev/zot/v2/pkg/storage/types" ) func WriteImageToFileSystem(image Image, repoName, ref string, storeController stypes.StoreController) error { diff --git a/pkg/test/image-utils/write_test.go b/pkg/test/image-utils/write_test.go index f8df7813..4c048c56 100644 --- a/pkg/test/image-utils/write_test.go +++ b/pkg/test/image-utils/write_test.go @@ -8,9 +8,9 @@ import ( godigest "github.com/opencontainers/go-digest" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/storage" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/storage" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) var ErrTestError = errors.New("ErrTestError") diff --git a/pkg/test/inject/dev.go b/pkg/test/inject/dev.go index 6d21d300..f47880a7 100644 --- a/pkg/test/inject/dev.go +++ b/pkg/test/inject/dev.go @@ -9,8 +9,8 @@ import ( "net/http" "sync" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/log" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/log" ) func Ok(ok bool) bool { diff --git a/pkg/test/inject/inject_test.go b/pkg/test/inject/inject_test.go index dda24b5e..68f1d416 100644 --- a/pkg/test/inject/inject_test.go +++ b/pkg/test/inject/inject_test.go @@ -11,7 +11,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/test/inject" + "zotregistry.dev/zot/v2/pkg/test/inject" ) var ( diff --git a/pkg/test/mocks/cve_mock.go b/pkg/test/mocks/cve_mock.go index 478ea14b..dbd977af 100644 --- a/pkg/test/mocks/cve_mock.go +++ b/pkg/test/mocks/cve_mock.go @@ -3,8 +3,8 @@ package mocks import ( "context" - "zotregistry.dev/zot/pkg/common" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/common" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" ) type CveInfoMock struct { diff --git a/pkg/test/mocks/image_store_mock.go b/pkg/test/mocks/image_store_mock.go index 53ca277d..c5150deb 100644 --- a/pkg/test/mocks/image_store_mock.go +++ b/pkg/test/mocks/image_store_mock.go @@ -8,8 +8,8 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - "zotregistry.dev/zot/pkg/scheduler" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/scheduler" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) type MockedImageStore struct { diff --git a/pkg/test/mocks/lint_mock.go b/pkg/test/mocks/lint_mock.go index 47ac43a5..5788eb82 100644 --- a/pkg/test/mocks/lint_mock.go +++ b/pkg/test/mocks/lint_mock.go @@ -3,7 +3,7 @@ package mocks import ( godigest "github.com/opencontainers/go-digest" - storageTypes "zotregistry.dev/zot/pkg/storage/types" + storageTypes "zotregistry.dev/zot/v2/pkg/storage/types" ) type MockedLint struct { diff --git a/pkg/test/mocks/oci_mock.go b/pkg/test/mocks/oci_mock.go index b50b2214..4050d127 100644 --- a/pkg/test/mocks/oci_mock.go +++ b/pkg/test/mocks/oci_mock.go @@ -4,8 +4,8 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - "zotregistry.dev/zot/pkg/common" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/common" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" ) type OciLayoutUtilsMock struct { diff --git a/pkg/test/mocks/repo_db_mock.go b/pkg/test/mocks/repo_db_mock.go index 86a1e242..317778b7 100644 --- a/pkg/test/mocks/repo_db_mock.go +++ b/pkg/test/mocks/repo_db_mock.go @@ -6,7 +6,7 @@ import ( godigest "github.com/opencontainers/go-digest" - mTypes "zotregistry.dev/zot/pkg/meta/types" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" ) type MetaDBMock struct { diff --git a/pkg/test/oci-utils/oci_layout.go b/pkg/test/oci-utils/oci_layout.go index 43bead73..f2f2b922 100644 --- a/pkg/test/oci-utils/oci_layout.go +++ b/pkg/test/oci-utils/oci_layout.go @@ -16,12 +16,12 @@ import ( godigest "github.com/opencontainers/go-digest" ispec "github.com/opencontainers/image-spec/specs-go/v1" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/common" - "zotregistry.dev/zot/pkg/extensions/search/convert" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - stypes "zotregistry.dev/zot/pkg/storage/types" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/common" + "zotregistry.dev/zot/v2/pkg/extensions/search/convert" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + stypes "zotregistry.dev/zot/v2/pkg/storage/types" ) type OciUtils interface { //nolint: interfacebloat diff --git a/pkg/test/oci-utils/oci_layout_test.go b/pkg/test/oci-utils/oci_layout_test.go index 0f50f7f1..3fe7317f 100644 --- a/pkg/test/oci-utils/oci_layout_test.go +++ b/pkg/test/oci-utils/oci_layout_test.go @@ -16,20 +16,20 @@ import ( ispec "github.com/opencontainers/image-spec/specs-go/v1" . "github.com/smartystreets/goconvey/convey" - zerr "zotregistry.dev/zot/errors" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - extconf "zotregistry.dev/zot/pkg/extensions/config" - "zotregistry.dev/zot/pkg/extensions/monitoring" - cvemodel "zotregistry.dev/zot/pkg/extensions/search/cve/model" - "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - tcommon "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" - "zotregistry.dev/zot/pkg/test/signature" + zerr "zotregistry.dev/zot/v2/errors" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + extconf "zotregistry.dev/zot/v2/pkg/extensions/config" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + cvemodel "zotregistry.dev/zot/v2/pkg/extensions/search/cve/model" + "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" ) var ErrTestError = errors.New("testError") diff --git a/pkg/test/oci-utils/repo.go b/pkg/test/oci-utils/repo.go index 362104b6..327b5d4d 100644 --- a/pkg/test/oci-utils/repo.go +++ b/pkg/test/oci-utils/repo.go @@ -4,10 +4,10 @@ import ( "context" "fmt" - zerr "zotregistry.dev/zot/errors" - mTypes "zotregistry.dev/zot/pkg/meta/types" - reqCtx "zotregistry.dev/zot/pkg/requestcontext" - imageUtil "zotregistry.dev/zot/pkg/test/image-utils" + zerr "zotregistry.dev/zot/v2/errors" + mTypes "zotregistry.dev/zot/v2/pkg/meta/types" + reqCtx "zotregistry.dev/zot/v2/pkg/requestcontext" + imageUtil "zotregistry.dev/zot/v2/pkg/test/image-utils" ) type RepoImage struct { diff --git a/pkg/test/oci-utils/repo_test.go b/pkg/test/oci-utils/repo_test.go index 69aadda0..2ae55838 100644 --- a/pkg/test/oci-utils/repo_test.go +++ b/pkg/test/oci-utils/repo_test.go @@ -7,10 +7,10 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/meta/types" - "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/mocks" - ociutils "zotregistry.dev/zot/pkg/test/oci-utils" + "zotregistry.dev/zot/v2/pkg/meta/types" + "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/mocks" + ociutils "zotregistry.dev/zot/v2/pkg/test/oci-utils" ) var ErrTestFail = errors.New("fail") diff --git a/pkg/test/oci-utils/store.go b/pkg/test/oci-utils/store.go index 6f6c01bd..27f47656 100644 --- a/pkg/test/oci-utils/store.go +++ b/pkg/test/oci-utils/store.go @@ -3,12 +3,12 @@ package ociutils import ( godigest "github.com/opencontainers/go-digest" - "zotregistry.dev/zot/pkg/extensions/monitoring" - zLog "zotregistry.dev/zot/pkg/log" - "zotregistry.dev/zot/pkg/storage" - "zotregistry.dev/zot/pkg/storage/local" - stypes "zotregistry.dev/zot/pkg/storage/types" - "zotregistry.dev/zot/pkg/test/mocks" + "zotregistry.dev/zot/v2/pkg/extensions/monitoring" + zLog "zotregistry.dev/zot/v2/pkg/log" + "zotregistry.dev/zot/v2/pkg/storage" + "zotregistry.dev/zot/v2/pkg/storage/local" + stypes "zotregistry.dev/zot/v2/pkg/storage/types" + "zotregistry.dev/zot/v2/pkg/test/mocks" ) func GetDefaultImageStore(rootDir string, log zLog.Logger) stypes.ImageStore { diff --git a/pkg/test/signature/notation.go b/pkg/test/signature/notation.go index b96e7b2f..eacce5dc 100644 --- a/pkg/test/signature/notation.go +++ b/pkg/test/signature/notation.go @@ -31,7 +31,7 @@ import ( "oras.land/oras-go/v2/registry/remote" "oras.land/oras-go/v2/registry/remote/auth" - tcommon "zotregistry.dev/zot/pkg/test/common" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" ) var ( diff --git a/pkg/test/signature/notation_test.go b/pkg/test/signature/notation_test.go index f8e29e36..e2012f1a 100644 --- a/pkg/test/signature/notation_test.go +++ b/pkg/test/signature/notation_test.go @@ -13,11 +13,11 @@ import ( notconfig "github.com/notaryproject/notation-go/config" . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/pkg/api" - "zotregistry.dev/zot/pkg/api/config" - tcommon "zotregistry.dev/zot/pkg/test/common" - . "zotregistry.dev/zot/pkg/test/image-utils" - "zotregistry.dev/zot/pkg/test/signature" + "zotregistry.dev/zot/v2/pkg/api" + "zotregistry.dev/zot/v2/pkg/api/config" + tcommon "zotregistry.dev/zot/v2/pkg/test/common" + . "zotregistry.dev/zot/v2/pkg/test/image-utils" + "zotregistry.dev/zot/v2/pkg/test/signature" ) func TestLoadNotationSigningkeys(t *testing.T) { diff --git a/pkg/test/skip/skip_test.go b/pkg/test/skip/skip_test.go index ba24c2fc..f2d2ce49 100644 --- a/pkg/test/skip/skip_test.go +++ b/pkg/test/skip/skip_test.go @@ -6,7 +6,7 @@ import ( "github.com/stretchr/testify/require" - tskip "zotregistry.dev/zot/pkg/test/skip" + tskip "zotregistry.dev/zot/v2/pkg/test/skip" ) // for code coverage. diff --git a/swagger/docs_test.go b/swagger/docs_test.go index 56a70668..1e109673 100644 --- a/swagger/docs_test.go +++ b/swagger/docs_test.go @@ -5,7 +5,7 @@ import ( . "github.com/smartystreets/goconvey/convey" - "zotregistry.dev/zot/swagger" + "zotregistry.dev/zot/v2/swagger" ) func TestDocs(t *testing.T) {