diff --git a/.github/common-actions/e2e-test-cli/action.yaml b/.github/common-actions/e2e-test-cli/action.yaml index 2c851f7..c137a09 100644 --- a/.github/common-actions/e2e-test-cli/action.yaml +++ b/.github/common-actions/e2e-test-cli/action.yaml @@ -26,18 +26,20 @@ runs: working-directory: /tmp/operator-builder-test run: | if [[ "${{ inputs.test-deploy }}" == "true" ]]; then - COMMAND=`find ${PWD}/bin ! -name kustomize ! -name controller-gen ! -name operator-builder -type f` - MANIFEST=`find ${PWD}/config/samples -name "*.yaml" | head -1` - echo "::set-output name=command::${COMMAND}" - echo "::set-output name=manifest::${MANIFEST}" + COMMAND=`find ${PWD}/bin ! -name kustomize ! -name controller-gen ! -name operator-builder ! -name kube-apiserver ! -name etcd ! -name kubectl ! -name setup-envtest -type f` + echo $COMMAND + MANIFEST=`find ${PWD}/config/samples ! -name kustomization.yaml -name "*.yaml" | head -1` + echo $MANIFEST + echo "CLI_COMMAND=$COMMAND" >> "$GITHUB_OUTPUT" + echo "CLI_MANIFEST=$MANIFEST" >> "$GITHUB_OUTPUT" fi - name: Generate and Apply Child Resources shell: bash run: | if [[ "${{ inputs.test-deploy }}" == "true" ]]; then - ${{ steps.get-cli-inputs.outputs.command }} generate \ - -w ${{ steps.get-cli-inputs.outputs.manifest }} \ + ${{ steps.get-cli-inputs.outputs.CLI_COMMAND }} generate \ + -w ${{ steps.get-cli-inputs.outputs.CLI_MANIFEST }} \ | kubectl apply -f - fi @@ -45,8 +47,8 @@ runs: shell: bash run: | if [[ "${{ inputs.test-deploy }}" == "true" ]]; then - ${{ steps.get-cli-inputs.outputs.command }} generate \ - -w ${{ steps.get-cli-inputs.outputs.manifest }} \ + ${{ steps.get-cli-inputs.outputs.CLI_COMMAND }} generate \ + -w ${{ steps.get-cli-inputs.outputs.CLI_MANIFEST }} \ | kubectl delete -f - fi @@ -56,7 +58,7 @@ runs: run: | if [[ "${{ inputs.test-deploy }}" == "true" ]]; then make install - ${{ steps.get-cli-inputs.outputs.command }} init | kubectl apply -f - + ${{ steps.get-cli-inputs.outputs.CLI_COMMAND }} init | kubectl apply -f - fi - name: Uninstall Parent Custom Resources diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index da42e80..7c6d4cb 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Check Latest Commit Message run: make test-commit @@ -27,7 +27,7 @@ jobs: if: github.event_name == 'pull_request' steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Get PR Commits id: get-pr-commits @@ -52,7 +52,7 @@ jobs: if: github.event_name == 'pull_request' steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Check Pull Request Title uses: deepakputhraya/action-pr-title@master @@ -80,7 +80,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Check License Lines uses: kt3k/license_checker@v1.0.6 @@ -91,7 +91,7 @@ jobs: steps: - uses: actions/setup-go@v3 with: - go-version: 1.18 + go-version: "1.19" - name: Checkout Code uses: actions/checkout@v3 @@ -99,5 +99,5 @@ jobs: - name: Lint uses: golangci/golangci-lint-action@v3 with: - version: v1.46.2 + version: v1.52.2 args: --timeout 3m diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 5aedaac..9ba8189 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -10,14 +10,14 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: fetch-depth: 0 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.18 + go-version: "1.19" # NOTE: removing support for snapcraft as their CLI has become increasingly unstable and errors have become # common place. See https://github.com/snapcore/action-publish/issues/28 for an example of some of the issues diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index d819443..c249e6b 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -15,16 +15,16 @@ jobs: fail-fast: false matrix: include: - - go-version: 1.18 - - go-version: 1.19 + - go-version: "1.19" + - go-version: "1.20" steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: fetch-depth: 0 - name: Setup Go - uses: actions/setup-go@v2 + uses: actions/setup-go@v3 with: go-version: ${{ matrix.go-version }} @@ -42,16 +42,16 @@ jobs: fail-fast: false matrix: include: - - go-version: 1.18 - - go-version: 1.19 + - go-version: "1.19" + - go-version: "1.20" steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: fetch-depth: 0 - name: Setup Go - uses: actions/setup-go@v2 + uses: actions/setup-go@v3 with: go-version: ${{ matrix.go-version }} @@ -59,7 +59,7 @@ jobs: run: make build - name: Store Artifact - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: operator-builder path: bin/operator-builder @@ -78,36 +78,36 @@ jobs: - name: Standalone Operator (Current Go Version) artifact: standalone-codebase test-workload-path: test/cases/standalone - go-version: 1.19 + go-version: "1.20" - name: Standalone Edge Cases Operator (Current Go Version - 1) artifact: standalone-edge-codebase test-workload-path: test/cases/edge-standalone - go-version: 1.18 + go-version: "1.19" - name: Workload Collection Operator (Current Go Version) artifact: collection-codebase test-workload-path: test/cases/collection - go-version: 1.19 + go-version: "1.20" - name: Workload Collection Edge Cases Operator (Current Go Version - 1) artifact: collection-edge-codebase test-workload-path: test/cases/edge-collection - go-version: 1.18 + go-version: "1.19" env: TEST_WORKLOAD_PATH: "${{ matrix.test-workload-path }}" TEST_PATH: "/tmp/operator-builder-func-test" steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: fetch-depth: 0 - name: Download operator-builder Binary - uses: actions/download-artifact@v2 + uses: actions/download-artifact@v3 with: name: operator-builder path: bin - name: Setup Go - uses: actions/setup-go@v2 + uses: actions/setup-go@v3 with: go-version: ${{ matrix.go-version }} @@ -122,7 +122,7 @@ jobs: - name: Store ${{ matrix.name }} Codebase if: github.event_name == 'pull_request' - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: ${{ matrix.artifact }} path: ${{ env.TEST_PATH }} @@ -145,22 +145,22 @@ jobs: artifact: standalone-codebase test-build: "true" test-deploy: "true" - go-version: 1.19 + go-version: "1.20" - name: Standalone Edge Cases Operator (Current Go Version - 1) artifact: standalone-edge-codebase test-build: "false" test-deploy: "false" - go-version: 1.18 + go-version: "1.19" - name: Workload Collection Operator (Current Go Version) artifact: collection-codebase test-build: "true" test-deploy: "false" - go-version: 1.19 + go-version: "1.20" - name: Workload Collection Edge Cases Operator (Current Go Version - 1) artifact: collection-edge-codebase test-build: "true" test-deploy: "false" - go-version: 1.18 + go-version: "1.19" services: registry: image: registry:2 @@ -171,17 +171,17 @@ jobs: working-directory: /tmp/operator-builder-test steps: - name: Checkout Code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: fetch-depth: 0 - name: Setup Go - uses: actions/setup-go@v2 + uses: actions/setup-go@v3 with: go-version: ${{ matrix.go-version }} - name: Download ${{ matrix.name }} Codebase - uses: actions/download-artifact@v2 + uses: actions/download-artifact@v3 with: name: ${{ matrix.artifact }} path: /tmp/operator-builder-test diff --git a/.golangci.yml b/.golangci.yml index 95cf200..93fbfde 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -72,7 +72,6 @@ linters: - asciicheck - bodyclose #- cyclop - - deadcode - depguard - dogsled - dupl @@ -85,7 +84,8 @@ linters: - forbidigo - forcetypeassert - funlen - - gci + # disable due to false positives + #- gci - gochecknoglobals - gochecknoinits - gocognit @@ -99,7 +99,6 @@ linters: #- gofmt - goheader - goimports - - golint - gomnd - gomoddirectives - gomodguard @@ -107,10 +106,8 @@ linters: - gosec - gosimple - govet - - ifshort - importas - ineffassign - - interfacer - lll - makezero - misspell @@ -126,7 +123,6 @@ linters: - rowserrcheck - sqlclosecheck - staticcheck - - structcheck - stylecheck - testpackage - thelper @@ -135,7 +131,6 @@ linters: - unconvert - unparam - unused - - varcheck - wastedassign - whitespace - wrapcheck @@ -152,7 +147,9 @@ issues: - path: internal/commands/*\.go linters: - gochecknoglobals - + - path: internal/plugins/workload/v1/scaffolds/templates/readme.go + linters: + - gomnd # https://github.com/go-critic/go-critic/issues/926 - linters: - gocritic diff --git a/.licenserc.json b/.licenserc.json index 359c1df..f090ee6 100644 --- a/.licenserc.json +++ b/.licenserc.json @@ -1,5 +1,5 @@ { "**/*.go": [ - "// Copyright 2022 Nukleros" + "// Copyright 2023 Nukleros" ] } \ No newline at end of file diff --git a/Makefile b/Makefile index 17e7f46..f5023e1 100644 --- a/Makefile +++ b/Makefile @@ -8,11 +8,13 @@ INIT_OPTS=init \ --workload-config .workloadConfig/workload.yaml \ --repo github.com/acme/acme-cnp-mgr \ --skip-go-version-check \ - --controller-image controller:latest + --controller-image controller:latest \ + --enable-olm=true CREATE_OPTS=create api \ --workload-config .workloadConfig/workload.yaml \ --controller \ - --resource + --resource \ + --enable-olm=true define create_path if [ ! -d $(1)/.workloadConfig ]; then\ @@ -34,7 +36,7 @@ install: build # # traditional testing # -GOLANGCI_LINT_VERSION ?= v1.46.2 +GOLANGCI_LINT_VERSION ?= v1.52.2 install-linter: go install github.com/golangci/golangci-lint/cmd/golangci-lint@$(GOLANGCI_LINT_VERSION) diff --git a/cmd/operator-builder/main.go b/cmd/operator-builder/main.go index 7b2cf10..e101f32 100644 --- a/cmd/operator-builder/main.go +++ b/cmd/operator-builder/main.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/go.mod b/go.mod index 54bf107..8c067e7 100644 --- a/go.mod +++ b/go.mod @@ -4,82 +4,55 @@ go 1.18 require ( github.com/go-playground/validator v9.31.0+incompatible - github.com/sirupsen/logrus v1.8.1 - github.com/spf13/afero v1.6.0 - github.com/spf13/cobra v1.4.0 + github.com/sirupsen/logrus v1.9.0 + github.com/spf13/afero v1.9.3 + github.com/spf13/cobra v1.6.1 github.com/spf13/pflag v1.0.5 - github.com/stretchr/testify v1.7.0 + github.com/stretchr/testify v1.8.1 github.com/vmware-tanzu-labs/object-code-generator-for-k8s v0.5.0 - gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b + gopkg.in/yaml.v3 v3.0.1 k8s.io/apimachinery v0.24.2 k8s.io/client-go v0.24.2 - sigs.k8s.io/kubebuilder/v3 v3.7.0 + sigs.k8s.io/kubebuilder/v3 v3.9.1 ) require ( github.com/Masterminds/goutils v1.1.1 // indirect github.com/Masterminds/semver/v3 v3.1.1 // indirect github.com/Masterminds/sprig/v3 v3.2.2 // indirect - github.com/PuerkitoBio/purell v1.1.1 // indirect - github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 // indirect - github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a // indirect - github.com/cloudflare/cfssl v1.5.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/go-errors/errors v1.0.1 // indirect - github.com/go-logr/logr v1.2.0 // indirect - github.com/go-openapi/jsonpointer v0.19.5 // indirect - github.com/go-openapi/jsonreference v0.19.5 // indirect - github.com/go-openapi/swag v0.19.14 // indirect + github.com/go-logr/logr v1.2.3 // indirect github.com/go-playground/locales v0.14.0 // indirect github.com/go-playground/universal-translator v0.18.0 // indirect - github.com/gobuffalo/flect v0.2.5 // indirect + github.com/gobuffalo/flect v1.0.0 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/protobuf v1.5.2 // indirect - github.com/google/certificate-transparency-go v1.0.21 // indirect github.com/google/gofuzz v1.1.0 // indirect github.com/google/uuid v1.1.2 // indirect github.com/huandu/xstrings v1.3.1 // indirect github.com/imdario/mergo v0.3.12 // indirect - github.com/inconshreveable/mousetrap v1.0.0 // indirect - github.com/jmoiron/sqlx v1.2.0 // indirect - github.com/josharian/intern v1.0.0 // indirect + github.com/inconshreveable/mousetrap v1.0.1 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/leodido/go-urn v1.2.1 // indirect - github.com/mailru/easyjson v0.7.6 // indirect github.com/mitchellh/copystructure v1.0.0 // indirect - github.com/mitchellh/mapstructure v1.4.1 // indirect github.com/mitchellh/reflectwalk v1.0.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect - github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect - github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/shopspring/decimal v1.2.0 // indirect github.com/spf13/cast v1.3.1 // indirect - github.com/weppos/publicsuffix-go v0.13.0 // indirect - github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca // indirect - github.com/zmap/zcrypto v0.0.0-20200911161511-43ff0ea04f21 // indirect - github.com/zmap/zlint/v2 v2.2.1 // indirect golang.org/x/crypto v0.0.0-20220214200702-86341886e292 // indirect - golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3 // indirect - golang.org/x/net v0.0.0-20220225172249-27dd8689420f // indirect - golang.org/x/sys v0.0.0-20220319134239-a9b59b0215f8 // indirect - golang.org/x/text v0.3.7 // indirect - golang.org/x/tools v0.1.10 // indirect - golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect - google.golang.org/protobuf v1.27.1 // indirect + golang.org/x/mod v0.7.0 // indirect + golang.org/x/net v0.5.0 // indirect + golang.org/x/sys v0.4.0 // indirect + golang.org/x/text v0.6.0 // indirect + golang.org/x/tools v0.5.0 // indirect gopkg.in/go-playground/assert.v1 v1.2.1 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect k8s.io/api v0.24.2 // indirect - k8s.io/apiextensions-apiserver v0.24.2 // indirect k8s.io/klog/v2 v2.60.1 // indirect - k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42 // indirect k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9 // indirect - sigs.k8s.io/controller-runtime v0.12.2 // indirect - sigs.k8s.io/controller-tools v0.9.2 // indirect sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2 // indirect - sigs.k8s.io/kustomize/kyaml v0.13.6 // indirect sigs.k8s.io/structured-merge-diff/v4 v4.2.1 // indirect sigs.k8s.io/yaml v1.3.0 // indirect ) diff --git a/go.sum b/go.sum index 21a96c6..fc54c6c 100644 --- a/go.sum +++ b/go.sum @@ -1,9 +1,9 @@ -bitbucket.org/liamstask/goose v0.0.0-20150115234039-8488cc47d90c/go.mod h1:hSVuE3qU7grINVSwrmzHfpg9k87ALBk+XaualNyUzI4= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= +cloud.google.com/go v0.44.3/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To= @@ -16,6 +16,7 @@ cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOY cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY= cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI= cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk= +cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY= cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= @@ -37,8 +38,8 @@ cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0Zeo cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= +cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA= github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M= @@ -48,8 +49,6 @@ github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZ github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/GeertJohan/go.incremental v1.0.0/go.mod h1:6fAjUhbVuX1KcMD3c8TEgVUqmo4seqhv0i0kdATSkM0= -github.com/GeertJohan/go.rice v1.0.0/go.mod h1:eH6gbSOAUv07dQuZVnBmoDP8mgsM1rtixis4Tib9if0= github.com/Masterminds/goutils v1.1.1 h1:5nUrii3FMTL5diU80unEVvNevw1nH4+ZV4DSLVJLSYI= github.com/Masterminds/goutils v1.1.1/go.mod h1:8cTjp+g8YejhMuvIA5y2vz3BpJxksy863GQaJW2MFNU= github.com/Masterminds/semver/v3 v3.1.1 h1:hLg3sBzpNErnxhQtUy/mmLR2I9foDujNK030IGemrRc= @@ -57,77 +56,43 @@ github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0 github.com/Masterminds/sprig/v3 v3.2.2 h1:17jRggJu518dr3QaafizSXOjKYp94wKfABxUmyxvxX8= github.com/Masterminds/sprig/v3 v3.2.2/go.mod h1:UoaO7Yp8KlPnJIYWTFkMaqPUYKTfGFPhxNuwnnxkKlk= github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ= -github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= -github.com/PuerkitoBio/purell v1.1.1 h1:WEQqlqaGbrPkxLJWfBwQmfEAE1Z7ONdDLqrN38tNFfI= github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= -github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 h1:d+Bc7a5rLufV/sSk/8dngufqelfh6jnri85riMAaF/M= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= -github.com/akavel/rsrc v0.8.0/go.mod h1:uLoCtb9J+EyAqh+26kdrTgmzRBFPGOolLWKpdxkKq+c= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= -github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= -github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= -github.com/antlr/antlr4/runtime/Go/antlr v0.0.0-20210826220005-b48c857c3a0e/go.mod h1:F7bn7fEU90QkQ3tnmaTx3LTKLEDqnwWODIYppRQ5hnY= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= -github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a h1:idn718Q4B6AGu/h5Sxe66HYVdqdGu2l9Iebqhi/AEoA= github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= -github.com/benbjohnson/clock v1.0.3/go.mod h1:bGMdMPoPVvcYyt1gHDf4J2KE153Yf9BuiUKYMaxlTDM= -github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= -github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84= -github.com/bketelsen/crypt v0.0.4/go.mod h1:aI6NrJ0pMGgvZKL1iVgXLnfIFJtfV+bKCoqOes/6LfM= -github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/certifi/gocertifi v0.0.0-20180118203423-deb3ae2ef261/go.mod h1:GJKEexRPVJrBSOjoqN5VNOIKJ5Q3RViH6eu3puDRwx4= -github.com/certifi/gocertifi v0.0.0-20191021191039-0944d244cd40/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= -github.com/certifi/gocertifi v0.0.0-20200922220541-2c3bb06c6054/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= -github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cloudflare/backoff v0.0.0-20161212185259-647f3cdfc87a/go.mod h1:rzgs2ZOiguV6/NpiDgADjRLPNyZlApIWxKpkT+X8SdY= -github.com/cloudflare/cfssl v1.5.0 h1:vFJDAvQgFSRbCn9zg8KpSrrEZrBAQ4KO5oNK7SXEyb0= -github.com/cloudflare/cfssl v1.5.0/go.mod h1:sPPkBS5L8l8sRc/IOO1jG51Xb34u+TYhL6P//JdODMQ= -github.com/cloudflare/go-metrics v0.0.0-20151117154305-6a9aea36fb41/go.mod h1:eaZPlJWD+G9wseg1BuRXlHnjntPMrywMsyxf+LTOdP4= -github.com/cloudflare/redoctober v0.0.0-20171127175943-746a508df14c/go.mod h1:6Se34jNoqrd8bTxrmJB2Bg2aoZ2CdSXonils9NsiNgo= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= -github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cockroachdb/datadriven v0.0.0-20200714090401-bf6692d28da5/go.mod h1:h6jFvWxBdQXxjopDMZyH2UVceIRfR84bdzbkoKrsWNo= -github.com/cockroachdb/errors v1.2.4/go.mod h1:rQD95gz6FARkaKkQXUksEje/d9a6wBJoCr5oaCLELYA= -github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= -github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= -github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/daaku/go.zipexe v1.0.0/go.mod h1:z8IiR6TsVLEYKwXAoE/I+8ys/sDkgTzSL0CLnGVd57E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= -github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/elazarl/goproxy v0.0.0-20180725130230-947c36da3153/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc= github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= @@ -136,45 +101,31 @@ github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.m github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/fsnotify/fsnotify v1.5.1 h1:mZcQUHVQUQWoPXXtuf9yuEXKudkV2sx1E06UadKWpgI= github.com/getkin/kin-openapi v0.76.0/go.mod h1:660oXbgy5JFMKreazJaQTw7o+X00qeSyhcnluiMv+Xg= -github.com/getsentry/raven-go v0.0.0-20180121060056-563b81fc02b7/go.mod h1:KungGk8q33+aIAZUIVWZDr2OfAEBsO49PX4NzFV5kcQ= -github.com/getsentry/raven-go v0.2.0/go.mod h1:KungGk8q33+aIAZUIVWZDr2OfAEBsO49PX4NzFV5kcQ= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/go-errors/errors v1.0.1 h1:LUHzmkK3GUKUrL/1gfBUxAHzcev3apQlezX/+O7ma6w= -github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= -github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas= github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= -github.com/go-logr/logr v1.2.0 h1:QK40JKJyMdUDz+h+xvCsru/bJhvG0UxvePV0ufL/AcE= github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/zapr v1.2.0/go.mod h1:Qa4Bsj2Vb+FAVeAKsLD8RLQ+YRJB8YDmOAKxaBQf7Ro= +github.com/go-logr/logr v1.2.3 h1:2DntVwHkVopvECVRSlL5PSo9eG+cAkDCuckLubN+rq0= +github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/jsonpointer v0.19.5 h1:gZr+CIYByUqjcgeLXnQu2gHYQC9o73G2XUeOFYEICuY= github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8= -github.com/go-openapi/jsonreference v0.19.5 h1:1WJP/wi4OjB4iV8KVbH73rQaoialJrqv8gitZLxGLtM= github.com/go-openapi/jsonreference v0.19.5/go.mod h1:RdybgQwPxbL4UEjuAruzK1x3nE69AqPYEJeo/TWfEeg= github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= -github.com/go-openapi/swag v0.19.14 h1:gm3vOOXfiuw5i9p5N9xJvfjvuofpyvLA9Wr6QfK5Fng= github.com/go-openapi/swag v0.19.14/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= github.com/go-playground/locales v0.14.0 h1:u50s323jtVGugKlcYeyzC0etD1HifMjqmJqb8WugfUU= github.com/go-playground/locales v0.14.0/go.mod h1:sawfccIbzZTqEDETgFXqTho0QybSa7l++s0DH+LDiLs= @@ -182,18 +133,14 @@ github.com/go-playground/universal-translator v0.18.0 h1:82dyy6p4OuJq4/CByFNOn/j github.com/go-playground/universal-translator v0.18.0/go.mod h1:UvRDBj+xPUEGrFYl+lu/H90nyDXpg0fqeB/AQUGNTVA= github.com/go-playground/validator v9.31.0+incompatible h1:UA72EPEogEnq76ehGdEDp4Mit+3FDh548oRqwVgNsHA= github.com/go-playground/validator v9.31.0+incompatible/go.mod h1:yrEkQXlcI+PugkyDjY2bRrL/UBU4f3rvrgkN3V8JEig= -github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= -github.com/gobuffalo/flect v0.2.5 h1:H6vvsv2an0lalEaCDRThvtBfmg44W/QHXBCYUXf/6S4= -github.com/gobuffalo/flect v0.2.5/go.mod h1:1ZyCLIbg0YD7sDkzvFdPoOydPtD8y9JQnrOROolUcM8= -github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= +github.com/gobuffalo/flect v1.0.0 h1:eBFmskjXZgAOagiTXJH25Nt5sdFwNRcb8DKZsIsAUQI= +github.com/gobuffalo/flect v1.0.0/go.mod h1:l9V6xSb4BlXwsxEMj3FVEub2nkdQjWhPvD8XTTlHPQc= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= -github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -223,16 +170,10 @@ github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= -github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA= -github.com/google/cel-go v0.10.1/go.mod h1:U7ayypeSkw23szu4GaQTPJGx66c20mx8JklMSxrmI1w= -github.com/google/cel-spec v0.6.0/go.mod h1:Nwjgxy5CbjlPrtCWjeDjUyKMl8w41YBYGjsyDdqk0xA= -github.com/google/certificate-transparency-go v1.0.21 h1:Yf1aXowfZ2nuboBsg7iYGLmwsOARdV86pfH3g95wXmE= -github.com/google/certificate-transparency-go v1.0.21/go.mod h1:QeJfpSbVSfYc7RgB3gJFj9cbuQMMchQxrWXz8Ruopmg= -github.com/google/gnostic v0.5.7-v3refs h1:FhTMOKj2VhjpouxvWJAV1TL304uMlb9zcDqkl6cEI54= github.com/google/gnostic v0.5.7-v3refs/go.mod h1:73MKFl6jIHelAJNaBGFzt3SPtZULs9dYrGFt8OiIsHQ= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= @@ -245,7 +186,7 @@ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ= +github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.1.0 h1:Hsa8mG0dQ46ij8Sl2AYJDUv1oA9/d6Vk+3LG99Oe02g= github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= @@ -261,6 +202,7 @@ github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hf github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= @@ -269,16 +211,14 @@ github.com/google/uuid v1.1.2 h1:EVhdT+1Kseyi1/pUmXKaFxYsDNy9RQYkMWRH68J/W7Y= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= -github.com/googleapis/gnostic v0.5.1/go.mod h1:6U4PtQXGIEt/Z3h5MAT7FNofLnw9vXk2cUuW7uA/OeU= +github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= -github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q= github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= @@ -308,35 +248,22 @@ github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJ github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= -github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/jmhodges/clock v0.0.0-20160418191101-880ee4c33548/go.mod h1:hGT6jSUVzF6no3QaDSMLGLEHtHSBSefs+MgcDWnmhmo= -github.com/jmoiron/sqlx v1.2.0 h1:41Ip0zITnmWNR/vHV+S4m+VoUivnWY5E4OJfLZjCJMA= -github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks= +github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= +github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= -github.com/jonboulle/clockwork v0.2.2/go.mod h1:Pkfl5aHPm1nk2H9h0bjmnJD/BcgbGXUBGnn1kMkgxc8= -github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= -github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= -github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= -github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/kisielk/sqlstruct v0.0.0-20150923205031-648daed35d49/go.mod h1:yyMNCyc/Ib3bDTKd379tNMpB/7/H5TjM2Y9QJ5THLbE= -github.com/kisom/goutils v1.1.0/go.mod h1:+UBTfd78habUYWFbNWTJNG+jNG/i/lGURakr4A/yNRw= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= -github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= @@ -345,24 +272,15 @@ github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/kylelemons/go-gypsy v0.0.0-20160905020020-08cad365cd28/go.mod h1:T/T7jsxVqf9k/zYOqbgNAsANsjxTd1Yq3htjDhQ1H0c= github.com/leodido/go-urn v1.2.1 h1:BqpAaACuzVSgi/VLzGZIobT2z4v53pjosyNd9Yv6n/w= github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= -github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.3.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= -github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.7.0/go.mod h1:KAzv3t3aY1NaHWoQz1+4F1ccyAH66Jk7yos7ldAVICs= -github.com/mailru/easyjson v0.7.6 h1:8yTIVnZgCoiM1TgqoeTl+LfU5Jg6/xL3QhGQnimLYnA= github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= -github.com/mattn/go-sqlite3 v1.10.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= github.com/mitchellh/copystructure v1.0.0 h1:Laisrj+bAB6b/yJwB5Bt3ITZhGJdqmxquMKeZ+mmkFQ= @@ -374,175 +292,109 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4 github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.1 h1:CpVNEelQCZBooIPDn+AR3NpivK/TIKU8bDxdASFVQag= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/reflectwalk v1.0.0 h1:9D+8oIskB4VJBN5SFlmc27fSlIBZaov1Wpk/IfikLNY= github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= -github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6/go.mod h1:E2VnQOmVuvZB6UYnnDB0qG5Nq/1tD9acaOpo6xmt0Kw= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 h1:n6/2gBQ3RWajuToeY6ZtZTIKv2v7ThUy5KKusIT0yc0= -github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00/go.mod h1:Pm3mSP3c5uWn86xMLZ5Sa7JB9GsEZySvHYXCTK4E9q4= -github.com/mreiferson/go-httpclient v0.0.0-20160630210159-31f0106b4474/go.mod h1:OQA4XLvDbMgS8P0CevmM4m9Q3Jq4phKUzcocxuGJ5m8= github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e h1:fD57ERR4JtEqsWbfPhv4DMiApHyliiK5xCTNVSPiaAs= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= -github.com/nkovacs/streamquote v0.0.0-20170412213628-49af9bddb229/go.mod h1:0aYXnNPJ8l7uZxf45rWW1a/uME32OF0rhiYGNQ2oF2E= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= -github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= -github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= -github.com/onsi/ginkgo/v2 v2.1.4 h1:GNapqRSid3zijZ9H77KrgVG4/8KqiyRsxcSxe+7ApXY= +github.com/onsi/ginkgo/v2 v2.7.0 h1:/XxtEV3I3Eif/HobnVx9YmJgk8ENdRsuUmM+fLCFNow= github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= -github.com/onsi/gomega v1.19.0 h1:4ieX6qQjPP/BfC3mpsAtIGGlxTWPeA3Inl/7DtXw1tw= -github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= -github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= +github.com/onsi/gomega v1.24.2 h1:J/tulyYK6JwBldPViHJReihxxZ+22FHs0piGjQAvoUE= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= -github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI= +github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= -github.com/pquerna/cachecontrol v0.0.0-20171018203845-0dec1b30a021/go.mod h1:prYjPmNq4d1NPVmpShWobRqXY3q7Vp+80DqgxxUrUIA= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= -github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= -github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= -github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= -github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= -github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= -github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= -github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= -github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= -github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= github.com/shopspring/decimal v1.2.0 h1:abSATXmQEYyShuxI4/vyW3tV1MrKAJzCZ/0zLUXYbsQ= github.com/shopspring/decimal v1.2.0/go.mod h1:DKyhrW/HYNuLGql+MJL6WCR6knT2jwCFRcu2hWCYk4o= github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= -github.com/sirupsen/logrus v1.3.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= -github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= -github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= -github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE= -github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= +github.com/sirupsen/logrus v1.9.0 h1:trlNQbNUG3OdDrDil03MCb1H2o9nJ1x4/5LYw7byDE0= +github.com/sirupsen/logrus v1.9.0/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= -github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= -github.com/spf13/afero v1.6.0 h1:xoax2sJ2DT8S8xA2paPFjDCScCNeWsg75VG0DLRreiY= -github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I= +github.com/spf13/afero v1.9.3 h1:41FoI0fD7OR7mGcKE/aOiLkGreyf8ifIOQmJANWogMk= +github.com/spf13/afero v1.9.3/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cast v1.3.1 h1:nFm6S0SMdyzrzcmThSipiEubIDy8WEXKNZ0UOgiRpng= github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cobra v1.1.3/go.mod h1:pGADOWyqRD/YMrPZigI/zbliZ2wVD/23d+is3pSWzOo= -github.com/spf13/cobra v1.2.1/go.mod h1:ExllRjgxM/piMAM+3tAZvg8fsklGAf3tPfi+i8t68Nk= -github.com/spf13/cobra v1.4.0 h1:y+wJpx64xcgO1V+RcnwW0LEHxTKRi2ZDPSBjWnrg88Q= -github.com/spf13/cobra v1.4.0/go.mod h1:Wo4iy3BUC+X2Fybo0PDqwJIv3dNRiZLHQymsfxlB84g= +github.com/spf13/cobra v1.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA= +github.com/spf13/cobra v1.6.1/go.mod h1:IOw/AERYS7UzyrGinqmz6HLUo219MORXGxhbaJUqzrY= github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= -github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo= -github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= -github.com/spf13/viper v1.8.1/go.mod h1:o0Pch8wJ9BVSWGQMbra6iw0oQ5oktSIBaujf1rJH9Ns= github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.2.0 h1:Hbg2NidpLE8veEBkEZTL3CvlkUIVzuU9jDplZO54c48= -github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= +github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= +github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= +github.com/stretchr/testify v1.8.1 h1:w7B6lhMri9wdJUVmEZPGGhZzrYTPvgJArz7wNPgYKsk= +github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/tmc/grpc-websocket-proxy v0.0.0-20201229170055-e5319fda7802/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/vmware-tanzu-labs/object-code-generator-for-k8s v0.5.0 h1:9dPvy3CTfTipij2wu7fzcRLxh/KYs3oaLiBR8uF+vDM= github.com/vmware-tanzu-labs/object-code-generator-for-k8s v0.5.0/go.mod h1:Cf1te3B0f1QfeXuquaasWxH+Xv6TCDvPMx6AOYkiH2I= -github.com/weppos/publicsuffix-go v0.4.0/go.mod h1:z3LCPQ38eedDQSwmsSRW4Y7t2L8Ln16JPQ02lHAdn5k= -github.com/weppos/publicsuffix-go v0.13.0 h1:0Tu1uzLBd1jPn4k6OnMmOPZH/l/9bj9kUOMMkoRs6Gg= -github.com/weppos/publicsuffix-go v0.13.0/go.mod h1:z3LCPQ38eedDQSwmsSRW4Y7t2L8Ln16JPQ02lHAdn5k= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= -github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca h1:1CFlNzQhALwjS9mBAUkycX616GzgsuYUOCHA5+HSlXI= -github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -github.com/ziutek/mymysql v1.5.4/go.mod h1:LMSpPZ6DbqWFxNCHW77HeMg9I646SAhApZ/wKdgO/C0= -github.com/zmap/rc2 v0.0.0-20131011165748-24b9757f5521/go.mod h1:3YZ9o3WnatTIZhuOtot4IcUfzoKVjUHqu6WALIyI0nE= -github.com/zmap/zcertificate v0.0.0-20180516150559-0e3d58b1bac4/go.mod h1:5iU54tB79AMBcySS0R2XIyZBAVmeHranShAFELYx7is= -github.com/zmap/zcrypto v0.0.0-20200513165325-16679db567ff/go.mod h1:TxpejqcVKQjQaVVmMGfzx5HnmFMdIU+vLtaCyPBfGI4= -github.com/zmap/zcrypto v0.0.0-20200911161511-43ff0ea04f21 h1:PIpcdSOg3pMdFJUBg5yR9xxcj5rm/SGAyaWT/wK6Kco= -github.com/zmap/zcrypto v0.0.0-20200911161511-43ff0ea04f21/go.mod h1:TxpejqcVKQjQaVVmMGfzx5HnmFMdIU+vLtaCyPBfGI4= -github.com/zmap/zlint/v2 v2.2.1 h1:b2kI/ToXX16h2wjV2c6Da65eT6aTMtkLHKetXuM9EtI= -github.com/zmap/zlint/v2 v2.2.1/go.mod h1:ixPWsdq8qLxYRpNUTbcKig3R7WgmspsHGLhCCs6rFAM= go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4= -go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= -go.etcd.io/etcd/api/v3 v3.5.1/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= -go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g= -go.etcd.io/etcd/client/pkg/v3 v3.5.1/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g= -go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ= -go.etcd.io/etcd/client/v3 v3.5.0/go.mod h1:AIKXXVX/DQXtfTEqBryiLTUXwON+GuvO6Z7lLS/oTh0= -go.etcd.io/etcd/client/v3 v3.5.1/go.mod h1:OnjH4M8OnAotwaB2l9bVgZzRFKru7/ZMoS46OtKyd3Q= -go.etcd.io/etcd/pkg/v3 v3.5.0/go.mod h1:UzJGatBQ1lXChBkQF0AuAtkRQMYnHubxAEYIrC3MSsE= -go.etcd.io/etcd/raft/v3 v3.5.0/go.mod h1:UFOHSIvO/nKwd4lhkwabrTD3cqW5yVyYYf/KlD00Szc= -go.etcd.io/etcd/server/v3 v3.5.0/go.mod h1:3Ah5ruV+M+7RZr0+Y/5mNLwC+eQlni+mQmOVdCRJoS4= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= @@ -550,42 +402,21 @@ go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= -go.opentelemetry.io/contrib v0.20.0/go.mod h1:G/EtFaa6qaN7+LxqfIAT3GiZa7Wv5DTBUzl5H4LY0Kc= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.20.0/go.mod h1:oVGt1LRbBOBq1A5BQLlUg9UaU/54aiHw8cgjV3aWZ/E= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.20.0/go.mod h1:2AboqHi0CiIZU0qwhtUfCYD1GeUzvvIXWNkhDt7ZMG4= -go.opentelemetry.io/otel v0.20.0/go.mod h1:Y3ugLH2oa81t5QO+Lty+zXf8zC9L26ax4Nzoxm/dooo= -go.opentelemetry.io/otel/exporters/otlp v0.20.0/go.mod h1:YIieizyaN77rtLJra0buKiNBOm9XQfkPEKBeuhoMwAM= -go.opentelemetry.io/otel/metric v0.20.0/go.mod h1:598I5tYlH1vzBjn+BTuhzTCSb/9debfNp6R3s7Pr1eU= -go.opentelemetry.io/otel/oteltest v0.20.0/go.mod h1:L7bgKf9ZB7qCwT9Up7i9/pn0PWIa9FqQ2IQ8LoxiGnw= -go.opentelemetry.io/otel/sdk v0.20.0/go.mod h1:g/IcepuwNsoiX5Byy2nNV0ySUF1em498m7hBWC279Yc= -go.opentelemetry.io/otel/sdk/export/metric v0.20.0/go.mod h1:h7RBNMsDJ5pmI1zExLi+bJK+Dr8NQCh0qGhm1KDnNlE= -go.opentelemetry.io/otel/sdk/metric v0.20.0/go.mod h1:knxiS8Xd4E/N+ZqKmUPf3gTTZ4/0TjTXukfxjzSTpHE= -go.opentelemetry.io/otel/trace v0.20.0/go.mod h1:6GjCW8zgDjwGHGa6GkyeB8+/5vjT16gUEi0Nf1iBdgw= -go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= -go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5/go.mod h1:nmDLcffg48OtT/PSW0Hg7FvpRQsQh5OSqIylirxKC7o= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= -go.uber.org/goleak v1.1.10/go.mod h1:8a7PlsEVH3e/a/GLqe5IIrQx6GzcnRmZEufDUTk4A7A= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= -go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= -go.uber.org/zap v1.17.0/go.mod h1:MXVU+bhUf/A7Xi2HNOnopQOrmycQ5Ih87HtOu4q5SSo= -go.uber.org/zap v1.19.0/go.mod h1:xg/QME4nWcxGxrpdeYfq7UvYrLh66cuVKdrbD1XF/NI= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20200124225646-8b5121be2f68/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200414173820-0848c9571904/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201012173705-84dcc777aaee/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= -golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= +golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= +golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220214200702-86341886e292 h1:f+lwQ+GtmgoY+A2YaQxlSOnDjXcQ7ZRLWOHbC6HtRqE= golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -611,7 +442,6 @@ golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRu golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= -golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= @@ -623,8 +453,8 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3 h1:kQgndtyPBW/JIYERgdxfwMYh3AVStj88WQTlNDi2a+o= -golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= +golang.org/x/mod v0.7.0 h1:LapD9S96VoQRhi/GrNTqeBJFrUjs5UHCAtTlgwA5oZA= +golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -639,7 +469,6 @@ golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= -golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -659,23 +488,19 @@ golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/ golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.0.0-20201010224723-4f7140c49acb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= -golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20210825183410-e898025ed96a/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220225172249-27dd8689420f h1:oA4XRj0qtSt8Yo1Zms0CUlsT3KG69V2UGQWPBxujDmc= -golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.5.0 h1:GyT4nK/YDHSqa1c4753ouYCDajOYKTja9Xb/OHtgvSw= +golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -687,8 +512,6 @@ golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20210402161424-2e8d93401602/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -701,6 +524,7 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -711,7 +535,6 @@ golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -719,13 +542,11 @@ golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191002063906-3421d5a6bb1c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -739,35 +560,28 @@ golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210831042530-f4d43177bf5e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220319134239-a9b59b0215f8 h1:OH54vjqzRWmbJ62fjuhxy7AxFFgoHN0/DPc/UrL8cAs= -golang.org/x/sys v0.0.0-20220319134239-a9b59b0215f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.4.0 h1:Zr2JFtRQNX3BCZ8YtxRE9hNJYC8J6I1MVbMg6owUp18= +golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= @@ -779,16 +593,15 @@ golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.6.0 h1:3XmdazWV+ubf7QgHSTWeykHOci5oeekaGJBLkrkaw4k= +golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20220210224613-90d013bbcef8/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= @@ -800,12 +613,10 @@ golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBn golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191108193012-7d206e10da11/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191112195655-aa38f8e97acc/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -840,16 +651,14 @@ golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= +golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= -golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.10-0.20220218145154-897bd77cd717/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= -golang.org/x/tools v0.1.10 h1:QjFRCZxdOhBJ/UNgnBZLbNV13DlbnK0quyivTnXJM20= -golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= +golang.org/x/tools v0.5.0 h1:+bSpV5HIeWkuvgaMfI3UmKRThoTA5ODJTUd8T17NO+4= +golang.org/x/tools v0.5.0/go.mod h1:N+Kgy78s5I24c24dU8OfWNEotWjutIs8SnJvn5IDq+k= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= @@ -872,7 +681,6 @@ google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34q google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8= google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU= google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94= -google.golang.org/api v0.44.0/go.mod h1:EBOGZqzyhtvMDoxwS97ctnh0zUmYY6CxqXsc1AvkYD8= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -901,10 +709,8 @@ google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200423170343-7949de9c1215/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA= @@ -913,19 +719,17 @@ google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201019141844-1ed22bb0c154/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20201102152239-715cce707fb0/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201109203340-2640f1f9cdfb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= -google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= -google.golang.org/genproto v0.0.0-20210831024726-fe130286e0e2/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= -google.golang.org/genproto v0.0.0-20220107163113-42d7afdf6368/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -939,15 +743,11 @@ google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3Iji google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0= google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc v1.37.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= -google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= -google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= @@ -960,7 +760,6 @@ google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGj google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.27.1 h1:SnqbnDw1V7RiZcXPx5MEeqPv2s79L9i7BJUlG/+RurQ= google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -975,28 +774,21 @@ gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8 gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/ini.v1 v1.62.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= -gopkg.in/square/go-jose.v2 v2.2.2/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= -gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -1006,24 +798,15 @@ honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= k8s.io/api v0.24.2 h1:g518dPU/L7VRLxWfcadQn2OnsiGWVOadTLpdnqgY2OI= k8s.io/api v0.24.2/go.mod h1:AHqbSkTm6YrQ0ObxjO3Pmp/ubFF/KuM7jU+3khoBsOg= -k8s.io/apiextensions-apiserver v0.24.2 h1:/4NEQHKlEz1MlaK/wHT5KMKC9UKYz6NZz6JE6ov4G6k= -k8s.io/apiextensions-apiserver v0.24.2/go.mod h1:e5t2GMFVngUEHUd0wuCJzw8YDwZoqZfJiGOW6mm2hLQ= k8s.io/apimachinery v0.24.2 h1:5QlH9SL2C8KMcrNJPor+LbXVTaZRReml7svPEh4OKDM= k8s.io/apimachinery v0.24.2/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= -k8s.io/apiserver v0.24.2/go.mod h1:pSuKzr3zV+L+MWqsEo0kHHYwCo77AT5qXbFXP2jbvFI= k8s.io/client-go v0.24.2 h1:CoXFSf8if+bLEbinDqN9ePIDGzcLtqhfd6jpfnwGOFA= k8s.io/client-go v0.24.2/go.mod h1:zg4Xaoo+umDsfCWr4fCnmLEtQXyCNXCvJuSsglNcV30= -k8s.io/code-generator v0.24.2/go.mod h1:dpVhs00hTuTdTY6jvVxvTFCk6gSMrtfRydbhZwHI15w= -k8s.io/component-base v0.24.2/go.mod h1:ucHwW76dajvQ9B7+zecZAP3BVqvrHoOxm8olHEg0nmM= -k8s.io/gengo v0.0.0-20200413195148-3a45101e95ac/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0= k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= -k8s.io/gengo v0.0.0-20211129171323-c02415ce4185/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE= k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y= k8s.io/klog/v2 v2.60.1 h1:VW25q3bZx9uE3vvdL6M8ezOX79vA2Aq1nEWLqNQclHc= k8s.io/klog/v2 v2.60.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -k8s.io/kube-openapi v0.0.0-20210421082810-95288971da7e/go.mod h1:vHXdDvt9+2spS2Rx9ql3I8tycm3H9FDfdUoIuKCefvw= -k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42 h1:Gii5eqf+GmIEwGNKQYQClCayuJCe2/4fZUvF7VG99sU= k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42/go.mod h1:Z/45zLw8lUo4wdiUkI+v/ImEGAvu3WatcZl3lPMR4Rk= k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9 h1:HNSDgDCrr/6Ly3WEGKZftiE7IY19Vz2GdbOCyI4qqhc= @@ -1031,17 +814,10 @@ k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9/go.mod h1:jPW/WVKK9YHAvNhRxK0md/ rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= -sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.30/go.mod h1:fEO7lRTdivWO2qYVCVG7dEADOMo/MLDCVr8So2g88Uw= -sigs.k8s.io/controller-runtime v0.12.2 h1:nqV02cvhbAj7tbt21bpPpTByrXGn2INHRsi39lXy9sE= -sigs.k8s.io/controller-runtime v0.12.2/go.mod h1:qKsk4WE6zW2Hfj0G4v10EnNB2jMG1C+NTb8h+DwCoU0= -sigs.k8s.io/controller-tools v0.9.2 h1:AkTE3QAdz9LS4iD3EJvHyYxBkg/g9fTbgiYsrcsFCcM= -sigs.k8s.io/controller-tools v0.9.2/go.mod h1:NUkn8FTV3Sad3wWpSK7dt/145qfuQ8CKJV6j4jHC5rM= sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2 h1:kDi4JBNAsJWfz1aEXhO8Jg87JJaPNLh5tIzYHgStQ9Y= sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2/go.mod h1:B+TnT182UBxE84DiCz4CVE26eOSDAeYCpfDnC2kdKMY= -sigs.k8s.io/kubebuilder/v3 v3.7.0 h1:o1ZsPgnZB9ddS2wUqL2Nw812PQzaCccNyu83uRS09ws= -sigs.k8s.io/kubebuilder/v3 v3.7.0/go.mod h1:3VwM89VsNnBbOuee1vhq7wOTh8oUwsk1IibeNaByqP4= -sigs.k8s.io/kustomize/kyaml v0.13.6 h1:eF+wsn4J7GOAXlvajv6OknSunxpcOBQQqsnPxObtkGs= -sigs.k8s.io/kustomize/kyaml v0.13.6/go.mod h1:yHP031rn1QX1lr/Xd934Ri/xdVNG8BE2ECa78Ht/kEg= +sigs.k8s.io/kubebuilder/v3 v3.9.1 h1:9JNKRg9GzlLBYwYRx1nQlwha8+Pd9gPyat1lj7T+jZw= +sigs.k8s.io/kubebuilder/v3 v3.9.1/go.mod h1:Z4boifT/XHIZTVEAIZaPTXqjhuK8Msx2iPYJy8ic6vg= sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw= sigs.k8s.io/structured-merge-diff/v4 v4.2.1 h1:bKCqE9GvQ5tiVHn5rfn1r+yao3aLQEaLzkkmAkf+A6Y= sigs.k8s.io/structured-merge-diff/v4 v4.2.1/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4= diff --git a/internal/license/license.go b/internal/license/license.go index 02562e6..7fd4262 100644 --- a/internal/license/license.go +++ b/internal/license/license.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/inspect/inspector.go b/internal/markers/inspect/inspector.go index 58059d2..7617c21 100644 --- a/internal/markers/inspect/inspector.go +++ b/internal/markers/inspect/inspector.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/inspect/transform.go b/internal/markers/inspect/transform.go index d214d67..ab765a0 100644 --- a/internal/markers/inspect/transform.go +++ b/internal/markers/inspect/transform.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/inspect/yaml.go b/internal/markers/inspect/yaml.go index 841cfcd..9f7856e 100644 --- a/internal/markers/inspect/yaml.go +++ b/internal/markers/inspect/yaml.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/consume.go b/internal/markers/lexer/consume.go index 5fc37ed..d172708 100644 --- a/internal/markers/lexer/consume.go +++ b/internal/markers/lexer/consume.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/consume_internal_test.go b/internal/markers/lexer/consume_internal_test.go index ca267be..60e10d0 100644 --- a/internal/markers/lexer/consume_internal_test.go +++ b/internal/markers/lexer/consume_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/discard.go b/internal/markers/lexer/discard.go index f76a0c9..e15277b 100644 --- a/internal/markers/lexer/discard.go +++ b/internal/markers/lexer/discard.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/emit.go b/internal/markers/lexer/emit.go index 89f91a2..94273eb 100644 --- a/internal/markers/lexer/emit.go +++ b/internal/markers/lexer/emit.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/error.go b/internal/markers/lexer/error.go index bc72172..5c8b583 100644 --- a/internal/markers/lexer/error.go +++ b/internal/markers/lexer/error.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/lexeme.go b/internal/markers/lexer/lexeme.go index e9781b9..1d10e8a 100644 --- a/internal/markers/lexer/lexeme.go +++ b/internal/markers/lexer/lexeme.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/lexer.go b/internal/markers/lexer/lexer.go index 15594c8..5eee35e 100644 --- a/internal/markers/lexer/lexer.go +++ b/internal/markers/lexer/lexer.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/lexer_test.go b/internal/markers/lexer/lexer_test.go index 7b6e352..15879dc 100644 --- a/internal/markers/lexer/lexer_test.go +++ b/internal/markers/lexer/lexer_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/peek.go b/internal/markers/lexer/peek.go index cc2707d..3af9c50 100644 --- a/internal/markers/lexer/peek.go +++ b/internal/markers/lexer/peek.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/peek_internal_test.go b/internal/markers/lexer/peek_internal_test.go index 7008640..d6c77a9 100644 --- a/internal/markers/lexer/peek_internal_test.go +++ b/internal/markers/lexer/peek_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/position.go b/internal/markers/lexer/position.go index c3f2f24..acd4ccd 100644 --- a/internal/markers/lexer/position.go +++ b/internal/markers/lexer/position.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/stack.go b/internal/markers/lexer/stack.go index f10bdb0..a329e3f 100644 --- a/internal/markers/lexer/stack.go +++ b/internal/markers/lexer/stack.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/lexer/state.go b/internal/markers/lexer/state.go index b3ffc13..cf609cb 100644 --- a/internal/markers/lexer/state.go +++ b/internal/markers/lexer/state.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/marker/argument.go b/internal/markers/marker/argument.go index 435aeae..b54614d 100644 --- a/internal/markers/marker/argument.go +++ b/internal/markers/marker/argument.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/marker/marker.go b/internal/markers/marker/marker.go index 1b0c741..4d8aaa0 100644 --- a/internal/markers/marker/marker.go +++ b/internal/markers/marker/marker.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/marker/marker_internal_test.go b/internal/markers/marker/marker_internal_test.go index b0c27fd..6c8c26a 100644 --- a/internal/markers/marker/marker_internal_test.go +++ b/internal/markers/marker/marker_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/marker/registry.go b/internal/markers/marker/registry.go index 2d9b2e6..5ae19a8 100644 --- a/internal/markers/marker/registry.go +++ b/internal/markers/marker/registry.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/marker/utils.go b/internal/markers/marker/utils.go index 0fce68e..574b4df 100644 --- a/internal/markers/marker/utils.go +++ b/internal/markers/marker/utils.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/consumed.go b/internal/markers/parser/consumed.go index 65d840a..450dfef 100644 --- a/internal/markers/parser/consumed.go +++ b/internal/markers/parser/consumed.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/definition.go b/internal/markers/parser/definition.go index 5e6394e..3f09d7f 100644 --- a/internal/markers/parser/definition.go +++ b/internal/markers/parser/definition.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/emit.go b/internal/markers/parser/emit.go index a53f090..b2f8d13 100644 --- a/internal/markers/parser/emit.go +++ b/internal/markers/parser/emit.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/error.go b/internal/markers/parser/error.go index 03fa10b..55a3cc5 100644 --- a/internal/markers/parser/error.go +++ b/internal/markers/parser/error.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/parser.go b/internal/markers/parser/parser.go index 82475a1..04243b9 100644 --- a/internal/markers/parser/parser.go +++ b/internal/markers/parser/parser.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/peek.go b/internal/markers/parser/peek.go index 5ea7f2c..fd9615b 100644 --- a/internal/markers/parser/peek.go +++ b/internal/markers/parser/peek.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/position.go b/internal/markers/parser/position.go index 86133ed..5df9ce9 100644 --- a/internal/markers/parser/position.go +++ b/internal/markers/parser/position.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/registry.go b/internal/markers/parser/registry.go index 48e7bd0..67d08bb 100644 --- a/internal/markers/parser/registry.go +++ b/internal/markers/parser/registry.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/state.go b/internal/markers/parser/state.go index 8dbd5b5..82c1643 100644 --- a/internal/markers/parser/state.go +++ b/internal/markers/parser/state.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/markers/parser/unmarshal.go b/internal/markers/parser/unmarshal.go index 440cb44..7755833 100644 --- a/internal/markers/parser/unmarshal.go +++ b/internal/markers/parser/unmarshal.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/config/v1/api.go b/internal/plugins/config/v1/api.go index 972678f..cf75cac 100644 --- a/internal/plugins/config/v1/api.go +++ b/internal/plugins/config/v1/api.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -20,12 +20,14 @@ import ( type createAPISubcommand struct { workloadConfigPath string workload kinds.WorkloadBuilder + enableOlm bool } var _ plugin.CreateAPISubcommand = &createAPISubcommand{} func (p *createAPISubcommand) BindFlags(fs *pflag.FlagSet) { fs.StringVar(&p.workloadConfigPath, "workload-config", "", "path to workload config file") + fs.BoolVar(&p.enableOlm, "enable-olm", false, "enable support for OpenShift Lifecycle Manager") } func (p *createAPISubcommand) InjectConfig(c config.Config) error { diff --git a/internal/plugins/config/v1/init.go b/internal/plugins/config/v1/init.go index 2f4f058..c531d3d 100644 --- a/internal/plugins/config/v1/init.go +++ b/internal/plugins/config/v1/init.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -18,6 +18,7 @@ import ( type initSubcommand struct { workloadConfigPath string controllerImage string + enableOlm bool } var _ plugin.InitSubcommand = &initSubcommand{} @@ -25,6 +26,7 @@ var _ plugin.InitSubcommand = &initSubcommand{} func (p *initSubcommand) BindFlags(fs *pflag.FlagSet) { fs.StringVar(&p.workloadConfigPath, "workload-config", "", "path to workload config file") fs.StringVar(&p.controllerImage, "controller-image", "controller:latest", "controller image") + fs.BoolVar(&p.enableOlm, "enable-olm", false, "enable support for Operator Lifecycle Manager (OLM)") } func (p *initSubcommand) InjectConfig(c config.Config) error { @@ -37,6 +39,7 @@ func (p *initSubcommand) InjectConfig(c config.Config) error { WorkloadConfigPath: p.workloadConfigPath, CliRootCommandName: processor.Workload.GetRootCommand().Name, ControllerImg: p.controllerImage, + EnableOLM: p.enableOlm, } if err := c.EncodePluginConfig(workloadconfig.PluginKey, pluginConfig); err != nil { diff --git a/internal/plugins/config/v1/plugin.go b/internal/plugins/config/v1/plugin.go index aaf590d..09cfa8e 100644 --- a/internal/plugins/config/v1/plugin.go +++ b/internal/plugins/config/v1/plugin.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/domain.go b/internal/plugins/domain.go index ecb466e..89a4308 100644 --- a/internal/plugins/domain.go +++ b/internal/plugins/domain.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/license/v1/init.go b/internal/plugins/license/v1/init.go index 2e1f3b5..f9854b0 100644 --- a/internal/plugins/license/v1/init.go +++ b/internal/plugins/license/v1/init.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/license/v1/plugin.go b/internal/plugins/license/v1/plugin.go index 3b8d1df..00d1330 100644 --- a/internal/plugins/license/v1/plugin.go +++ b/internal/plugins/license/v1/plugin.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/api.go b/internal/plugins/workload/v1/api.go index 39f0f35..db454b4 100644 --- a/internal/plugins/workload/v1/api.go +++ b/internal/plugins/workload/v1/api.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -27,6 +27,7 @@ type createAPISubcommand struct { workloadConfigPath string cliRootCommandName string workload kinds.WorkloadBuilder + enableOlm bool } var ErrScaffoldCreateAPI = errors.New("unable to scaffold api") @@ -51,6 +52,7 @@ func (p *createAPISubcommand) InjectConfig(c config.Config) error { p.workloadConfigPath = pluginConfig.WorkloadConfigPath p.cliRootCommandName = pluginConfig.CliRootCommandName + p.enableOlm = pluginConfig.EnableOLM return nil } @@ -64,11 +66,11 @@ func (p *createAPISubcommand) InjectResource(res *resource.Resource) error { func (p *createAPISubcommand) PreScaffold(machinery.Filesystem) error { processor, err := workloadconfig.Parse(p.workloadConfigPath) if err != nil { - return fmt.Errorf("%s for %s, %w", ErrScaffoldCreateAPI, p.workloadConfigPath, err) + return fmt.Errorf("%s for %s, %w", ErrScaffoldCreateAPI.Error(), p.workloadConfigPath, err) } if err := subcommand.CreateAPI(processor); err != nil { - return fmt.Errorf("%s for %s, %w", ErrScaffoldCreateAPI, p.workloadConfigPath, err) + return fmt.Errorf("%s for %s, %w", ErrScaffoldCreateAPI.Error(), p.workloadConfigPath, err) } p.workload = processor.Workload @@ -82,11 +84,12 @@ func (p *createAPISubcommand) Scaffold(fs machinery.Filesystem) error { p.resource, p.workload, p.cliRootCommandName, + p.enableOlm, ) scaffolder.InjectFS(fs) if err := scaffolder.Scaffold(); err != nil { - return fmt.Errorf("%s for %s, %w", ErrScaffoldInit, p.workloadConfigPath, err) + return fmt.Errorf("%s for %s, %w", ErrScaffoldInit.Error(), p.workloadConfigPath, err) } return nil diff --git a/internal/plugins/workload/v1/init.go b/internal/plugins/workload/v1/init.go index b549c87..5af750b 100644 --- a/internal/plugins/workload/v1/init.go +++ b/internal/plugins/workload/v1/init.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -24,6 +24,7 @@ type initSubcommand struct { workloadConfigPath string cliRootCommandName string controllerImg string + enableOlm bool workload kinds.WorkloadBuilder } @@ -56,6 +57,7 @@ func (p *initSubcommand) InjectConfig(c config.Config) error { p.workloadConfigPath = pluginConfig.WorkloadConfigPath p.cliRootCommandName = pluginConfig.CliRootCommandName p.controllerImg = pluginConfig.ControllerImg + p.enableOlm = pluginConfig.EnableOLM return nil } @@ -63,11 +65,11 @@ func (p *initSubcommand) InjectConfig(c config.Config) error { func (p *initSubcommand) PreScaffold(machinery.Filesystem) error { processor, err := workloadconfig.Parse(p.workloadConfigPath) if err != nil { - return fmt.Errorf("%s for %s, %w", ErrScaffoldInit, p.workloadConfigPath, err) + return fmt.Errorf("%s for %s, %w", ErrScaffoldInit.Error(), p.workloadConfigPath, err) } if err := subcommand.Init(processor); err != nil { - return fmt.Errorf("%s for %s, %w", ErrScaffoldInit, p.workloadConfigPath, err) + return fmt.Errorf("%s for %s, %w", ErrScaffoldInit.Error(), p.workloadConfigPath, err) } p.workload = processor.Workload @@ -81,11 +83,12 @@ func (p *initSubcommand) Scaffold(fs machinery.Filesystem) error { p.workload, p.cliRootCommandName, p.controllerImg, + p.enableOlm, ) scaffolder.InjectFS(fs) if err := scaffolder.Scaffold(); err != nil { - return fmt.Errorf("%s for %s, %w", ErrScaffoldInit, p.workloadConfigPath, err) + return fmt.Errorf("%s for %s, %w", ErrScaffoldInit.Error(), p.workloadConfigPath, err) } return nil diff --git a/internal/plugins/workload/v1/plugin.go b/internal/plugins/workload/v1/plugin.go index 4bed644..f7f990f 100644 --- a/internal/plugins/workload/v1/plugin.go +++ b/internal/plugins/workload/v1/plugin.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/api.go b/internal/plugins/workload/v1/scaffolds/api.go index a133ecb..24952ae 100644 --- a/internal/plugins/workload/v1/scaffolds/api.go +++ b/internal/plugins/workload/v1/scaffolds/api.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -59,6 +59,7 @@ type apiScaffolder struct { boilerplate string workload kinds.WorkloadBuilder cliRootCommandName string + enableOlm bool } // NewAPIScaffolder returns a new Scaffolder for project initialization operations. @@ -67,12 +68,14 @@ func NewAPIScaffolder( res *resource.Resource, workload kinds.WorkloadBuilder, cliRootCommandName string, + enableOlm bool, ) plugins.Scaffolder { return &apiScaffolder{ config: cfg, resource: res, workload: workload, cliRootCommandName: cliRootCommandName, + enableOlm: enableOlm, } } @@ -100,7 +103,7 @@ func (s *apiScaffolder) Scaffold() error { // scaffold the workload if err := s.scaffoldWorkload(scaffold, s.workload); err != nil { - return fmt.Errorf("%w; %s for workload type %T", err, ErrScaffoldWorkload, s.workload) + return fmt.Errorf("%w; %s for workload type %T", err, ErrScaffoldWorkload.Error(), s.workload) } return nil @@ -139,7 +142,7 @@ func (s *apiScaffolder) scaffoldWorkload( // items such as common resource methods, api type definitions and child resource typed // object definitions. if err := s.scaffoldAPI(scaffold, workload); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldAPIResources) + return fmt.Errorf("%w; %s", err, ErrScaffoldAPIResources.Error()) } // scaffold the controller. this generates the main controller logic. @@ -150,7 +153,7 @@ func (s *apiScaffolder) scaffoldWorkload( &mutate.Component{}, &crd.Kustomization{}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldController) + return fmt.Errorf("%w; %s", err, ErrScaffoldController.Error()) } // update controller main entrypoint. this updates the main.go file with logic related to @@ -161,7 +164,7 @@ func (s *apiScaffolder) scaffoldWorkload( WireController: true, }, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldMainUpdater) + return fmt.Errorf("%w; %s", err, ErrScaffoldMainUpdater.Error()) } // scaffold the custom resource sample files. this will generate sample manifest files. @@ -171,20 +174,25 @@ func (s *apiScaffolder) scaffoldWorkload( IsClusterScoped: workload.IsClusterScoped(), }, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldController) + return fmt.Errorf("%w; %s", err, ErrScaffoldCRDSample.Error()) + } + + // scaffold the kustomization sample if OLM is enabled. + if err := scaffold.Execute(&samples.Kustomization{}); err != nil { + return fmt.Errorf("%w; %s", err, ErrScaffoldKustomization.Error()) } // scaffold the end-to-end tests. this will generate some common end-to-end tests for // the controller. if err := scaffold.Execute(&e2e.WorkloadTest{Builder: workload}); err != nil { - return fmt.Errorf("%w; %s - error updating test/e2e/%s_%s_%s_test.go", err, ErrScaffoldController, + return fmt.Errorf("%w; %s - error updating test/e2e/%s_%s_%s_test.go", err, ErrScaffoldController.Error(), workload.GetAPIGroup(), workload.GetAPIVersion(), strings.ToLower(workload.GetAPIKind())) } // scaffold the companion CLI only if we have a root command name if s.cliRootCommandName != "" { if err := s.scaffoldCLI(scaffold, workload); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLI) + return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLI.Error()) } } @@ -193,7 +201,7 @@ func (s *apiScaffolder) scaffoldWorkload( if workload.IsCollection() { for _, component := range workload.GetComponents() { if err := s.scaffoldWorkload(scaffold, component); err != nil { - return fmt.Errorf("%w; %s for workload type %T", err, ErrScaffoldWorkload, component) + return fmt.Errorf("%w; %s for workload type %T", err, ErrScaffoldWorkload.Error(), component) } } } @@ -211,7 +219,7 @@ func (s *apiScaffolder) scaffoldAPI( &api.Types{Builder: workload}, &api.Group{}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldAPITypes) + return fmt.Errorf("%w; %s", err, ErrScaffoldAPITypes.Error()) } // scaffold the specific kind files @@ -220,14 +228,14 @@ func (s *apiScaffolder) scaffoldAPI( &api.KindLatest{PackageName: workload.GetPackageName()}, &api.KindUpdater{}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldAPIKindInfo) + return fmt.Errorf("%w; %s", err, ErrScaffoldAPIKindInfo.Error()) } // scaffold the resources if err := scaffold.Execute( &resources.Resources{Builder: workload}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldAPIResources) + return fmt.Errorf("%w; %s", err, ErrScaffoldAPIResources.Error()) } // scaffolds the child resource definition files @@ -236,7 +244,7 @@ func (s *apiScaffolder) scaffoldAPI( if err := scaffold.Execute( &resources.Definition{Builder: workload, Manifest: manifest}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldAPIChildResources) + return fmt.Errorf("%w; %s", err, ErrScaffoldAPIChildResources.Error()) } // update the child resource mutation for each child resource @@ -244,7 +252,7 @@ func (s *apiScaffolder) scaffoldAPI( if err := scaffold.Execute( &resources.Mutate{Builder: workload, ChildResource: manifest.ChildResources[i]}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldAPIChildResources) + return fmt.Errorf("%w; %s", err, ErrScaffoldAPIChildResources.Error()) } } } @@ -253,7 +261,7 @@ func (s *apiScaffolder) scaffoldAPI( if err := scaffold.Execute( &resources.Constants{Builder: workload}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldAPIResources) + return fmt.Errorf("%w; %s", err, ErrScaffoldAPIResources.Error()) } return nil @@ -270,7 +278,7 @@ func (s *apiScaffolder) scaffoldCLI( &cli.CmdInitSub{Builder: workload}, &cli.CmdInitSubUpdater{Builder: workload}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIInit) + return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIInit.Error()) } // scaffold the generate command unless we have a collection without resources @@ -279,7 +287,7 @@ func (s *apiScaffolder) scaffoldCLI( &cli.CmdGenerateSub{Builder: workload}, &cli.CmdGenerateSubUpdater{Builder: workload}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIGenerate) + return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIGenerate.Error()) } } @@ -288,7 +296,7 @@ func (s *apiScaffolder) scaffoldCLI( &cli.CmdVersionSub{Builder: workload}, &cli.CmdVersionSubUpdater{Builder: workload}, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIVersion) + return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIVersion.Error()) } // scaffold the root command @@ -300,7 +308,7 @@ func (s *apiScaffolder) scaffoldCLI( Builder: workload, }, ); err != nil { - return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIRoot) + return fmt.Errorf("%w; %s", err, ErrScaffoldCompanionCLIRoot.Error()) } return nil diff --git a/internal/plugins/workload/v1/scaffolds/init.go b/internal/plugins/workload/v1/scaffolds/init.go index dc4cdc4..13d6bb3 100644 --- a/internal/plugins/workload/v1/scaffolds/init.go +++ b/internal/plugins/workload/v1/scaffolds/init.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -12,13 +12,21 @@ import ( "sigs.k8s.io/kubebuilder/v3/pkg/config" "sigs.k8s.io/kubebuilder/v3/pkg/machinery" "sigs.k8s.io/kubebuilder/v3/pkg/plugins" + kustomizecommonv1 "sigs.k8s.io/kubebuilder/v3/pkg/plugins/common/kustomize/v1" + scaffoldsv4 "sigs.k8s.io/kubebuilder/v3/pkg/plugins/golang/v4/scaffolds" "github.com/nukleros/operator-builder/internal/plugins/workload/v1/scaffolds/templates" "github.com/nukleros/operator-builder/internal/plugins/workload/v1/scaffolds/templates/cli" + "github.com/nukleros/operator-builder/internal/plugins/workload/v1/scaffolds/templates/config/manifests" + "github.com/nukleros/operator-builder/internal/plugins/workload/v1/scaffolds/templates/config/scorecard" "github.com/nukleros/operator-builder/internal/plugins/workload/v1/scaffolds/templates/test/e2e" "github.com/nukleros/operator-builder/internal/workload/v1/kinds" ) +const ( + operatorSDKVersion = "v1.28.0" +) + var _ plugins.Scaffolder = &initScaffolder{} type initScaffolder struct { @@ -27,6 +35,7 @@ type initScaffolder struct { workload kinds.WorkloadBuilder cliRootCommandName string controllerImg string + enableOlm bool fs machinery.Filesystem } @@ -37,6 +46,7 @@ func NewInitScaffolder( workload kinds.WorkloadBuilder, cliRootCommandName string, controllerImg string, + enableOlm bool, ) plugins.Scaffolder { return &initScaffolder{ config: cfg, @@ -44,6 +54,7 @@ func NewInitScaffolder( workload: workload, cliRootCommandName: cliRootCommandName, controllerImg: controllerImg, + enableOlm: enableOlm, } } @@ -83,12 +94,44 @@ func (s *initScaffolder) Scaffold() error { &templates.Main{}, &templates.GoMod{}, &templates.Dockerfile{}, - &templates.Makefile{RootCmdName: s.cliRootCommandName, ControllerImg: s.controllerImg}, - &templates.Readme{RootCmdName: s.cliRootCommandName}, + &templates.Readme{ + RootCmdName: s.cliRootCommandName, + EnableOLM: s.enableOlm, + ControllerImg: s.controllerImg, + }, + &templates.Makefile{ + RootCmdName: s.cliRootCommandName, + ControllerImg: s.controllerImg, + EnableOLM: s.enableOlm, + KustomizeVersion: kustomizecommonv1.KustomizeVersion, + ControllerToolsVersion: scaffoldsv4.ControllerToolsVersion, + ControllerRuntimeVersion: scaffoldsv4.ControllerRuntimeVersion, + OperatorSDKVersion: operatorSDKVersion, + }, &e2e.Test{}, ); err != nil { return fmt.Errorf("unable to scaffold initial configuration, %w", err) } + if s.enableOlm { + if err := scaffold.Execute( + &scorecard.Scorecard{ScorecardType: scorecard.ScorecardTypeBase}, + &scorecard.Scorecard{ScorecardType: scorecard.ScorecardTypeKustomize}, + &scorecard.Scorecard{ScorecardType: scorecard.ScorecardTypePatchesBasic}, + &scorecard.Scorecard{ScorecardType: scorecard.ScorecardTypePatchesOLM}, + ); err != nil { + return fmt.Errorf("unable to scaffold OLM scorecard configuration, %w", err) + } + + if err := scaffold.Execute( + &manifests.Kustomization{ + SupportsKustomizeV4: false, + SupportsWebhooks: false, + }, + ); err != nil { + return fmt.Errorf("unable to scaffold manifests, %w", err) + } + } + return nil } diff --git a/internal/plugins/workload/v1/scaffolds/templates/api/group.go b/internal/plugins/workload/v1/scaffolds/templates/api/group.go index 2cab75a..db23f87 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/api/group.go +++ b/internal/plugins/workload/v1/scaffolds/templates/api/group.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/api/kind.go b/internal/plugins/workload/v1/scaffolds/templates/api/kind.go index 00c6eb5..2166959 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/api/kind.go +++ b/internal/plugins/workload/v1/scaffolds/templates/api/kind.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/api/resources/constants.go b/internal/plugins/workload/v1/scaffolds/templates/api/resources/constants.go index 200d33a..b8dd59f 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/api/resources/constants.go +++ b/internal/plugins/workload/v1/scaffolds/templates/api/resources/constants.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // SPDX-License-Identifier: MIT package resources diff --git a/internal/plugins/workload/v1/scaffolds/templates/api/resources/definition.go b/internal/plugins/workload/v1/scaffolds/templates/api/resources/definition.go index ebc47d1..0cd69bb 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/api/resources/definition.go +++ b/internal/plugins/workload/v1/scaffolds/templates/api/resources/definition.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/api/resources/mutate.go b/internal/plugins/workload/v1/scaffolds/templates/api/resources/mutate.go index 80c27fa..6285057 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/api/resources/mutate.go +++ b/internal/plugins/workload/v1/scaffolds/templates/api/resources/mutate.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // SPDX-License-Identifier: MIT package resources diff --git a/internal/plugins/workload/v1/scaffolds/templates/api/resources/resources.go b/internal/plugins/workload/v1/scaffolds/templates/api/resources/resources.go index 6471e87..fadd34b 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/api/resources/resources.go +++ b/internal/plugins/workload/v1/scaffolds/templates/api/resources/resources.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/api/types.go b/internal/plugins/workload/v1/scaffolds/templates/api/types.go index 2376178..f7f7c2a 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/api/types.go +++ b/internal/plugins/workload/v1/scaffolds/templates/api/types.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate.go b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate.go index 1a335e0..b548daa 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate_sub.go b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate_sub.go index e3db0c3..c908db8 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate_sub.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_generate_sub.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -203,7 +203,6 @@ func (f *CmdGenerateSubUpdater) GetCodeFragments() machinery.CodeFragmentsMap { } const ( - //nolint: lll cmdGenerateSub = `{{ .Boilerplate }} package {{ .Resource.Group }} diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init.go b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init.go index 6fcb002..dfecaf5 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init_sub.go b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init_sub.go index 4a93ade..ab51038 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init_sub.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_init_sub.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_root.go b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_root.go index e268e2b..3e0a613 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_root.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_root.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version.go b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version.go index e725c78..10523c8 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version_sub.go b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version_sub.go index 70a0af8..261d427 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version_sub.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/cmd_version_sub.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/cli/main.go b/internal/plugins/workload/v1/scaffolds/templates/cli/main.go index 7e28745..ecc676e 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/cli/main.go +++ b/internal/plugins/workload/v1/scaffolds/templates/cli/main.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/config/crd/kustomization.go b/internal/plugins/workload/v1/scaffolds/templates/config/crd/kustomization.go index 6c480bb..5759336 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/config/crd/kustomization.go +++ b/internal/plugins/workload/v1/scaffolds/templates/config/crd/kustomization.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/config/manifests/kustomization.go b/internal/plugins/workload/v1/scaffolds/templates/config/manifests/kustomization.go new file mode 100644 index 0000000..de0dd78 --- /dev/null +++ b/internal/plugins/workload/v1/scaffolds/templates/config/manifests/kustomization.go @@ -0,0 +1,97 @@ +// Copyright 2023 Nukleros +// SPDX-License-Identifier: MIT + +// NOTE: this was copied from operator-sdk in order to +// include support for OpenShift Lifecycle Manager. It was +// copied because operator-sdk templates are internal to the +// repo and unable to be imported directly. Including original +// license with this file. + +// Copyright 2021 The Operator-SDK Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package manifests + +import ( + "path/filepath" + + "sigs.k8s.io/kubebuilder/v3/pkg/machinery" +) + +var _ machinery.Template = &Kustomization{} + +// Kustomization scaffolds a kustomization.yaml for the manifests overlay folder. +type Kustomization struct { + machinery.TemplateMixin + machinery.ProjectNameMixin + + // SupportsKustomizeV4 is true for the projects that are + // scaffold using the kustomize/v2-aplha plugin and + // the major bump for it 4x + // Previous versions uses 3x + SupportsKustomizeV4 bool + + SupportsWebhooks bool +} + +// SetTemplateDefaults implements machinery.Template. +func (f *Kustomization) SetTemplateDefaults() error { + if f.Path == "" { + f.Path = filepath.Join("config", "manifests", "kustomization.yaml") + } + + // We cannot overwiting the file after it be created because + // it might contain user changes (i.e to work with Kustomize 4.x + // the target /spec/template/spec/containers/1/volumeMounts/0 + // needs to be replaced with /spec/template/spec/containers/0/volumeMounts/0 + f.IfExistsAction = machinery.SkipFile + + f.TemplateBody = kustomizationTemplate + + return nil +} + +const kustomizationTemplate = `# These resources constitute the fully configured set of manifests +# used to generate the 'manifests/' directory in a bundle. +resources: +- bases/{{ .ProjectName }}.clusterserviceversion.yaml +- ../default +- ../samples +- ../scorecard +{{ if .SupportsWebhooks }} +# [WEBHOOK] To enable webhooks, uncomment all the sections with [WEBHOOK] prefix. +# Do NOT uncomment sections with prefix [CERTMANAGER], as OLM does not support cert-manager. +# These patches remove the unnecessary "cert" volume and its manager container volumeMount. +#patchesJson6902: +#- target: +# group: apps +# version: v1 +# kind: Deployment +# name: controller-manager +# namespace: system +# patch: |- +# # Remove the manager container's "cert" volumeMount, since OLM will create and mount a set of certs. +# # Update the indices in this path if adding or removing containers/volumeMounts in the manager's Deployment. +# - op: remove +{{ if .SupportsKustomizeV4 }} +# path: /spec/template/spec/containers/0/volumeMounts/0 +{{ else -}} +# path: /spec/template/spec/containers/1/volumeMounts/0 +{{ end -}} +# # Remove the "cert" volume, since OLM will create and mount a set of certs. +# # Update the indices in this path if adding or removing volumes in the manager's Deployment. +# - op: remove +# path: /spec/template/spec/volumes/0 +{{ end -}} +` diff --git a/internal/plugins/workload/v1/scaffolds/templates/config/samples/crd_sample.go b/internal/plugins/workload/v1/scaffolds/templates/config/samples/crd_sample.go index 551f31a..718ea89 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/config/samples/crd_sample.go +++ b/internal/plugins/workload/v1/scaffolds/templates/config/samples/crd_sample.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/config/samples/kustomization.go b/internal/plugins/workload/v1/scaffolds/templates/config/samples/kustomization.go new file mode 100644 index 0000000..7223465 --- /dev/null +++ b/internal/plugins/workload/v1/scaffolds/templates/config/samples/kustomization.go @@ -0,0 +1,84 @@ +// Copyright 2023 Nukleros +// SPDX-License-Identifier: MIT + +// NOTE: this was copied from operator-sdk in order to +// include support for OpenShift Lifecycle Manager. It was +// copied because operator-sdk templates are internal to the +// repo and unable to be imported directly. Including original +// license with this file. + +// Copyright 2021 The Operator-SDK Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package samples + +import ( + "fmt" + "path/filepath" + + "sigs.k8s.io/kubebuilder/v3/pkg/machinery" +) + +var ( + _ machinery.Template = &Kustomization{} + _ machinery.Inserter = &Kustomization{} +) + +// Kustomization scaffolds a kustomization.yaml for the manifests overlay folder. +type Kustomization struct { + machinery.TemplateMixin + machinery.ResourceMixin +} + +// SetTemplateDefaults implements machinery.Template. +func (f *Kustomization) SetTemplateDefaults() error { + if f.Path == "" { + f.Path = filepath.Join("config", "samples", "kustomization.yaml") + } + + f.Path = f.Resource.Replacer().Replace(f.Path) + f.TemplateBody = fmt.Sprintf(kustomizationTemplate, machinery.NewMarkerFor(f.Path, samplesMarker)) + + return nil +} + +const ( + samplesMarker = "manifestskustomizesamples" +) + +// GetMarkers implements file.Inserter. +func (f *Kustomization) GetMarkers() []machinery.Marker { + return []machinery.Marker{machinery.NewMarkerFor(f.Path, samplesMarker)} +} + +const samplesCodeFragment = `- %s +` + +// makeCRFileName returns a Custom Resource example file name in the same format +// as kubebuilder's CreateAPI plugin for a gvk. +func (f *Kustomization) makeCRFileName() string { + return f.Resource.Replacer().Replace("%[group]_%[version]_%[kind].yaml") +} + +// GetCodeFragments implements file.Inserter. +func (f *Kustomization) GetCodeFragments() machinery.CodeFragmentsMap { + return machinery.CodeFragmentsMap{ + machinery.NewMarkerFor(f.Path, samplesMarker): []string{fmt.Sprintf(samplesCodeFragment, f.makeCRFileName())}, + } +} + +const kustomizationTemplate = `## Append samples you want in your CSV to this file as resources ## +resources: +%s +` diff --git a/internal/plugins/workload/v1/scaffolds/templates/config/scorecard/scorecard.go b/internal/plugins/workload/v1/scaffolds/templates/config/scorecard/scorecard.go new file mode 100644 index 0000000..d72c5cd --- /dev/null +++ b/internal/plugins/workload/v1/scaffolds/templates/config/scorecard/scorecard.go @@ -0,0 +1,195 @@ +// Copyright 2023 Nukleros +// SPDX-License-Identifier: MIT + +// NOTE: this was copied from operator-sdk in order to +// include support for OpenShift Lifecycle Manager. It was +// copied because operator-sdk templates are internal to the +// repo and unable to be imported directly. Including original +// license with this file. + +// Copyright 2021 The Operator-SDK Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package scorecard + +import ( + "errors" + "fmt" + "path/filepath" + + "sigs.k8s.io/kubebuilder/v3/pkg/machinery" +) + +var _ machinery.Template = &Scorecard{} + +var ( + ErrUnknwonScorecardType = errors.New("unknown scorecard type") +) + +//nolint:golint +type ScorecardType int + +const ( + kustomizeFileSubPath = "kustomization.yaml" + operatorSdkImageVersion = "v1.28.0" + + ScorecardTypeUnknown ScorecardType = iota + ScorecardTypeBase + ScorecardTypeKustomize + ScorecardTypePatchesOLM + ScorecardTypePatchesBasic +) + +// Scorecard scaffolds a file which represents an Operator Lifecycle Manager scorecard. +// It is only used when --enable-olm is set to true. +type Scorecard struct { + machinery.TemplateMixin + + // input variables + ScorecardTestImage string + ScorecardType ScorecardType +} + +func (f *Scorecard) SetTemplateDefaults() error { + if f.ScorecardType == ScorecardTypeUnknown { + return ErrUnknwonScorecardType + } + + f.Path = filepath.Join(append([]string{"config", "scorecard"}, getScorecardSubPath(f.ScorecardType)...)...) + f.TemplateBody = getScorecardTemplate(f.ScorecardType) + + f.ScorecardTestImage = fmt.Sprintf("quay.io/operator-framework/scorecard-test:%s", operatorSdkImageVersion) + f.IfExistsAction = machinery.OverwriteFile + + return nil +} + +const ( + // kustomizationFile is a kustomization.yaml file for the scorecard componentconfig. + // This should always be written to config/scorecard/kustomization.yaml. + kustomizeFile = `resources: + - bases/config.yaml +patchesJson6902: + - path: patches/basic.config.yaml + target: + group: scorecard.operatorframework.io + version: v1alpha3 + kind: Configuration + name: config + - path: patches/olm.config.yaml + target: + group: scorecard.operatorframework.io + version: v1alpha3 + kind: Configuration + name: config +%[1]s +` + + // YAML file marker to append to kustomization.yaml files. + patchesJSON6902Marker = "patchesJson6902" + + // Config is an empty scorecard componentconfig with parallel stages. + config = `apiVersion: scorecard.operatorframework.io/v1alpha3 +kind: Configuration +metadata: + name: config +stages: + - parallel: true + tests: [] +` + + // PatchBasic contains all default "basic" test configurations. + patchBasic = `- op: add + path: /stages/0/tests/- + value: + entrypoint: + - scorecard-test + - basic-check-spec + image: {{ .ScorecardTestImage }} + labels: + suite: basic + test: basic-check-spec-test +` + + // PatchOLM contains all default "olm" test configurations. + patchOLM = `- op: add + path: /stages/0/tests/- + value: + entrypoint: + - scorecard-test + - olm-bundle-validation + image: {{ .ScorecardTestImage }} + labels: + suite: olm + test: olm-bundle-validation-test +- op: add + path: /stages/0/tests/- + value: + entrypoint: + - scorecard-test + - olm-crds-have-validation + image: {{ .ScorecardTestImage }} + labels: + suite: olm + test: olm-crds-have-validation-test +- op: add + path: /stages/0/tests/- + value: + entrypoint: + - scorecard-test + - olm-crds-have-resources + image: {{ .ScorecardTestImage }} + labels: + suite: olm + test: olm-crds-have-resources-test +- op: add + path: /stages/0/tests/- + value: + entrypoint: + - scorecard-test + - olm-spec-descriptors + image: {{ .ScorecardTestImage }} + labels: + suite: olm + test: olm-spec-descriptors-test +- op: add + path: /stages/0/tests/- + value: + entrypoint: + - scorecard-test + - olm-status-descriptors + image: {{ .ScorecardTestImage }} + labels: + suite: olm + test: olm-status-descriptors-test +` +) + +func getScorecardSubPath(scorecardType ScorecardType) []string { + return map[ScorecardType][]string{ + ScorecardTypeBase: {"bases", "config.yaml"}, + ScorecardTypeKustomize: {kustomizeFileSubPath}, + ScorecardTypePatchesBasic: {"patches", "basic.config.yaml"}, + ScorecardTypePatchesOLM: {"patches", "olm.config.yaml"}, + }[scorecardType] +} + +func getScorecardTemplate(scorecardType ScorecardType) string { + return map[ScorecardType]string{ + ScorecardTypeBase: config, + ScorecardTypeKustomize: fmt.Sprintf(kustomizeFile, machinery.NewMarkerFor(kustomizeFileSubPath, patchesJSON6902Marker)), + ScorecardTypePatchesBasic: patchBasic, + ScorecardTypePatchesOLM: patchOLM, + }[scorecardType] +} diff --git a/internal/plugins/workload/v1/scaffolds/templates/controller/controller.go b/internal/plugins/workload/v1/scaffolds/templates/controller/controller.go index a224ed9..98cf663 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/controller/controller.go +++ b/internal/plugins/workload/v1/scaffolds/templates/controller/controller.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -114,7 +114,7 @@ func (f *Controller) getAPITypesPath(builder kinds.WorkloadBuilder) string { ) } -//nolint: lll +//nolint:lll const controllerTemplate = `{{ .Boilerplate }} package {{ .Resource.Group }} @@ -161,12 +161,6 @@ func New{{ .Resource.Kind }}Reconciler(mgr ctrl.Manager) *{{ .Resource.Kind }}Re {{ .ToMarker }} {{ end }} -// Until Webhooks are implemented we need to list and watch namespaces to ensure -// they are available before deploying resources, -// See: -// - https://github.com/vmware-tanzu-labs/operator-builder/issues/141 -// - https://github.com/vmware-tanzu-labs/operator-builder/issues/162 - // +kubebuilder:rbac:groups=core,resources=namespaces,verbs=list;watch // Reconcile is part of the main kubernetes reconciliation loop which aims to diff --git a/internal/plugins/workload/v1/scaffolds/templates/controller/controller_suitetest.go b/internal/plugins/workload/v1/scaffolds/templates/controller/controller_suitetest.go index 1db6bc5..0a7d5aa 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/controller/controller_suitetest.go +++ b/internal/plugins/workload/v1/scaffolds/templates/controller/controller_suitetest.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -15,7 +15,8 @@ var _ machinery.Template = &SuiteTest{} var _ machinery.Inserter = &SuiteTest{} // SuiteTest scaffolds the file that sets up the controller tests -// nolint:maligned +// +//nolint:maligned type SuiteTest struct { machinery.TemplateMixin machinery.MultiGroupMixin diff --git a/internal/plugins/workload/v1/scaffolds/templates/controller/phases.go b/internal/plugins/workload/v1/scaffolds/templates/controller/phases.go index cf5107a..65cb994 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/controller/phases.go +++ b/internal/plugins/workload/v1/scaffolds/templates/controller/phases.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/dockerfile.go b/internal/plugins/workload/v1/scaffolds/templates/dockerfile.go index 7e3c3bb..c7da303 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/dockerfile.go +++ b/internal/plugins/workload/v1/scaffolds/templates/dockerfile.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/gomod.go b/internal/plugins/workload/v1/scaffolds/templates/gomod.go index 4494455..5f34d81 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/gomod.go +++ b/internal/plugins/workload/v1/scaffolds/templates/gomod.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/int/dependencies/component.go b/internal/plugins/workload/v1/scaffolds/templates/int/dependencies/component.go index ec302ca..5bedfb2 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/int/dependencies/component.go +++ b/internal/plugins/workload/v1/scaffolds/templates/int/dependencies/component.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/int/mutate/component.go b/internal/plugins/workload/v1/scaffolds/templates/int/mutate/component.go index 576185b..4c0d0e9 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/int/mutate/component.go +++ b/internal/plugins/workload/v1/scaffolds/templates/int/mutate/component.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/main.go b/internal/plugins/workload/v1/scaffolds/templates/main.go index ac7943b..17e874f 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/main.go +++ b/internal/plugins/workload/v1/scaffolds/templates/main.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/makefile.go b/internal/plugins/workload/v1/scaffolds/templates/makefile.go index d7f47e7..1301a2d 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/makefile.go +++ b/internal/plugins/workload/v1/scaffolds/templates/makefile.go @@ -1,10 +1,12 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT package templates import ( + "fmt" + "sigs.k8s.io/kubebuilder/v3/pkg/machinery" ) @@ -16,10 +18,18 @@ const crdOptions = "crd:crdVersions=v1" type Makefile struct { machinery.TemplateMixin machinery.RepositoryMixin + machinery.ProjectNameMixin + machinery.DomainMixin RootCmdName string CrdOptions string ControllerImg string + EnableOLM bool + + ControllerToolsVersion string + KustomizeVersion string + ControllerRuntimeVersion string + OperatorSDKVersion string } func (f *Makefile) SetTemplateDefaults() error { @@ -28,19 +38,27 @@ func (f *Makefile) SetTemplateDefaults() error { } f.CrdOptions = crdOptions - f.TemplateBody = makefileTemplate + f.TemplateBody = fmt.Sprintf(makefileTemplate, f.Domain, f.ProjectName, makeHelp) f.IfExistsAction = machinery.OverwriteFile return nil } -//nolint: lll +// NOTE: this is to account for characters which represent string substitutions in go such as %s. +// +//nolint:lll +const makeHelp = `help: ## Display this help. + @awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m\033[0m\n"} /^[a-zA-Z_0-9-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST)` + +//nolint:lll const makefileTemplate = ` # Image URL to use all building/pushing image targets IMG ?= "{{ .ControllerImg }}" # Produce CRDs that work back to Kubernetes 1.11 (no version conversion) -CRD_OPTIONS ?= "{{ .CrdOptions }}" +CRD_OPTIONS ?= "crd:crdVersions=v1" +# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary. +ENVTEST_K8S_VERSION = 1.26.1 # Get the currently used golang install path (in GOPATH/bin, unless GOBIN is set) ifeq (,$(shell go env GOBIN)) @@ -50,11 +68,11 @@ GOBIN=$(shell go env GOBIN) endif # Setting SHELL to bash allows bash commands to be executed by recipes. -# This is a requirement for 'setup-envtest.sh' in the test target. # Options are set to exit when a recipe line exits non-zero or a piped command fails. SHELL = /usr/bin/env bash -o pipefail .SHELLFLAGS = -ec +.PHONY: all all: build ##@ General @@ -70,93 +88,274 @@ all: build # More info on the awk command: # http://linuxcommand.org/lc3_adv_awk.php -help: ## Display this help. - @awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m\033[0m\n"} /^[a-zA-Z_0-9-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST) +%[3]s ##@ Development +.PHONY: manifests manifests: controller-gen ## Generate WebhookConfiguration, ClusterRole and CustomResourceDefinition objects. $(CONTROLLER_GEN) $(CRD_OPTIONS) rbac:roleName=manager-role webhook paths="./..." output:crd:artifacts:config=config/crd/bases +.PHONY: generate generate: controller-gen ## Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations. $(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./..." +.PHONY: fmt fmt: ## Run go fmt against code. go fmt ./... +.PHONY: vet vet: ## Run go vet against code. go vet ./... -ENVTEST_ASSETS_DIR=$(shell pwd)/testbin -test: manifests generate fmt vet ## Run tests. - mkdir -p ${ENVTEST_ASSETS_DIR} - test -f ${ENVTEST_ASSETS_DIR}/setup-envtest.sh || curl -sSLo ${ENVTEST_ASSETS_DIR}/setup-envtest.sh https://raw.githubusercontent.com/kubernetes-sigs/controller-runtime/v0.7.2/hack/setup-envtest.sh - source ${ENVTEST_ASSETS_DIR}/setup-envtest.sh; fetch_envtest_tools $(ENVTEST_ASSETS_DIR); setup_envtest_env $(ENVTEST_ASSETS_DIR); go test ./... -coverprofile cover.out +.PHONY: test +test: manifests generate fmt vet envtest ## Run tests. + KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) --bin-dir $(LOCALBIN) -p path)" go test ./... -coverprofile cover.out -test-e2e: +.PHONY: test-e2e +test-e2e: ## Run E2E tests against a running Kubernetes cluster. go test {{ .Repo }}/test/e2e -tags=e2e_test -count=1 ##@ Build -build: generate fmt vet ## Build manager binary. +.PHONY: build +build: manifests generate fmt vet ## Build manager binary. go build -o bin/manager main.go +.PHONY: run run: manifests generate fmt vet ## Run a controller from your host. go run ./main.go +# If you wish built the manager image targeting other platforms you can use the --platform flag. +# (i.e. docker build --platform linux/arm64 ). However, you must enable docker buildKit for it. +# More info: https://docs.docker.com/develop/develop-images/build_enhancements/ +.PHONY: docker-build docker-build: test ## Build docker image with the manager. - docker build -t ${IMG} . + docker build -t $(IMG) . +.PHONY: docker-push docker-push: ## Push docker image with the manager. - docker push ${IMG} + docker push $(IMG) + +# PLATFORMS defines the target platforms for the manager image be build to provide support to multiple +# architectures. (i.e. make docker-buildx IMG=myregistry/mypoperator:0.0.1). To use this option you need to: +# - able to use docker buildx . More info: https://docs.docker.com/build/buildx/ +# - have enable BuildKit, More info: https://docs.docker.com/develop/develop-images/build_enhancements/ +# - be able to push the image for your registry (i.e. if you do not inform a valid value via IMG=> then the export will fail) +# To properly provided solutions that supports more than one platform you should use this option. +PLATFORMS ?= linux/arm64,linux/amd64,linux/s390x,linux/ppc64le +.PHONY: docker-buildx +docker-buildx: test ## Build and push docker image for the manager for cross-platform support + # copy existing Dockerfile and insert --platform=${BUILDPLATFORM} into Dockerfile.cross, and preserve the original Dockerfile + sed -e '1 s/\(^FROM\)/FROM --platform=\$$\{BUILDPLATFORM\}/; t' -e ' 1,// s//FROM --platform=\$$\{BUILDPLATFORM\}/' Dockerfile > Dockerfile.cross + - docker buildx create --name project-v3-builder + docker buildx use project-v3-builder + - docker buildx build --push --platform=$(PLATFORMS) --tag ${IMG} -f Dockerfile.cross . + - docker buildx rm project-v3-builder + rm Dockerfile.cross ##@ Deployment +ifndef ignore-not-found + ignore-not-found = false +endif + +.PHONY: install install: manifests kustomize ## Install CRDs into the K8s cluster specified in ~/.kube/config. $(KUSTOMIZE) build config/crd | kubectl apply -f - -uninstall: manifests kustomize ## Uninstall CRDs from the K8s cluster specified in ~/.kube/config. - $(KUSTOMIZE) build config/crd | kubectl delete -f - +.PHONY: uninstall +uninstall: manifests kustomize ## Uninstall CRDs from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion. + $(KUSTOMIZE) build config/crd | kubectl delete --ignore-not-found=$(ignore-not-found) -f - +.PHONY: deploy deploy: manifests kustomize ## Deploy controller to the K8s cluster specified in ~/.kube/config. cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG} $(KUSTOMIZE) build config/default | kubectl apply -f - -undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/config. - $(KUSTOMIZE) build config/default | kubectl delete -f - - - -CONTROLLER_GEN = $(shell pwd)/bin/controller-gen -controller-gen: ## Download controller-gen locally if necessary. - $(call go-get-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/controller-gen@v0.9.0) - -KUSTOMIZE = $(shell pwd)/bin/kustomize -kustomize: ## Download kustomize locally if necessary. - $(call go-get-tool,$(KUSTOMIZE),sigs.k8s.io/kustomize/kustomize/v4@v4.5.5) - -# go-get-tool will 'go get' any package $2 and install it to $1. -PROJECT_DIR := $(shell dirname $(abspath $(lastword $(MAKEFILE_LIST)))) -define go-get-tool -@[ -f $(1) ] || { \ -set -e ;\ -TMP_DIR=$$(mktemp -d) ;\ -cd $$TMP_DIR ;\ -go mod init tmp ;\ -echo "Downloading $(2)" ;\ -GOBIN=$(PROJECT_DIR)/bin go install $(2) ;\ -rm -rf $$TMP_DIR ;\ -} -endef +.PHONY: undeploy +undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion. + $(KUSTOMIZE) build config/default | kubectl delete --ignore-not-found=$(ignore-not-found) -f - + +##@ Build Dependencies + +## Location to install dependencies to +LOCALBIN ?= $(shell pwd)/bin +$(LOCALBIN): + mkdir -p $(LOCALBIN) + +## Tool Binaries +KUSTOMIZE ?= $(LOCALBIN)/kustomize +CONTROLLER_GEN ?= $(LOCALBIN)/controller-gen +ENVTEST ?= $(LOCALBIN)/setup-envtest + +## Tool Versions +KUSTOMIZE_VERSION ?= {{ .KustomizeVersion }} +CONTROLLER_TOOLS_VERSION ?= {{ .ControllerToolsVersion }} + +KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh" +.PHONY: kustomize +kustomize: $(KUSTOMIZE) ## Download kustomize locally if necessary. If wrong version is installed, it will be removed before downloading. +$(KUSTOMIZE): $(LOCALBIN) + @if test -x $(LOCALBIN)/kustomize && ! $(LOCALBIN)/kustomize version | grep -q $(KUSTOMIZE_VERSION); then \ + echo "$(LOCALBIN)/kustomize version is not expected $(KUSTOMIZE_VERSION). Removing it before installing."; \ + rm -rf $(LOCALBIN)/kustomize; \ + fi + test -s $(LOCALBIN)/kustomize || { curl -Ss $(KUSTOMIZE_INSTALL_SCRIPT) --output install_kustomize.sh && bash install_kustomize.sh $(subst v,,$(KUSTOMIZE_VERSION)) $(LOCALBIN); rm install_kustomize.sh; } + +.PHONY: controller-gen +controller-gen: $(CONTROLLER_GEN) ## Download controller-gen locally if necessary. If wrong version is installed, it will be overwritten. +$(CONTROLLER_GEN): $(LOCALBIN) + test -s $(LOCALBIN)/controller-gen && $(LOCALBIN)/controller-gen --version | grep -q $(CONTROLLER_TOOLS_VERSION) || \ + GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-tools/cmd/controller-gen@$(CONTROLLER_TOOLS_VERSION) + +.PHONY: envtest +envtest: $(ENVTEST) ## Download envtest-setup locally if necessary. +$(ENVTEST): $(LOCALBIN) + test -s $(LOCALBIN)/setup-envtest || GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-runtime/tools/setup-envtest@latest + +{{ if .EnableOLM -}} +##@ Operator Lifecycle Manager + +# opm +.PHONY: opm +OPM = ./bin/opm +opm: ## Download opm locally if necessary. +ifeq (,$(wildcard $(OPM))) +ifeq (,$(shell which opm 2>/dev/null)) + @{ \ + set -e ;\ + mkdir -p $(dir $(OPM)) ;\ + OS=$(shell go env GOOS) && ARCH=$(shell go env GOARCH) && \ + curl -sSLo $(OPM) https://github.com/operator-framework/operator-registry/releases/download/%[1]s/$${OS}-$${ARCH}-opm ;\ + chmod +x $(OPM) ;\ + } +else +OPM = $(shell which opm) +endif +endif + +# operator-sdk +.PHONY: operator-sdk +OPERATOR_SDK = ./bin/operator-sdk +operator-sdk: ## Download operator-sdk locally if necessary. +ifeq (,$(wildcard $(OPERATOR_SDK))) +ifeq (,$(shell which opm 2>/dev/null)) + @{ \ + set -e ;\ + mkdir -p $(dir $(OPERATOR_SDK)) ;\ + OS=$(shell go env GOOS) && ARCH=$(shell go env GOARCH) && \ + curl -sSLo $(OPERATOR_SDK) https://github.com/operator-framework/operator-sdk/releases/download/{{ .OperatorSDKVersion }}/operator-sdk_$${OS}_$${ARCH} ;\ + chmod +x $(OPERATOR_SDK) ;\ + } +else +OPM = $(shell which opm) +endif +endif + +# bundle + +# VERSION defines the project version for the bundle. +# Update this value when you upgrade the version of your project. +# To re-generate a bundle for another specific version without changing the standard setup, you can: +# - use the VERSION as arg of the bundle target (e.g make bundle VERSION=0.0.2) +# - use environment variables to overwrite this value (e.g export VERSION=0.0.2) +VERSION ?= 0.0.1 + +# CHANNELS define the bundle channels used in the bundle. +# Add a new line here if you would like to change its default config. (E.g CHANNELS = "candidate,fast,stable") +# To re-generate a bundle for other specific channels without changing the standard setup, you can: +# - use the CHANNELS as arg of the bundle target (e.g make bundle CHANNELS=candidate,fast,stable) +# - use environment variables to overwrite this value (e.g export CHANNELS="candidate,fast,stable") +ifneq ($(origin CHANNELS), undefined) +BUNDLE_CHANNELS := --channels=$(CHANNELS) +endif + +# DEFAULT_CHANNEL defines the default channel used in the bundle. +# Add a new line here if you would like to change its default config. (E.g DEFAULT_CHANNEL = "stable") +# To re-generate a bundle for any other default channel without changing the default setup, you can: +# - use the DEFAULT_CHANNEL as arg of the bundle target (e.g make bundle DEFAULT_CHANNEL=stable) +# - use environment variables to overwrite this value (e.g export DEFAULT_CHANNEL="stable") +ifneq ($(origin DEFAULT_CHANNEL), undefined) +BUNDLE_DEFAULT_CHANNEL := --default-channel=$(DEFAULT_CHANNEL) +endif +BUNDLE_METADATA_OPTS ?= $(BUNDLE_CHANNELS) $(BUNDLE_DEFAULT_CHANNEL) + +# IMAGE_TAG_BASE defines the docker.io namespace and part of the image name for remote images. +# This variable is used to construct full image tags for bundle and catalog images. +# +# For example, running 'make bundle-build bundle-push catalog-build catalog-push' will build and push both +# %[1]s/%[2]s-bundle:$VERSION and %[1]s/%[2]s-catalog:$VERSION. +IMAGE_TAG_BASE ?= %[1]s/%[2]s + +# BUNDLE_IMG defines the image:tag used for the bundle. +# You can use it as an arg. (E.g make bundle-build BUNDLE_IMG=/:) +BUNDLE_IMG ?= $(IMAGE_TAG_BASE)-bundle:v$(VERSION) + +# BUNDLE_GEN_FLAGS are the flags passed to the operator-sdk generate bundle command +BUNDLE_GEN_FLAGS ?= -q --overwrite --version $(VERSION) $(BUNDLE_METADATA_OPTS) + +# USE_IMAGE_DIGESTS defines if images are resolved via tags or digests +# You can enable this value if you would like to use SHA Based Digests +# To enable set flag to true +USE_IMAGE_DIGESTS ?= false +ifeq ($(USE_IMAGE_DIGESTS), true) + BUNDLE_GEN_FLAGS += --use-image-digests +endif + +.PHONY: bundle +bundle: manifests kustomize ## Generate bundle manifests and metadata, then validate generated files. + operator-sdk generate kustomize manifests -q + cd config/manager && $(KUSTOMIZE) edit set image controller=$(IMG) + $(KUSTOMIZE) build config/manifests | operator-sdk generate bundle $(BUNDLE_GEN_FLAGS) + operator-sdk bundle validate ./bundle + +.PHONY: bundle-build +bundle-build: ## Build the bundle image. + docker build -f bundle.Dockerfile -t $(BUNDLE_IMG) . + +.PHONY: bundle-push +bundle-push: ## Push the bundle image. + $(MAKE) docker-push IMG=$(BUNDLE_IMG) + + +# catalog + +# A comma-separated list of bundle images (e.g. make catalog-build BUNDLE_IMGS=example.com/operator-bundle:v0.1.0,example.com/operator-bundle:v0.2.0). +# These images MUST exist in a registry and be pull-able. +BUNDLE_IMGS ?= $(BUNDLE_IMG) + +# The image tag given to the resulting catalog image (e.g. make catalog-build CATALOG_IMG=example.com/operator-catalog:v0.2.0). +CATALOG_IMG ?= $(IMAGE_TAG_BASE)-catalog:v$(VERSION) + +# Set CATALOG_BASE_IMG to an existing catalog image tag to add $BUNDLE_IMGS to that image. +ifneq ($(origin CATALOG_BASE_IMG), undefined) +FROM_INDEX_OPT := --from-index $(CATALOG_BASE_IMG) +endif + +# Build a catalog image by adding bundle images to an empty catalog using the operator package manager tool, 'opm'. +# This recipe invokes 'opm' in 'semver' bundle add mode. For more information on add modes, see: +# https://github.com/operator-framework/community-operators/blob/7f1438c/docs/packaging-operator.md#updating-your-existing-operator +.PHONY: catalog-build +catalog-build: opm ## Build a catalog image. + $(OPM) index add --container-tool docker --mode semver --tag $(CATALOG_IMG) --bundles $(BUNDLE_IMGS) $(FROM_INDEX_OPT) + +# Push the catalog image. +.PHONY: catalog-push +catalog-push: ## Push a catalog image. + $(MAKE) docker-push IMG=$(CATALOG_IMG) +{{ end }} + +##@ Miscellaneous {{ if ne .RootCmdName "" -}} -# Build the companion CLI -build-cli: +.PHONY: build-cli +build-cli: ## Build the companion CLI. go build -o bin/{{ .RootCmdName }} cmd/{{ .RootCmdName }}/main.go {{- end }} -# Build the API Documentation # NOTE: requires go version 1.16 or later -docs: manifests +docs: manifests ## Build the API documentation. @if ! command -v go &> /dev/null; then echo "error: go not installed"; exit 1; fi; \ GOCMD=$$(which go); \ if [[ -z $$($$GOCMD version | grep '1.16') ]]; then echo "error: requires go version >= 1.16"; exit 1; fi; \ diff --git a/internal/plugins/workload/v1/scaffolds/templates/readme.go b/internal/plugins/workload/v1/scaffolds/templates/readme.go index 860cb5d..8e95654 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/readme.go +++ b/internal/plugins/workload/v1/scaffolds/templates/readme.go @@ -1,20 +1,33 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT package templates import ( + "errors" + "fmt" + "strings" + "sigs.k8s.io/kubebuilder/v3/pkg/machinery" ) +const ( + missingVersionTag = "latest" +) + var _ machinery.Template = &Readme{} +var ErrInvalidImage = errors.New("invalid image") + // Readme scaffolds a file that defines the templated README.md instructions for a custom workload. type Readme struct { machinery.TemplateMixin - RootCmdName string + RootCmdName string + EnableOLM bool + ControllerImg string + ControllerBundleImg string } // SetTemplateDefaults implements file.Template. @@ -23,6 +36,18 @@ func (f *Readme) SetTemplateDefaults() error { f.Path = "README.md" } + controllerImgParts := strings.Split(f.ControllerImg, ":") + switch len(controllerImgParts) { + case 1: + f.ControllerImg = fmt.Sprintf("%s:%s", controllerImgParts[0], missingVersionTag) + f.ControllerBundleImg = fmt.Sprintf("%s-bundle:%s", controllerImgParts[0], missingVersionTag) + case 2: + f.ControllerImg = fmt.Sprintf("%s:%s", controllerImgParts[0], controllerImgParts[1]) + f.ControllerBundleImg = fmt.Sprintf("%s-bundle:%s", controllerImgParts[0], controllerImgParts[1]) + default: + return fmt.Errorf("%s; %w", f.ControllerImg, ErrInvalidImage) + } + f.IfExistsAction = machinery.OverwriteFile f.TemplateBody = readmefileTemplate @@ -55,7 +80,7 @@ To clean up: First, set the image: - export IMG=myrepo/myproject:v0.1.0 + export IMG={{ .ControllerImg }} Now you can build and push the image: @@ -81,5 +106,35 @@ The CLI binary will get saved to the bin directory. You can see the help message with: ./bin/{{ .RootCmdName }} help +{{- end }} + +{{ if .EnableOLM -}} +## Deploy the Operator Lifecycle Manager Bundle + +First, build the bundle. The bundle contains metadata that makes it +compatible with Operator Lifecycle Manager and also makes the operator +importable into OpenShift OperatorHub: + + make bundle + +Next, set the bundle image. This is the image that contains the packaged +bundle: + + export BUNDLE_IMG={{ .ControllerBundleImg }} + +Now you can build and push the bundle image: + + make bundle-build + make bundle-push + +To deploy the bundle (requires OLM to be running in the cluster): + + make operator-sdk + bin/operator-sdk bundle validate $BUNDLE_IMG + bin/operator-sdk run bundle $BUNDLE_IMG + +To clean up: + + bin/operator-sdk cleanup --delete-all $BUNDLE_IMG {{ end -}} ` diff --git a/internal/plugins/workload/v1/scaffolds/templates/test/e2e/e2e.go b/internal/plugins/workload/v1/scaffolds/templates/test/e2e/e2e.go index f1ef60a..6eefd10 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/test/e2e/e2e.go +++ b/internal/plugins/workload/v1/scaffolds/templates/test/e2e/e2e.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/plugins/workload/v1/scaffolds/templates/test/e2e/workloads.go b/internal/plugins/workload/v1/scaffolds/templates/test/e2e/workloads.go index 26951a7..f3aebd4 100644 --- a/internal/plugins/workload/v1/scaffolds/templates/test/e2e/workloads.go +++ b/internal/plugins/workload/v1/scaffolds/templates/test/e2e/workloads.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -68,7 +68,7 @@ func (f *WorkloadTest) SetTemplateDefaults() error { return nil } -//nolint: lll +//nolint:lll const e2eWorkloadsTemplate = `// +build e2e_test {{ .Boilerplate }} @@ -142,11 +142,11 @@ func (tester *E2ETest) {{ .TesterName }}Test(testSuite *E2EComponentTestSuite) { // test the update of a child object // TODO: need immutable fields so that we can predict which managed fields we can modify to test reconciliation - // see https://github.com/vmware-tanzu-labs/operator-builder/issues/67 + // see https://github.com/nukleros/operator-builder/issues/24 // test the update of a parent object // TODO: need immutable fields so that we can predict which managed fields we can modify to test reconciliation - // see https://github.com/vmware-tanzu-labs/operator-builder/issues/67 + // see https://github.com/nukleros/operator-builder/issues/24 // test that controller logs do not contain errors if os.Getenv("DEPLOY_IN_CLUSTER") == "true" { diff --git a/internal/utils/conversion.go b/internal/utils/conversion.go index 3b67c99..002f898 100644 --- a/internal/utils/conversion.go +++ b/internal/utils/conversion.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -36,7 +36,7 @@ func ToArrayString(in interface{}) ([]string, error) { // attempt conversion for each item outInterfaces, err := ToArrayInterface(in) if err != nil { - return nil, fmt.Errorf("%w; %s", err, ErrConvertArrayString) + return nil, fmt.Errorf("%w; %s", err, ErrConvertArrayString.Error()) } outStrings := make([]string, len(outInterfaces)) @@ -44,7 +44,7 @@ func ToArrayString(in interface{}) ([]string, error) { for i := range outInterfaces { outString, err := ToString(outInterfaces[i]) if err != nil { - return nil, fmt.Errorf("%w; %s", err, ErrConvertArrayString) + return nil, fmt.Errorf("%w; %s", err, ErrConvertArrayString.Error()) } outStrings[i] = outString diff --git a/internal/utils/files.go b/internal/utils/files.go index 1abeebe..b0c3b7d 100644 --- a/internal/utils/files.go +++ b/internal/utils/files.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/utils/functionmap.go b/internal/utils/functionmap.go index e2469fd..451c5cf 100644 --- a/internal/utils/functionmap.go +++ b/internal/utils/functionmap.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/utils/names.go b/internal/utils/names.go index 1f6e63c..32d412f 100644 --- a/internal/utils/names.go +++ b/internal/utils/names.go @@ -1,12 +1,10 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT package utils -import ( - "strings" -) +import "strings" // ToPascalCase will convert a kebab-case string to a PascalCase name appropriate to // use as a go variable name. @@ -98,9 +96,10 @@ func ToSnakeCase(name string) string { // ToTitle replaces the strings.Title method, which is deprecated in go1.18. This is a helper // method to make titling a string much more readable than the new methodology. -//nolint:godox // TODO: use commented code below eventually. It returns different at this time but will // eventually be deprecated. +// +//nolint:godox func ToTitle(in string) string { //nolint:gocritic // return cases.Title(language.Und, cases.NoLower, cases.NoLower).String(in) diff --git a/internal/utils/utils.go b/internal/utils/utils.go index b45e6ee..acbd013 100644 --- a/internal/utils/utils.go +++ b/internal/utils/utils.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/utils/version.go b/internal/utils/version.go index 7fe6fba..661260b 100644 --- a/internal/utils/version.go +++ b/internal/utils/version.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/commands/companion/cli.go b/internal/workload/v1/commands/companion/cli.go index 6a065a8..0c0cd3b 100644 --- a/internal/workload/v1/commands/companion/cli.go +++ b/internal/workload/v1/commands/companion/cli.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/commands/companion/cli_internal_test.go b/internal/workload/v1/commands/companion/cli_internal_test.go index 38e1323..d36ff87 100644 --- a/internal/workload/v1/commands/companion/cli_internal_test.go +++ b/internal/workload/v1/commands/companion/cli_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/commands/subcommand/create_api.go b/internal/workload/v1/commands/subcommand/create_api.go index ee46cc4..8042764 100644 --- a/internal/workload/v1/commands/subcommand/create_api.go +++ b/internal/workload/v1/commands/subcommand/create_api.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -33,18 +33,18 @@ func CreateAPI(processor *config.Processor) error { // run through pre-processing to gather the collection and the components apiProcessor := &createAPIProcessor{configProcessors: processor.GetProcessors()} if err := apiProcessor.preProcess(); err != nil { - return fmt.Errorf("%w; %s", err, ErrCreateAPIPreProcess) + return fmt.Errorf("%w; %s", err, ErrCreateAPIPreProcess.Error()) } if len(apiProcessor.components) > 0 { if err := processor.Workload.SetComponents(apiProcessor.components); err != nil { - return fmt.Errorf("%w; %s", err, ErrCreateAPISetComponents) + return fmt.Errorf("%w; %s", err, ErrCreateAPISetComponents.Error()) } } // run through processing if err := apiProcessor.process(); err != nil { - return fmt.Errorf("%w; %s", err, ErrCreateAPIProcess) + return fmt.Errorf("%w; %s", err, ErrCreateAPIProcess.Error()) } return nil diff --git a/internal/workload/v1/commands/subcommand/init.go b/internal/workload/v1/commands/subcommand/init.go index 58ad105..13c5492 100644 --- a/internal/workload/v1/commands/subcommand/init.go +++ b/internal/workload/v1/commands/subcommand/init.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/commands/subcommand/init_config.go b/internal/workload/v1/commands/subcommand/init_config.go index 47d69e4..dcc84ae 100644 --- a/internal/workload/v1/commands/subcommand/init_config.go +++ b/internal/workload/v1/commands/subcommand/init_config.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -68,7 +68,7 @@ func outputFile(options *InitConfigOptions, data []byte) error { outputStream := os.Stdout if _, err := outputStream.WriteString(string(data)); err != nil { - return fmt.Errorf("%w; %s", err, ErrWriteStdout) + return fmt.Errorf("%w; %s", err, ErrWriteStdout.Error()) } return nil @@ -82,7 +82,7 @@ func outputFile(options *InitConfigOptions, data []byte) error { } if err := os.WriteFile(options.Path, data, permissions); err != nil { - return fmt.Errorf("%w; %s at location %s", err, ErrWriteFile, options.Path) + return fmt.Errorf("%w; %s at location %s", err, ErrWriteFile.Error(), options.Path) } return nil diff --git a/internal/workload/v1/config/config.go b/internal/workload/v1/config/config.go index 75c4006..3345e07 100644 --- a/internal/workload/v1/config/config.go +++ b/internal/workload/v1/config/config.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -12,4 +12,5 @@ type Plugin struct { WorkloadConfigPath string `json:"workloadConfigPath" yaml:"workloadConfigPath"` CliRootCommandName string `json:"cliRootCommandName" yaml:"cliRootCommandName"` ControllerImg string `json:"controllerImg" yaml:"controllerImg"` + EnableOLM bool `json:"enableOlm" yaml:"enableOlm"` } diff --git a/internal/workload/v1/config/parse.go b/internal/workload/v1/config/parse.go index 0c72d91..95b6950 100644 --- a/internal/workload/v1/config/parse.go +++ b/internal/workload/v1/config/parse.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -33,7 +33,7 @@ var ( func Parse(configPath string) (*Processor, error) { processor, err := NewProcessor(configPath) if err != nil { - return nil, fmt.Errorf("%s - error creating new processor - %w", ErrParseConfig, err) + return nil, fmt.Errorf("%s - error creating new processor - %w", ErrParseConfig.Error(), err) } // create the validator we need to track workloads as they are parsed and fail fast @@ -44,7 +44,7 @@ func Parse(configPath string) (*Processor, error) { // parse the workload configuration from the newly created object if err := processor.parse(validator); err != nil { - return nil, fmt.Errorf("%s at config path %s - %w", ErrParseConfig, configPath, err) + return nil, fmt.Errorf("%s at config path %s - %w", ErrParseConfig.Error(), configPath, err) } // we must ensure the top-level workload that we created is not a component, as the top-level @@ -52,7 +52,7 @@ func Parse(configPath string) (*Processor, error) { if processor.Workload.IsComponent() { return nil, fmt.Errorf( "%s - no %s found at config path %s - %w", - ErrParseConfig, + ErrParseConfig.Error(), kinds.WorkloadKindCollection, configPath, ErrCollectionRequired, @@ -157,7 +157,7 @@ func (processor *Processor) parseComponents( processor.Children = append(processor.Children, componentProcessor) if err := componentProcessor.parse(validator); err != nil { - return fmt.Errorf("%w; %s at path %s", err, ErrParseComponentConfig, componentPath) + return fmt.Errorf("%w; %s at path %s", err, ErrParseComponentConfig.Error(), componentPath) } // set the config path diff --git a/internal/workload/v1/config/parse_internal_test.go b/internal/workload/v1/config/parse_internal_test.go index 73cb9d1..87f2056 100644 --- a/internal/workload/v1/config/parse_internal_test.go +++ b/internal/workload/v1/config/parse_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/config/processor.go b/internal/workload/v1/config/processor.go index 6760567..04fd707 100644 --- a/internal/workload/v1/config/processor.go +++ b/internal/workload/v1/config/processor.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/config/validate.go b/internal/workload/v1/config/validate.go index 6224455..2a09f70 100644 --- a/internal/workload/v1/config/validate.go +++ b/internal/workload/v1/config/validate.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/kinds/api.go b/internal/workload/v1/kinds/api.go index ab24ade..5e6c649 100644 --- a/internal/workload/v1/kinds/api.go +++ b/internal/workload/v1/kinds/api.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/kinds/api_internal_test.go b/internal/workload/v1/kinds/api_internal_test.go index 4fc3522..9144ff3 100644 --- a/internal/workload/v1/kinds/api_internal_test.go +++ b/internal/workload/v1/kinds/api_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/kinds/collection.go b/internal/workload/v1/kinds/collection.go index b5b7747..38b3a58 100644 --- a/internal/workload/v1/kinds/collection.go +++ b/internal/workload/v1/kinds/collection.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -260,13 +260,13 @@ func (c *WorkloadCollection) GetSubCommand() *companion.CLI { func (c *WorkloadCollection) LoadManifests(workloadPath string) error { expanded, err := manifests.ExpandManifests(workloadPath, c.Spec.Resources) if err != nil { - return fmt.Errorf("%w; %s for collection %s", err, ErrLoadManifests, c.Name) + return fmt.Errorf("%w; %s for collection %s", err, ErrLoadManifests.Error(), c.Name) } c.Spec.Manifests = expanded for _, manifest := range *c.Spec.Manifests { if err := manifest.LoadContent(c.IsCollection()); err != nil { - return fmt.Errorf("%w; %s for collection %s", err, ErrLoadManifests, c.Name) + return fmt.Errorf("%w; %s for collection %s", err, ErrLoadManifests.Error(), c.Name) } } diff --git a/internal/workload/v1/kinds/collection_internal_test.go b/internal/workload/v1/kinds/collection_internal_test.go index 61b3342..fce8be4 100644 --- a/internal/workload/v1/kinds/collection_internal_test.go +++ b/internal/workload/v1/kinds/collection_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/kinds/component.go b/internal/workload/v1/kinds/component.go index e84c29a..1954f65 100644 --- a/internal/workload/v1/kinds/component.go +++ b/internal/workload/v1/kinds/component.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -235,13 +235,13 @@ func (c *ComponentWorkload) GetSubCommand() *companion.CLI { func (c *ComponentWorkload) LoadManifests(workloadPath string) error { expanded, err := manifests.ExpandManifests(workloadPath, c.Spec.Resources) if err != nil { - return fmt.Errorf("%w; %s for component %s", err, ErrLoadManifests, c.Name) + return fmt.Errorf("%w; %s for component %s", err, ErrLoadManifests.Error(), c.Name) } c.Spec.Manifests = expanded for _, manifest := range *c.Spec.Manifests { if err := manifest.LoadContent(c.IsCollection()); err != nil { - return fmt.Errorf("%w; %s for component %s", err, ErrLoadManifests, c.Name) + return fmt.Errorf("%w; %s for component %s", err, ErrLoadManifests.Error(), c.Name) } } diff --git a/internal/workload/v1/kinds/component_internal_test.go b/internal/workload/v1/kinds/component_internal_test.go index d57a5a9..7f0bbe5 100644 --- a/internal/workload/v1/kinds/component_internal_test.go +++ b/internal/workload/v1/kinds/component_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/kinds/kinds.go b/internal/workload/v1/kinds/kinds.go index 797766d..6a93aa5 100644 --- a/internal/workload/v1/kinds/kinds.go +++ b/internal/workload/v1/kinds/kinds.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/kinds/standalone.go b/internal/workload/v1/kinds/standalone.go index 88be0f5..bf01315 100644 --- a/internal/workload/v1/kinds/standalone.go +++ b/internal/workload/v1/kinds/standalone.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -222,13 +222,13 @@ func (s *StandaloneWorkload) GetSubCommand() *companion.CLI { func (s *StandaloneWorkload) LoadManifests(workloadPath string) error { expanded, err := manifests.ExpandManifests(workloadPath, s.Spec.Resources) if err != nil { - return fmt.Errorf("%w; %s for standalone workload %s", err, ErrLoadManifests, s.Name) + return fmt.Errorf("%w; %s for standalone workload %s", err, ErrLoadManifests.Error(), s.Name) } s.Spec.Manifests = expanded for _, manifest := range *s.Spec.Manifests { if err := manifest.LoadContent(s.IsCollection()); err != nil { - return fmt.Errorf("%w; %s for standalone workload %s", err, ErrLoadManifests, s.Name) + return fmt.Errorf("%w; %s for standalone workload %s", err, ErrLoadManifests.Error(), s.Name) } } diff --git a/internal/workload/v1/kinds/standalone_internal_test.go b/internal/workload/v1/kinds/standalone_internal_test.go index b889551..c22ed3d 100644 --- a/internal/workload/v1/kinds/standalone_internal_test.go +++ b/internal/workload/v1/kinds/standalone_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/kinds/workload.go b/internal/workload/v1/kinds/workload.go index b282cfc..26141a3 100644 --- a/internal/workload/v1/kinds/workload.go +++ b/internal/workload/v1/kinds/workload.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -224,7 +224,7 @@ func (ws *WorkloadSpec) appendCollectionRef() { } func processManifestError(err error, manifest *manifests.Manifest) error { - return fmt.Errorf("%w; %s [%s]", err, ErrProcessManifest, manifest.Filename) + return fmt.Errorf("%w; %s [%s]", err, ErrProcessManifest.Error(), manifest.Filename) } func (ws *WorkloadSpec) processManifests(markerTypes ...markers.MarkerType) error { @@ -251,7 +251,7 @@ func (ws *WorkloadSpec) processManifests(markerTypes ...markers.MarkerType) erro return fmt.Errorf( "%w; %s - unable to decode object in manifest file %s", err, - ErrProcessManifest, + ErrProcessManifest.Error(), manifestFile.Filename, ) } diff --git a/internal/workload/v1/manifests/child_resource.go b/internal/workload/v1/manifests/child_resource.go index f2f0179..ddfe72c 100644 --- a/internal/workload/v1/manifests/child_resource.go +++ b/internal/workload/v1/manifests/child_resource.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -74,7 +74,7 @@ func (resource *ChildResource) ProcessResourceMarkers(markerCollection *markers. // obtain the marker results from the child resource input yaml _, markerResults, err := markers.InspectForYAML([]byte(resource.StaticContent), markers.ResourceMarkerType) if err != nil { - return fmt.Errorf("%w; %s for child resource %s", err, ErrChildResourceResourceMarkerInspect, resource) + return fmt.Errorf("%w; %s for child resource %s", err, ErrChildResourceResourceMarkerInspect.Error(), resource) } // return immediately if no resource markers are present @@ -90,7 +90,7 @@ func (resource *ChildResource) ProcessResourceMarkers(markerCollection *markers. } if err := marker.Process(markerCollection); err != nil { - return fmt.Errorf("%w; %s for child resource %s", err, ErrChildResourceResourceMarkerProcess, resource) + return fmt.Errorf("%w; %s for child resource %s", err, ErrChildResourceResourceMarkerProcess.Error(), resource) } if marker.GetIncludeCode() != "" { diff --git a/internal/workload/v1/manifests/child_resource_internal_test.go b/internal/workload/v1/manifests/child_resource_internal_test.go index b8fe7a2..cd7ed1a 100644 --- a/internal/workload/v1/manifests/child_resource_internal_test.go +++ b/internal/workload/v1/manifests/child_resource_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // SPDX-License-Identifier: MIT package manifests diff --git a/internal/workload/v1/manifests/manifest.go b/internal/workload/v1/manifests/manifest.go index fa7245b..a7099b7 100644 --- a/internal/workload/v1/manifests/manifest.go +++ b/internal/workload/v1/manifests/manifest.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -85,7 +85,7 @@ func (manifest *Manifest) ExtractManifests() []string { func (manifest *Manifest) LoadContent(isCollection bool) error { manifestContent, err := os.ReadFile(manifest.Filename) if err != nil { - return fmt.Errorf("%w; %s for manifest file %s", err, ErrProcessManifest, manifest.Filename) + return fmt.Errorf("%w; %s for manifest file %s", err, ErrProcessManifest.Error(), manifest.Filename) } if isCollection { diff --git a/internal/workload/v1/manifests/manifest_internal_test.go b/internal/workload/v1/manifests/manifest_internal_test.go index bfbdbaa..147159a 100644 --- a/internal/workload/v1/manifests/manifest_internal_test.go +++ b/internal/workload/v1/manifests/manifest_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // SPDX-License-Identifier: MIT package manifests diff --git a/internal/workload/v1/markers/collection_field_marker.go b/internal/workload/v1/markers/collection_field_marker.go index d30f8c5..0e3442d 100644 --- a/internal/workload/v1/markers/collection_field_marker.go +++ b/internal/workload/v1/markers/collection_field_marker.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -45,9 +45,7 @@ func defineCollectionFieldMarker(registry *marker.Registry) error { return nil } -// // FieldMarkerProcessor interface methods. -// func (cfm *CollectionFieldMarker) GetName() string { if cfm.Name == nil { return "" diff --git a/internal/workload/v1/markers/collection_field_marker_internal_test.go b/internal/workload/v1/markers/collection_field_marker_internal_test.go index f3975d3..905e820 100644 --- a/internal/workload/v1/markers/collection_field_marker_internal_test.go +++ b/internal/workload/v1/markers/collection_field_marker_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/markers/field_marker.go b/internal/workload/v1/markers/field_marker.go index d17837f..89a16a5 100644 --- a/internal/workload/v1/markers/field_marker.go +++ b/internal/workload/v1/markers/field_marker.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -70,9 +70,7 @@ func defineFieldMarker(registry *marker.Registry) error { return nil } -// // FieldMarker Processor interface methods. -// func (fm *FieldMarker) GetName() string { if fm.Name == nil { return "" diff --git a/internal/workload/v1/markers/field_marker_internal_test.go b/internal/workload/v1/markers/field_marker_internal_test.go index 8715344..683369d 100644 --- a/internal/workload/v1/markers/field_marker_internal_test.go +++ b/internal/workload/v1/markers/field_marker_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/markers/field_types.go b/internal/workload/v1/markers/field_types.go index cbe70cb..f7a896d 100644 --- a/internal/workload/v1/markers/field_types.go +++ b/internal/workload/v1/markers/field_types.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/markers/field_types_internal_test.go b/internal/workload/v1/markers/field_types_internal_test.go index 1097638..d9b1711 100644 --- a/internal/workload/v1/markers/field_types_internal_test.go +++ b/internal/workload/v1/markers/field_types_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/markers/markers.go b/internal/workload/v1/markers/markers.go index 4df157b..2360d4c 100644 --- a/internal/workload/v1/markers/markers.go +++ b/internal/workload/v1/markers/markers.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/markers/markers_internal_test.go b/internal/workload/v1/markers/markers_internal_test.go index 9e13604..671f7e6 100644 --- a/internal/workload/v1/markers/markers_internal_test.go +++ b/internal/workload/v1/markers/markers_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/markers/resource_marker.go b/internal/workload/v1/markers/resource_marker.go index be066b4..79b6d78 100644 --- a/internal/workload/v1/markers/resource_marker.go +++ b/internal/workload/v1/markers/resource_marker.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -160,7 +160,7 @@ func (rm *ResourceMarker) GetParent() string { func (rm *ResourceMarker) Process(markers *MarkerCollection) error { // ensure we have a valid field marker before continuing to process if err := rm.validate(); err != nil { - return fmt.Errorf("%w; %s", err, ErrResourceMarkerInvalid) + return fmt.Errorf("%w; %s", err, ErrResourceMarkerInvalid.Error()) } // associate field markers from a collection of markers to this resource marker diff --git a/internal/workload/v1/markers/resource_marker_internal_test.go b/internal/workload/v1/markers/resource_marker_internal_test.go index 01ee1fd..705ee4f 100644 --- a/internal/workload/v1/markers/resource_marker_internal_test.go +++ b/internal/workload/v1/markers/resource_marker_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/rbac/rbac.go b/internal/workload/v1/rbac/rbac.go index c6b583e..56c7a30 100644 --- a/internal/workload/v1/rbac/rbac.go +++ b/internal/workload/v1/rbac/rbac.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/rbac/rbac_internal_test.go b/internal/workload/v1/rbac/rbac_internal_test.go index 11ff4a4..fa073e1 100644 --- a/internal/workload/v1/rbac/rbac_internal_test.go +++ b/internal/workload/v1/rbac/rbac_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/rbac/role_rule.go b/internal/workload/v1/rbac/role_rule.go index f8a8286..046dc4b 100644 --- a/internal/workload/v1/rbac/role_rule.go +++ b/internal/workload/v1/rbac/role_rule.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -51,7 +51,7 @@ func (roleRule *RoleRule) processRaw(rule interface{}) error { for objectField, fieldKey := range fields { if err := objectField.setValues(rule, fieldKey); err != nil { - return fmt.Errorf("%w; %s: %v", err, ErrorProcessRoleRule, rule) + return fmt.Errorf("%w; %s: %v", err, ErrorProcessRoleRule.Error(), rule) } } @@ -67,7 +67,7 @@ func (field *RoleRuleField) setValues(rule interface{}, fieldKey string) error { fieldValues, err := utils.ToArrayString(fieldValue) if err != nil { - return fmt.Errorf("%w; %s: [%s]", err, ErrorProcessRoleRuleField, fieldKey) + return fmt.Errorf("%w; %s: [%s]", err, ErrorProcessRoleRuleField.Error(), fieldKey) } *field = fieldValues diff --git a/internal/workload/v1/rbac/role_rule_internal_test.go b/internal/workload/v1/rbac/role_rule_internal_test.go index 0bf8fde..024fbe1 100644 --- a/internal/workload/v1/rbac/role_rule_internal_test.go +++ b/internal/workload/v1/rbac/role_rule_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/rbac/rule.go b/internal/workload/v1/rbac/rule.go index c03514d..d9125e0 100644 --- a/internal/workload/v1/rbac/rule.go +++ b/internal/workload/v1/rbac/rule.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/rbac/rule_internal_test.go b/internal/workload/v1/rbac/rule_internal_test.go index 4a063a7..e1d06c1 100644 --- a/internal/workload/v1/rbac/rule_internal_test.go +++ b/internal/workload/v1/rbac/rule_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/rbac/rules.go b/internal/workload/v1/rbac/rules.go index 8ca1725..0c83e7b 100644 --- a/internal/workload/v1/rbac/rules.go +++ b/internal/workload/v1/rbac/rules.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/internal/workload/v1/rbac/rules_internal_test.go b/internal/workload/v1/rbac/rules_internal_test.go index 897f0aa..dfee3f1 100644 --- a/internal/workload/v1/rbac/rules_internal_test.go +++ b/internal/workload/v1/rbac/rules_internal_test.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/pkg/cli/init.go b/pkg/cli/init.go index 01261e2..fd48b25 100644 --- a/pkg/cli/init.go +++ b/pkg/cli/init.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/pkg/cli/init_config.go b/pkg/cli/init_config.go index 8e85cf1..52530a7 100644 --- a/pkg/cli/init_config.go +++ b/pkg/cli/init_config.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT @@ -110,7 +110,7 @@ func (i *initConfigSubCommand) addInitSubCommand(parentCommand *cobra.Command) e subCommand.RunE = func(cmd *cobra.Command, args []string) error { if err := subcommand.InitConfig(i.options); err != nil { - return fmt.Errorf("%w; %s", err, returnErr) + return fmt.Errorf("%w; %s", err, returnErr.Error()) } return nil diff --git a/pkg/cli/license.go b/pkg/cli/license.go index daf1bec..8c16199 100644 --- a/pkg/cli/license.go +++ b/pkg/cli/license.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT diff --git a/pkg/cli/update.go b/pkg/cli/update.go index 237df6d..51c7ce9 100644 --- a/pkg/cli/update.go +++ b/pkg/cli/update.go @@ -1,4 +1,4 @@ -// Copyright 2022 Nukleros +// Copyright 2023 Nukleros // Copyright 2021 VMware, Inc. // SPDX-License-Identifier: MIT