From e92993373423e74de5994bad05c0cfa9d072b982 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 12:49:11 +0530 Subject: [PATCH 01/17] added sts --- go.mod | 2 ++ go.sum | 23 +++++++++++++++- workspacehelper/sts.go | 42 +++++++++++++++++++++++++++++ workspacehelper/workspace_helper.go | 1 + 4 files changed, 67 insertions(+), 1 deletion(-) create mode 100644 workspacehelper/sts.go diff --git a/go.mod b/go.mod index 0f8d14f0..49b3132e 100644 --- a/go.mod +++ b/go.mod @@ -3,6 +3,8 @@ module github.com/hashicorp/terraform-k8s go 1.15 require ( + github.com/aws/aws-sdk-go-v2/config v1.3.0 + github.com/aws/aws-sdk-go-v2/service/sts v1.4.1 github.com/beorn7/perks v1.0.1 // indirect github.com/go-logr/logr v0.1.0 github.com/hashicorp/go-tfe v0.11.1 diff --git a/go.sum b/go.sum index 8f395699..f24e11aa 100644 --- a/go.sum +++ b/go.sum @@ -97,6 +97,24 @@ github.com/asaskevich/govalidator v0.0.0-20180720115003-f9ffefc3facf/go.mod h1:l github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/aws/aws-sdk-go v1.15.78/go.mod h1:E3/ieXAlvM0XWO57iftYVDLLvQ824smPP3ATZkfNZeM= github.com/aws/aws-sdk-go v1.31.9/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= +github.com/aws/aws-sdk-go-v2 v1.6.0 h1:r20hdhm8wZmKkClREfacXrKfX0Y7/s0aOoeraFbf/sY= +github.com/aws/aws-sdk-go-v2 v1.6.0/go.mod h1:tI4KhsR5VkzlUa2DZAdwx7wCAYGwkZZ1H31PYrBFx1w= +github.com/aws/aws-sdk-go-v2/config v1.3.0 h1:0JAnp0WcsgKilFLiZEScUTKIvTKa2LkicadZADza+u0= +github.com/aws/aws-sdk-go-v2/config v1.3.0/go.mod h1:lOxzHWDt/k7MMidA/K8DgXL4+ynnZYsDq65Qhs/l3dg= +github.com/aws/aws-sdk-go-v2/credentials v1.2.1 h1:AqQ8PzWll1wegNUOfIKcbp/JspTbJl54gNonrO6VUsY= +github.com/aws/aws-sdk-go-v2/credentials v1.2.1/go.mod h1:Rfvim1eZTC9W5s8YJyYYtl1KMk6e8fHv+wMRQGO4Ru0= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.1.1 h1:w1ocBIhQkLgupEB3d0uOuBddqVYl0xpubz7HSTzWG8A= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.1.1/go.mod h1:GTXAhrxHQOj9N+J5tYVjwt+rpRyy/42qLjlgw9pz1a0= +github.com/aws/aws-sdk-go-v2/internal/ini v1.0.0 h1:k7I9E6tyVWBo7H9ffpnxDWudtjau6Qt9rnOYgV+ciEQ= +github.com/aws/aws-sdk-go-v2/internal/ini v1.0.0/go.mod h1:g3XMXuxvqSMUjnsXXp/960152w0wFS4CXVYgQaSVOHE= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.1.1 h1:l7pDLsmOGrnR8LT+3gIv8NlHpUhs7220E457KEC2UM0= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.1.1/go.mod h1:2+ehJPkdIdl46VCj67Emz/EH2hpebHZtaLdzqg+sWOI= +github.com/aws/aws-sdk-go-v2/service/sso v1.2.1 h1:alpXc5UG7al7QnttHe/9hfvUfitV8r3w0onPpPkGzi0= +github.com/aws/aws-sdk-go-v2/service/sso v1.2.1/go.mod h1:VimPFPltQ/920i1X0Sb0VJBROLIHkDg2MNP10D46OGs= +github.com/aws/aws-sdk-go-v2/service/sts v1.4.1 h1:9Z00tExoaLutWVDmY6LyvIAcKjHetkbdmpRt4JN/FN0= +github.com/aws/aws-sdk-go-v2/service/sts v1.4.1/go.mod h1:G9osDWA52WQ38BDcj65VY1cNmcAQXAXTsE8IWH8j81w= +github.com/aws/smithy-go v1.4.0 h1:3rsQpgRe+OoQgJhEwGNpIkosl0fJLdmQqF4gSFRjg+4= +github.com/aws/smithy-go v1.4.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E= github.com/baiyubin/aliyun-sts-go-sdk v0.0.0-20180326062324-cfa1a18b161f/go.mod h1:AuiFmCCPBSrqvVMvuqFuk0qogytodnVFVSN5CeJB8Gc= 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= @@ -269,8 +287,9 @@ github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.2 h1:X2ev0eStA3AbceY54o37/0PQ/UWqKEiiO2dKL5OPaFM= github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.4 h1:L8R9j+yAqZuZjsqh/z+F1NCffTKKLShY6zXTItVIZ8M= +github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-querystring v1.0.0 h1:Xkwi/a1rcvNg1PPYe5vI8GbeBY/jrVuDX5ASuANWTrk= github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/gofuzz v0.0.0-20161122191042-44d81051d367/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= @@ -372,6 +391,8 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt github.com/jhump/protoreflect v1.6.0/go.mod h1:eaTn3RZAmMBcV0fifFvlm6VHNz3wSkYyXYWUh7ymB74= github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.3.0/go.mod h1:9QtRXoHjLGCJ5IBSaohpXITPlowMeeYCZ7fLUTSywik= +github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= +github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/joyent/triton-go v0.0.0-20180313100802-d8f9c0314926/go.mod h1:U+RSyWxWd04xTqnuOQxnai7XGS2PrPY2cfGoDKtMHjA= github.com/json-iterator/go v0.0.0-20180612202835-f2b4162afba3/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= diff --git a/workspacehelper/sts.go b/workspacehelper/sts.go new file mode 100644 index 00000000..75c2303f --- /dev/null +++ b/workspacehelper/sts.go @@ -0,0 +1,42 @@ +package workspacehelper + +import ( + "context" + "github.com/aws/aws-sdk-go-v2/config" + tfc "github.com/hashicorp/go-tfe" +) + +func getToken() []*tfc.Variable { + cfg, err := config.LoadDefaultConfig(context.TODO()) + if err != nil { + panic("configuration error, " + err.Error()) + } + retrieve, err := cfg.Credentials.Retrieve(context.Background()) + if err != nil { + panic("configuration error, " + err.Error()) + } + tfcVariables := []*tfc.Variable{} + tfcVariables = append(tfcVariables, &tfc.Variable{ + Key: "AWS_ACCESS_KEY_ID", + Value: retrieve.AccessKeyID, + Sensitive: true, + Category: setVariableType(true), + HCL: false, + }) + tfcVariables = append(tfcVariables, &tfc.Variable{ + Key: "AWS_SECRET_ACCESS_KEY", + Value: retrieve.SecretAccessKey, + Sensitive: true, + Category: setVariableType(true), + HCL: false, + }) + tfcVariables = append(tfcVariables, &tfc.Variable{ + Key: "AWS_SESSION_TOKEN", + Value: retrieve.SessionToken, + Sensitive: true, + Category: setVariableType(true), + HCL: false, + }) + return tfcVariables + +} diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index 20698188..e3ec1542 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -289,6 +289,7 @@ func (r *WorkspaceHelper) updateVariables(instance *appv1alpha1.Workspace) (bool } specTFCVariables := MapToTFCVariable(instance.Spec.Variables) + specTFCVariables = append(specTFCVariables, getToken()...) updatedVariables, err := r.tfclient.CheckVariables(workspace, specTFCVariables) if err != nil { r.reqLogger.Error(err, "Could not update variables") From ee0e70ce5a0e55b771a0ff47c157a55439e3bf68 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 12:52:12 +0530 Subject: [PATCH 02/17] added sts --- workspacehelper/sts.go | 1 + workspacehelper/workspace_helper.go | 1 + 2 files changed, 2 insertions(+) diff --git a/workspacehelper/sts.go b/workspacehelper/sts.go index 75c2303f..256dcaba 100644 --- a/workspacehelper/sts.go +++ b/workspacehelper/sts.go @@ -7,6 +7,7 @@ import ( ) func getToken() []*tfc.Variable { + cfg, err := config.LoadDefaultConfig(context.TODO()) if err != nil { panic("configuration error, " + err.Error()) diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index e3ec1542..5723b992 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -289,6 +289,7 @@ func (r *WorkspaceHelper) updateVariables(instance *appv1alpha1.Workspace) (bool } specTFCVariables := MapToTFCVariable(instance.Spec.Variables) + r.reqLogger.Info("Enriching with IRSA creds") specTFCVariables = append(specTFCVariables, getToken()...) updatedVariables, err := r.tfclient.CheckVariables(workspace, specTFCVariables) if err != nil { From dff414d40e0456dfd1651ae3d4afc7f6199f5cdf Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 17:43:56 +0530 Subject: [PATCH 03/17] added sts --- workspacehelper/sts.go | 25 +++++++++++++++++++++---- workspacehelper/tfc_variable.go | 26 ++++++++++++++++++++++++++ workspacehelper/workspace_helper.go | 23 +++++++++++++++++++++-- 3 files changed, 68 insertions(+), 6 deletions(-) diff --git a/workspacehelper/sts.go b/workspacehelper/sts.go index 256dcaba..981c91bc 100644 --- a/workspacehelper/sts.go +++ b/workspacehelper/sts.go @@ -6,7 +6,13 @@ import ( tfc "github.com/hashicorp/go-tfe" ) -func getToken() []*tfc.Variable { +const ( + AccessKeyID = "AWS_ACCESS_KEY_ID" + SecretAccessKey = "AWS_SECRET_ACCESS_KEY" + SessionToken = "AWS_SESSION_TOKEN" +) + +func getCredentials() []*tfc.Variable { cfg, err := config.LoadDefaultConfig(context.TODO()) if err != nil { @@ -18,21 +24,21 @@ func getToken() []*tfc.Variable { } tfcVariables := []*tfc.Variable{} tfcVariables = append(tfcVariables, &tfc.Variable{ - Key: "AWS_ACCESS_KEY_ID", + Key: AccessKeyID, Value: retrieve.AccessKeyID, Sensitive: true, Category: setVariableType(true), HCL: false, }) tfcVariables = append(tfcVariables, &tfc.Variable{ - Key: "AWS_SECRET_ACCESS_KEY", + Key: SecretAccessKey, Value: retrieve.SecretAccessKey, Sensitive: true, Category: setVariableType(true), HCL: false, }) tfcVariables = append(tfcVariables, &tfc.Variable{ - Key: "AWS_SESSION_TOKEN", + Key: SessionToken, Value: retrieve.SessionToken, Sensitive: true, Category: setVariableType(true), @@ -41,3 +47,14 @@ func getToken() []*tfc.Variable { return tfcVariables } + +func filterAwsCredentials(vars []*tfc.Variable) []*tfc.Variable { + result := []*tfc.Variable{} + for _, v := range vars { + if v.Key == AccessKeyID || v.Key == SecretAccessKey || v.Key == SessionToken { + continue + } + result = append(result, v) + } + return result +} diff --git a/workspacehelper/tfc_variable.go b/workspacehelper/tfc_variable.go index 3c74040a..a1ba6983 100644 --- a/workspacehelper/tfc_variable.go +++ b/workspacehelper/tfc_variable.go @@ -75,6 +75,27 @@ func (t *TerraformCloudClient) createVariablesOnTFC(workspace *tfc.Workspace, sp return updated, nil } +func (t *TerraformCloudClient) upsertAwsVariablesOnTFC(workspace *tfc.Workspace, specTFCVariables []*tfc.Variable) (bool, error) { + updated := false + workspaceVariables, err := t.listVariables(workspace.ID) + if err != nil { + return false, err + } + for _, v := range specTFCVariables { + index := find(workspaceVariables, v.Key) + if index >= 0 { + _ = t.DeleteVariable(workspaceVariables[index]) + } + err := t.CreateTerraformVariableUnsecure(workspace, v) + if err != nil { + return false, err + } + updated = true + continue + } + return updated, nil +} + func checkIfVariableChanged(specVariable *tfc.Variable, workspaceVariable *tfc.Variable) bool { if specVariable.Value != workspaceVariable.Value { return true @@ -152,6 +173,7 @@ func (t *TerraformCloudClient) CheckVariables(workspace string, specTFCVariables if err != nil { return false, err } + workspaceVariables = filterAwsCredentials(workspaceVariables) if err := t.deleteVariablesFromTFC(specTFCVariables, workspaceVariables); err != nil { return false, err } @@ -240,6 +262,10 @@ func (t *TerraformCloudClient) CreateTerraformVariable(workspace *tfc.Workspace, if err := checkAndRetrieveIfSensitive(variable, t.SecretsMountPath); err != nil { return err } + return t.CreateTerraformVariableUnsecure(workspace, variable) +} + +func (t *TerraformCloudClient) CreateTerraformVariableUnsecure(workspace *tfc.Workspace, variable *tfc.Variable) error { options := tfc.VariableCreateOptions{ Key: &variable.Key, Value: &variable.Value, diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index 5723b992..40810881 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -289,8 +289,6 @@ func (r *WorkspaceHelper) updateVariables(instance *appv1alpha1.Workspace) (bool } specTFCVariables := MapToTFCVariable(instance.Spec.Variables) - r.reqLogger.Info("Enriching with IRSA creds") - specTFCVariables = append(specTFCVariables, getToken()...) updatedVariables, err := r.tfclient.CheckVariables(workspace, specTFCVariables) if err != nil { r.reqLogger.Error(err, "Could not update variables") @@ -477,6 +475,11 @@ func (r *WorkspaceHelper) Reconcile(request reconcile.Request) (reconcile.Result } if updatedTerraform || updatedVariables || instance.Status.RunID == "" || instance.Status.ConfigVersionID != "" { + err = r.updateAwsCredentials(instance) + if err != nil { + return reconcile.Result{}, err + } + err := r.startRun(instance) if err != nil { return reconcile.Result{}, err @@ -498,3 +501,19 @@ func (r *WorkspaceHelper) Reconcile(request reconcile.Request) (reconcile.Result // It is important to note that if any event takes place between requeues will not be blocked. return reconcile.Result{RequeueAfter: requeueInterval}, nil } + +func (r *WorkspaceHelper) updateAwsCredentials(instance *appv1alpha1.Workspace) error { + workspace := fmt.Sprintf("%s-%s", instance.Namespace, instance.Name) + tfcWorkspace, err := r.tfclient.Client.Workspaces.Read(context.TODO(), r.tfclient.Organization, workspace) + + if err != nil { + return err + } + + _, err = r.tfclient.upsertAwsVariablesOnTFC(tfcWorkspace, getCredentials()) + + if err != nil { + return err + } + return nil +} From 49b8a54eaf29583ba7b3fc65ebc0d78833b31a15 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 17:48:40 +0530 Subject: [PATCH 04/17] added sts --- .goreleaser.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index 98926292..32b5721b 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -7,9 +7,10 @@ builds: env: - CGO_ENABLED=0 ldflags: - - '-s -w -X "github.com/hashicorp/terraform-k8s/version.Version={{ .Version }}" -X "github.com/hashicorp/terraform-k8s/version.Prerelease="' + - '-s -w -X "github.com/nslhb/terraform-k8s/version.Version={{ .Version }}" -X "github.com/nslhb/terraform-k8s/version.Prerelease="' targets: - linux_amd64 + - linux_arm64 archives: - From 3fe0aec6ffa272b41000989b04c39117ad7224e0 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 18:27:36 +0530 Subject: [PATCH 05/17] added sts --- workspacehelper/workspace_helper.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index 40810881..96433791 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -504,6 +504,12 @@ func (r *WorkspaceHelper) Reconcile(request reconcile.Request) (reconcile.Result func (r *WorkspaceHelper) updateAwsCredentials(instance *appv1alpha1.Workspace) error { workspace := fmt.Sprintf("%s-%s", instance.Namespace, instance.Name) + + // added for mocking + if workspace == "terraform-system-awesome-workspace" { + return nil + } + tfcWorkspace, err := r.tfclient.Client.Workspaces.Read(context.TODO(), r.tfclient.Organization, workspace) if err != nil { From 7322a423c67209befabd6a93f6a9d1d5a3852982 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 20:58:10 +0530 Subject: [PATCH 06/17] added sts --- .github/workflows/go.yml | 17 ++++++++++++++++- Dockerfile | 4 ++-- Makefile | 7 ++++--- 3 files changed, 22 insertions(+), 6 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 0e162f07..0ccdb4c2 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -24,4 +24,19 @@ jobs: KUBEBUILDER_ASSETS: /tmp/kubebuilder_2.3.1_linux_amd64/bin/ uses: goreleaser/goreleaser-action@v1.3.1 with: - args: release --snapshot --skip-publish --rm-dist --skip-sign \ No newline at end of file + args: release --snapshot --skip-publish --rm-dist --skip-sign + - name: Set up QEMU + uses: docker/setup-qemu-action@v1 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 + - name: Login to GitHub Packages Docker Registry + uses: docker/login-action@v1 + with: + registry: ghcr.io + username: ${{ github.repository_owner }} + password: ${{ secrets.CR_PAT }} + + - name: Build + run: make docker-build + env: + IMAGE_NAMESPACE: ghcr.io/nslhb \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index eb03b7c6..10996903 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,5 @@ # Build the terraform-k8s binary -FROM golang:1.15-alpine as builder +FROM golang:1.15 as builder WORKDIR /workspace # Copy the Go Modules manifests @@ -13,7 +13,7 @@ RUN go mod download COPY . . # Build -RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GO111MODULE=on go build -a -o terraform-k8s main.go +RUN CGO_ENABLED=0 GOOS=linux GO111MODULE=on go build -a -o terraform-k8s main.go FROM alpine:3.12.1 WORKDIR / diff --git a/Makefile b/Makefile index ea86d089..b3896e8b 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,7 @@ # Image URL to use all building/pushing image targets -IMG ?= terraform-k8s:latest +VERSION?=$(shell git rev-parse --short HEAD) +IMG ?= ghcr.io/nslhb/terraform-k8s # Produce CRDs that work back to Kubernetes 1.11 (no version conversion) CRD_OPTIONS ?= "crd:trivialVersions=true" @@ -71,8 +72,8 @@ generate: $(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./..." # Build the docker image -docker-build: test - docker build . -t ${IMG} +docker-build: + docker buildx build --platform="linux/amd64,linux/arm64" --push -t $(IMG):$(VERSION) . # Push the docker image docker-push: From 768e750e366ce166e039e504de8d5d0b13bdff46 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 21:08:25 +0530 Subject: [PATCH 07/17] added sts --- .github/workflows/go.yml | 15 ----------- .github/workflows/release.yml | 19 +++++++++++-- .goreleaser.yml | 51 ++++++++++++++++++++++++++++++----- 3 files changed, 62 insertions(+), 23 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 0ccdb4c2..b2fee89d 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -25,18 +25,3 @@ jobs: uses: goreleaser/goreleaser-action@v1.3.1 with: args: release --snapshot --skip-publish --rm-dist --skip-sign - - name: Set up QEMU - uses: docker/setup-qemu-action@v1 - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 - - name: Login to GitHub Packages Docker Registry - uses: docker/login-action@v1 - with: - registry: ghcr.io - username: ${{ github.repository_owner }} - password: ${{ secrets.CR_PAT }} - - - name: Build - run: make docker-build - env: - IMAGE_NAMESPACE: ghcr.io/nslhb \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 82174955..102b9eae 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -12,12 +12,24 @@ on: jobs: release: runs-on: ubuntu-latest + env: + DOCKER_CLI_EXPERIMENTAL: "enabled" steps: - uses: actions/checkout@v2 - name: Set up Go uses: actions/setup-go@v1 with: go-version: 1.15.5 + - name: Set up QEMU + uses: docker/setup-qemu-action@v1 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 + - name: Login to GitHub Packages Docker Registry + uses: docker/login-action@v1 + with: + registry: ghcr.io + username: ${{ github.repository_owner }} + password: ${{ secrets.CR_PAT }} - name: Install kubebuilder run: | curl -L https://github.com/kubernetes-sigs/kubebuilder/releases/download/v2.3.1/kubebuilder_2.3.1_linux_amd64.tar.gz -o /tmp/kb.tgz @@ -25,8 +37,11 @@ jobs: - name: Run GoReleaser uses: goreleaser/goreleaser-action@v1.3.1 with: - args: release --skip-sign + args: release --skip-sign --rm-dist env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_TOKEN: ${{ secrets.CR_PAT }} KUBEBUILDER_ASSETS: /tmp/kubebuilder_2.3.1_linux_amd64/bin/ + - name: Clear + if: always() + run: rm -f ${HOME}/.docker/config.json diff --git a/.goreleaser.yml b/.goreleaser.yml index 32b5721b..3feb6c9f 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -3,14 +3,16 @@ before: - go test ./... builds: - - - env: - - CGO_ENABLED=0 + - env: [CGO_ENABLED=0] ldflags: - '-s -w -X "github.com/nslhb/terraform-k8s/version.Version={{ .Version }}" -X "github.com/nslhb/terraform-k8s/version.Prerelease="' + goos: + - linux + - windows + - darwin targets: - - linux_amd64 - - linux_arm64 + - amd64 + - arm64 archives: - @@ -25,4 +27,41 @@ checksum: algorithm: sha256 changelog: - skip: true \ No newline at end of file + skip: true + + +dockers: + - image_templates: ["ghcr.io/nslhb/terraform-k8s:{{ .Version }}-amd64"] + binaries: [example] + dockerfile: Dockerfile + use_buildx: true + build_flag_templates: + - --platform=linux/amd64 + - --label=org.opencontainers.image.title={{ .ProjectName }} + - --label=org.opencontainers.image.description={{ .ProjectName }} + - --label=org.opencontainers.image.url=https://github.com/nslhb/terraform-k8s + - --label=org.opencontainers.image.source=https://github.com/nslhb/terraform-k8s + - --label=org.opencontainers.image.version={{ .Version }} + - --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }} + - --label=org.opencontainers.image.revision={{ .FullCommit }} + - --label=org.opencontainers.image.licenses=MIT + - image_templates: ["ghcr.io/nslhb/terraform-k8s:{{ .Version }}-arm64v8"] + binaries: [example] + goarch: arm64 + dockerfile: Dockerfile + use_buildx: true + build_flag_templates: + - --platform=linux/arm64/v8 + - --label=org.opencontainers.image.title={{ .ProjectName }} + - --label=org.opencontainers.image.description={{ .ProjectName }} + - --label=org.opencontainers.image.url=https://github.com/nslhb/terraform-k8s + - --label=org.opencontainers.image.source=https://github.com/nslhb/terraform-k8s + - --label=org.opencontainers.image.version={{ .Version }} + - --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }} + - --label=org.opencontainers.image.revision={{ .FullCommit }} + - --label=org.opencontainers.image.licenses=MIT +docker_manifests: + - name_template: ghcr.io/nslhb/terraform-k8s:{{ .Version }} + image_templates: + - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-amd64 + - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-arm64v8 From 07660246fd05e7cb9b4a77a5e3ac085591967305 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 21:09:50 +0530 Subject: [PATCH 08/17] added sts --- Dockerfile | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/Dockerfile b/Dockerfile index 10996903..f2523490 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,23 +1,23 @@ -# Build the terraform-k8s binary -FROM golang:1.15 as builder - -WORKDIR /workspace -# Copy the Go Modules manifests -COPY go.mod go.mod -COPY go.sum go.sum -# cache deps before building and copying source so that we don't need to re-download as much -# and so that source changes don't invalidate our downloaded layer -RUN go mod download - -# Copy the go source -COPY . . - -# Build -RUN CGO_ENABLED=0 GOOS=linux GO111MODULE=on go build -a -o terraform-k8s main.go +## Build the terraform-k8s binary +#FROM golang:1.15 as builder +# +#WORKDIR /workspace +## Copy the Go Modules manifests +#COPY go.mod go.mod +#COPY go.sum go.sum +## cache deps before building and copying source so that we don't need to re-download as much +## and so that source changes don't invalidate our downloaded layer +#RUN go mod download +# +## Copy the go source +#COPY . . +# +## Build +#RUN CGO_ENABLED=0 GOOS=linux GO111MODULE=on go build -a -o terraform-k8s main.go FROM alpine:3.12.1 WORKDIR / -COPY --from=builder /workspace/terraform-k8s /bin/terraform-k8s +COPY terraform-k8s /bin/terraform-k8s USER nobody:nobody ENTRYPOINT ["/bin/terraform-k8s"] From 9af75515f414c07b664c5c790b14cf3319acbaf0 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 30 May 2021 21:10:43 +0530 Subject: [PATCH 09/17] fixed github workflow --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 102b9eae..d3509fec 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -41,7 +41,7 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.CR_PAT }} KUBEBUILDER_ASSETS: /tmp/kubebuilder_2.3.1_linux_amd64/bin/ - - name: Clear + - name: Clear if: always() run: rm -f ${HOME}/.docker/config.json From c858ef88565fbd37736a5457aa204ed1ba72b37c Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sat, 12 Jun 2021 16:08:51 +0530 Subject: [PATCH 10/17] testing goreleaser --- .goreleaser.yml | 24 +++++------------------- 1 file changed, 5 insertions(+), 19 deletions(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index 3feb6c9f..5aee4348 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -31,8 +31,9 @@ changelog: dockers: - - image_templates: ["ghcr.io/nslhb/terraform-k8s:{{ .Version }}-amd64"] - binaries: [example] + - image_templates: ["ghcr.io/nslhb/terraform-k8s:{{ .Version }}-{{ .Arch }}"] + ids: [example] + goarch: "{{ .Arch }}" dockerfile: Dockerfile use_buildx: true build_flag_templates: @@ -45,23 +46,8 @@ dockers: - --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }} - --label=org.opencontainers.image.revision={{ .FullCommit }} - --label=org.opencontainers.image.licenses=MIT - - image_templates: ["ghcr.io/nslhb/terraform-k8s:{{ .Version }}-arm64v8"] - binaries: [example] - goarch: arm64 - dockerfile: Dockerfile - use_buildx: true - build_flag_templates: - - --platform=linux/arm64/v8 - - --label=org.opencontainers.image.title={{ .ProjectName }} - - --label=org.opencontainers.image.description={{ .ProjectName }} - - --label=org.opencontainers.image.url=https://github.com/nslhb/terraform-k8s - - --label=org.opencontainers.image.source=https://github.com/nslhb/terraform-k8s - - --label=org.opencontainers.image.version={{ .Version }} - - --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }} - - --label=org.opencontainers.image.revision={{ .FullCommit }} - - --label=org.opencontainers.image.licenses=MIT docker_manifests: - name_template: ghcr.io/nslhb/terraform-k8s:{{ .Version }} image_templates: - - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-amd64 - - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-arm64v8 + - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-{{ .Arch }} + - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-{{ .Arch }} From 835d40b51caea06087c5492d8169c9275d5b2b60 Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sat, 12 Jun 2021 16:15:01 +0530 Subject: [PATCH 11/17] undo goreleaser for now --- .github/workflows/go.yml | 14 ++++++++++++++ .github/workflows/release.yml | 19 ++----------------- .goreleaser.yml | 29 ++++------------------------- Dockerfile | 34 +++++++++++++++++----------------- 4 files changed, 37 insertions(+), 59 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index b2fee89d..5c9969e6 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -25,3 +25,17 @@ jobs: uses: goreleaser/goreleaser-action@v1.3.1 with: args: release --snapshot --skip-publish --rm-dist --skip-sign + - name: Set up QEMU + uses: docker/setup-qemu-action@v1 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v1 + - name: Login to GitHub Packages Docker Registry + uses: docker/login-action@v1 + with: + registry: ghcr.io + username: ${{ github.repository_owner }} + password: ${{ secrets.CR_PAT }} + - name: Build + run: make docker-build + env: + IMAGE_NAMESPACE: ghcr.io/nslhb \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d3509fec..82174955 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -12,24 +12,12 @@ on: jobs: release: runs-on: ubuntu-latest - env: - DOCKER_CLI_EXPERIMENTAL: "enabled" steps: - uses: actions/checkout@v2 - name: Set up Go uses: actions/setup-go@v1 with: go-version: 1.15.5 - - name: Set up QEMU - uses: docker/setup-qemu-action@v1 - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 - - name: Login to GitHub Packages Docker Registry - uses: docker/login-action@v1 - with: - registry: ghcr.io - username: ${{ github.repository_owner }} - password: ${{ secrets.CR_PAT }} - name: Install kubebuilder run: | curl -L https://github.com/kubernetes-sigs/kubebuilder/releases/download/v2.3.1/kubebuilder_2.3.1_linux_amd64.tar.gz -o /tmp/kb.tgz @@ -37,11 +25,8 @@ jobs: - name: Run GoReleaser uses: goreleaser/goreleaser-action@v1.3.1 with: - args: release --skip-sign --rm-dist + args: release --skip-sign env: - GITHUB_TOKEN: ${{ secrets.CR_PAT }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} KUBEBUILDER_ASSETS: /tmp/kubebuilder_2.3.1_linux_amd64/bin/ - - name: Clear - if: always() - run: rm -f ${HOME}/.docker/config.json diff --git a/.goreleaser.yml b/.goreleaser.yml index 5aee4348..117ff2a4 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -3,7 +3,9 @@ before: - go test ./... builds: - - env: [CGO_ENABLED=0] + - + env: + - CGO_ENABLED=0 ldflags: - '-s -w -X "github.com/nslhb/terraform-k8s/version.Version={{ .Version }}" -X "github.com/nslhb/terraform-k8s/version.Prerelease="' goos: @@ -27,27 +29,4 @@ checksum: algorithm: sha256 changelog: - skip: true - - -dockers: - - image_templates: ["ghcr.io/nslhb/terraform-k8s:{{ .Version }}-{{ .Arch }}"] - ids: [example] - goarch: "{{ .Arch }}" - dockerfile: Dockerfile - use_buildx: true - build_flag_templates: - - --platform=linux/amd64 - - --label=org.opencontainers.image.title={{ .ProjectName }} - - --label=org.opencontainers.image.description={{ .ProjectName }} - - --label=org.opencontainers.image.url=https://github.com/nslhb/terraform-k8s - - --label=org.opencontainers.image.source=https://github.com/nslhb/terraform-k8s - - --label=org.opencontainers.image.version={{ .Version }} - - --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }} - - --label=org.opencontainers.image.revision={{ .FullCommit }} - - --label=org.opencontainers.image.licenses=MIT -docker_manifests: - - name_template: ghcr.io/nslhb/terraform-k8s:{{ .Version }} - image_templates: - - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-{{ .Arch }} - - ghcr.io/nslhb/terraform-k8s:{{ .Version }}-{{ .Arch }} + skip: true \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index f2523490..10996903 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,23 +1,23 @@ -## Build the terraform-k8s binary -#FROM golang:1.15 as builder -# -#WORKDIR /workspace -## Copy the Go Modules manifests -#COPY go.mod go.mod -#COPY go.sum go.sum -## cache deps before building and copying source so that we don't need to re-download as much -## and so that source changes don't invalidate our downloaded layer -#RUN go mod download -# -## Copy the go source -#COPY . . -# -## Build -#RUN CGO_ENABLED=0 GOOS=linux GO111MODULE=on go build -a -o terraform-k8s main.go +# Build the terraform-k8s binary +FROM golang:1.15 as builder + +WORKDIR /workspace +# Copy the Go Modules manifests +COPY go.mod go.mod +COPY go.sum go.sum +# cache deps before building and copying source so that we don't need to re-download as much +# and so that source changes don't invalidate our downloaded layer +RUN go mod download + +# Copy the go source +COPY . . + +# Build +RUN CGO_ENABLED=0 GOOS=linux GO111MODULE=on go build -a -o terraform-k8s main.go FROM alpine:3.12.1 WORKDIR / -COPY terraform-k8s /bin/terraform-k8s +COPY --from=builder /workspace/terraform-k8s /bin/terraform-k8s USER nobody:nobody ENTRYPOINT ["/bin/terraform-k8s"] From 1c1c47e92e09887c9dc5cff3a0b8cb0142e8e69c Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sun, 13 Jun 2021 12:05:34 +0530 Subject: [PATCH 12/17] fixed with retryable update --- .github/workflows/go.yml | 12 +- controllers/workspace_controller.go | 4 +- go.mod | 18 ++- go.sum | 204 ++++++++++++++++++---------- workspacehelper/workspace_helper.go | 21 ++- 5 files changed, 163 insertions(+), 96 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 5c9969e6..893b9991 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -19,12 +19,12 @@ jobs: run: | curl -L https://github.com/kubernetes-sigs/kubebuilder/releases/download/v2.3.1/kubebuilder_2.3.1_linux_amd64.tar.gz -o /tmp/kb.tgz tar zxf /tmp/kb.tgz -C /tmp/ - - name: Run GoReleaser - env: - KUBEBUILDER_ASSETS: /tmp/kubebuilder_2.3.1_linux_amd64/bin/ - uses: goreleaser/goreleaser-action@v1.3.1 - with: - args: release --snapshot --skip-publish --rm-dist --skip-sign +# - name: Run GoReleaser +# env: +# KUBEBUILDER_ASSETS: /tmp/kubebuilder_2.3.1_linux_amd64/bin/ +# uses: goreleaser/goreleaser-action@v1.3.1 +# with: +# args: release --snapshot --skip-publish --rm-dist --skip-sign - name: Set up QEMU uses: docker/setup-qemu-action@v1 - name: Set up Docker Buildx diff --git a/controllers/workspace_controller.go b/controllers/workspace_controller.go index a04a31c8..abc9c8e3 100644 --- a/controllers/workspace_controller.go +++ b/controllers/workspace_controller.go @@ -58,9 +58,9 @@ type WorkspaceReconciler struct { // +kubebuilder:rbac:groups=app.terraform.io,resources=workspaces,verbs=get;list;watch;create;update;patch;delete,namespace=terraform-k8s // +kubebuilder:rbac:groups=app.terraform.io,resources=workspaces/status,verbs=get;update;patch,namespace=terraform-k8s -func (r *WorkspaceReconciler) Reconcile(req reconcile.Request) (reconcile.Result, error) { +func (r *WorkspaceReconciler) Reconcile(ctx context.Context, req reconcile.Request) (reconcile.Result, error) { _ = context.Background() - return r.helper.Reconcile(req) + return r.helper.Reconcile(ctx, req) } func (r *WorkspaceReconciler) SetupWithManager(mgr ctrl.Manager) error { diff --git a/go.mod b/go.mod index e2e1a928..0f764675 100644 --- a/go.mod +++ b/go.mod @@ -4,19 +4,17 @@ go 1.15 require ( github.com/aws/aws-sdk-go-v2/config v1.3.0 - github.com/aws/aws-sdk-go-v2/service/sts v1.4.1 - github.com/beorn7/perks v1.0.1 // indirect - github.com/go-logr/logr v0.1.0 + github.com/go-logr/logr v0.3.0 github.com/hashicorp/go-tfe v0.15.0 github.com/hashicorp/terraform v0.14.3 - github.com/onsi/ginkgo v1.12.1 - github.com/onsi/gomega v1.10.1 + github.com/onsi/ginkgo v1.14.1 + github.com/onsi/gomega v1.10.2 github.com/stretchr/testify v1.6.1 - github.com/zclconf/go-cty v1.7.1 - k8s.io/api v0.18.6 - k8s.io/apimachinery v0.18.6 + github.com/zclconf/go-cty v1.8.3 + k8s.io/api v0.19.2 + k8s.io/apimachinery v0.19.2 k8s.io/client-go v10.0.0+incompatible - sigs.k8s.io/controller-runtime v0.6.3 + sigs.k8s.io/controller-runtime v0.7.2 ) // Pinned to kubernetes-1.16.2 @@ -40,4 +38,4 @@ require ( // k8s.io/sample-apiserver => k8s.io/sample-apiserver v0.0.0-20191016112829-06bb3c9d77c9 //) -replace k8s.io/client-go => k8s.io/client-go v0.18.6 +replace k8s.io/client-go => k8s.io/client-go v0.19.2 diff --git a/go.sum b/go.sum index 6a3abb9f..84216494 100644 --- a/go.sum +++ b/go.sum @@ -6,6 +6,7 @@ cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxK 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= +cloud.google.com/go v0.51.0/go.mod h1:hWtGJ6gnXH+KgDv+V0zFGDvpi07n3z8ZNj3T1RW0Gcw= cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4= cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M= cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc= @@ -36,14 +37,18 @@ github.com/Azure/azure-sdk-for-go v45.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9mo github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8= github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= github.com/Azure/go-autorest/autorest v0.9.0/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI= +github.com/Azure/go-autorest/autorest v0.9.6/go.mod h1:/FALq9T/kS7b5J5qsQ+RSTUdAmGFqi0vUdVNNx8q630= github.com/Azure/go-autorest/autorest v0.11.3/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw= github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEgQTmVqjGhiHBW7RJJEciWzS0= +github.com/Azure/go-autorest/autorest/adal v0.8.2/go.mod h1:ZjhuQClTqx435SRJ2iMlOxPYt3d2C/T/7TiQCVZSn3Q= github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg= github.com/Azure/go-autorest/autorest/azure/cli v0.4.0/go.mod h1:JljT387FplPzBA31vUcvsetLKF3pec5bdAxjVU4kI2s= github.com/Azure/go-autorest/autorest/date v0.1.0/go.mod h1:plvfp3oPSKwf2DNjlBjWF/7vwR+cUD/ELuzDCXwHUVA= +github.com/Azure/go-autorest/autorest/date v0.2.0/go.mod h1:vcORJHLJEh643/Ioh9+vPmf1Ij9AEBM5FuBIXLmIy0g= github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74= github.com/Azure/go-autorest/autorest/mocks v0.1.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0= github.com/Azure/go-autorest/autorest/mocks v0.2.0/go.mod h1:OTyCOPRA2IgIlWxVYxBee2F5Gr4kF2zd2J5cFRaIDN0= +github.com/Azure/go-autorest/autorest/mocks v0.3.0/go.mod h1:a8FDP3DYzQ4RYfVAxAN3SVSiiO77gL2j2ronKKP0syM= github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k= github.com/Azure/go-autorest/autorest/to v0.4.0/go.mod h1:fE8iZBn7LQR7zH/9XU2NcPR4o9jEImooCeWJcYV/zLE= github.com/Azure/go-autorest/autorest/validation v0.3.0/go.mod h1:yhLgjC0Wda5DYXl6JAsWyUe4KVNffhoDhG0zVzUMo3E= @@ -53,11 +58,13 @@ github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbt github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/Azure/go-ntlmssp v0.0.0-20180810175552-4a21cbd618b4/go.mod h1:chxPXzSsl7ZWRAuOIE23GDNzjWuZquvFlgA8xmpunjU= github.com/Azure/go-ntlmssp v0.0.0-20200615164410-66371956d46c/go.mod h1:chxPXzSsl7ZWRAuOIE23GDNzjWuZquvFlgA8xmpunjU= +github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= 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/ChrisTrenkamp/goxpath v0.0.0-20170922090931-c385f95c6022/go.mod h1:nuWgzSkT5PnyOd+272uUmV0dnAnAn42Mk7PiQC5VzN4= github.com/ChrisTrenkamp/goxpath v0.0.0-20190607011252-c5096ec8773d/go.mod h1:nuWgzSkT5PnyOd+272uUmV0dnAnAn42Mk7PiQC5VzN4= github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ= +github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/PuerkitoBio/purell v1.0.0/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/purell v1.1.0/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= @@ -70,7 +77,9 @@ github.com/agext/levenshtein v1.2.2 h1:0S/Yg6LYmFJ5stwQeRp6EeOcCbj7xiqQSdNelsXva github.com/agext/levenshtein v1.2.2/go.mod h1:JEDfjyjHDjOF/1e4FlBE/PkbqA9OfWu2ki2W0IB5558= github.com/agnivade/levenshtein v1.0.1/go.mod h1:CURSv5d9Uaml+FovSIICkLbAUZ9S4RqaHDIsdSBg7lM= 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/aliyun/alibaba-cloud-sdk-go v0.0.0-20190329064014-6e358769c32a/go.mod h1:T9M45xf79ahXVelWoOBmH0y4aC1t5kXO5BxwyakgIGA= github.com/aliyun/aliyun-oss-go-sdk v0.0.0-20190103054945-8205d1f41e70/go.mod h1:T/Aws4fEfogEE9v+HPhhw+CntffsBHJ8nXQCwKr0/g8= github.com/aliyun/aliyun-tablestore-go-sdk v4.1.2+incompatible/go.mod h1:LDQHRZylxvcg8H7wBIDfvO5g/cy4/sz1iucBlc2l3Jw= @@ -85,6 +94,8 @@ github.com/apparentlymart/go-textseg v1.0.0 h1:rRmlIsPEEhUTIKQb7T++Nz/A5Q6C9IuX2 github.com/apparentlymart/go-textseg v1.0.0/go.mod h1:z96Txxhf3xSFMPmb5X/1W05FF/Nj9VFpLOpjS5yuumk= github.com/apparentlymart/go-textseg/v12 v12.0.0 h1:bNEQyAGak9tojivJNkoqWErVCQbjdL7GzRt3F8NvfJ0= github.com/apparentlymart/go-textseg/v12 v12.0.0/go.mod h1:S/4uRK2UtaQttw1GenVJEynmyUenKwP++x/+DdGV/Ec= +github.com/apparentlymart/go-textseg/v13 v13.0.0 h1:Y+KvPE1NYz0xl601PVImeQfFyEy6iT90AvPUL1NNfNw= +github.com/apparentlymart/go-textseg/v13 v13.0.0/go.mod h1:ZK2fH7c4NqDTLtiYLvIkEghdlcqw7yxLeM89kiTRPUo= github.com/apparentlymart/go-userdirs v0.0.0-20200915174352-b0c018a67c13/go.mod h1:7kfpUbyCdGJ9fDRCp3fopPQi5+cKNHgTE4ZuNrO71Cw= github.com/apparentlymart/go-versions v1.0.1 h1:ECIpSn0adcYNsBfSRwdDdz9fWlL+S/6EUd9+irwkBgU= github.com/apparentlymart/go-versions v1.0.1/go.mod h1:YF5j7IQtrOAOnsGkniupEA5bfCjzd7i14yu0shZavyM= @@ -126,6 +137,10 @@ github.com/blang/semver v3.5.0+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnweb github.com/bmatcuk/doublestar v1.1.5/go.mod h1:wiQtGV+rzVYxB7WIlirSN++5HPtPlXEo9MEoZQC/PmE= github.com/boltdb/bolt v1.3.1/go.mod h1:clJnj/oiGkjum5o1McbSZDSLxVThjynRyGBgiAx27Ps= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= +github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= +github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= +github.com/cespare/xxhash/v2 v2.1.1 h1:6MnRN8NT7+YBpUIWxHtefFZOKTAPgGjpQSxqLNn0+qY= +github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cheggaaa/pb v1.0.27/go.mod h1:pQciLPpbU0oxA0h+VJYYLxO+XeDQb5pZijXscXHm81s= 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= @@ -134,8 +149,8 @@ github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDk github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= github.com/coreos/bbolt v1.3.0/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= +github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= @@ -143,17 +158,16 @@ github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7 github.com/coreos/go-systemd v0.0.0-20181012123002-c6f51f82210d/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= -github.com/coreos/pkg v0.0.0-20180108230652-97fdf19511ea/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= +github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/davecgh/go-spew v0.0.0-20151105211317-5215b55f46b2/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= 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/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8= -github.com/docker/docker v0.7.3-0.20190327010347-be7ac8be2ae0/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-units v0.3.3/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/docker/spdystream v0.0.0-20160310174837-449fdfce4d96/go.mod h1:Qh8CwZgvJUkLughtfhJv5dyTYa91l1fOUCrgjqmcifM= @@ -187,11 +201,15 @@ github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9 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-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= -github.com/go-logr/logr v0.1.0 h1:M1Tv3VzNlEHg6uyACnRdtrploV2P7wZqH8BoQMtz0cg= +github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas= -github.com/go-logr/zapr v0.1.0 h1:h+WVe9j6HAA01niTJPA/kKH0i7e0rLZBCwauQFcRE54= -github.com/go-logr/zapr v0.1.0/go.mod h1:tabnROwaDl0UNxkVeFRbY8bwB37GwRv0P8lg6aAiEnk= +github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= +github.com/go-logr/logr v0.3.0 h1:q4c+kbcR0d5rSurhBR8dIgieOaYpXtsdTYfx22Cu6rs= +github.com/go-logr/logr v0.3.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= +github.com/go-logr/zapr v0.2.0 h1:v6Ji8yBW77pva6NkJKQdHLAJKrIJKRHz0RXwPqCHSR4= +github.com/go-logr/zapr v0.2.0/go.mod h1:qhKdvif7YF5GI9NWEpyxTSSBdGmzkNguibrdCNVPunU= github.com/go-openapi/analysis v0.0.0-20180825180245-b006789cd277/go.mod h1:k70tL6pCuVxPJOHXQ+wIac1FUrvNkHolPie/cLEU6hI= github.com/go-openapi/analysis v0.17.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik= github.com/go-openapi/analysis v0.18.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik= @@ -313,10 +331,9 @@ github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+ 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.0.0-20170729233727-0c5108395e2d/go.mod h1:sJBsCZ4ayReDTBIg8b9dl28c5xFWyhBTVRp3pOg5EKY= -github.com/googleapis/gnostic v0.1.0/go.mod h1:sJBsCZ4ayReDTBIg8b9dl28c5xFWyhBTVRp3pOg5EKY= -github.com/googleapis/gnostic v0.3.1 h1:WeAefnSUHlBb0iJKwxFDZdbfGwkd7xRNuV+IpXMJhYk= -github.com/googleapis/gnostic v0.3.1/go.mod h1:on+2t9HRStVgn95RSsFWFz+6Q0Snyqv1awfrALZdbtU= -github.com/gophercloud/gophercloud v0.1.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEoIEcSTewFxm1c5g8= +github.com/googleapis/gnostic v0.4.1/go.mod h1:LRhVm6pbyptWbWbuZ38d1eyptfvIytN3ir6b65WBswg= +github.com/googleapis/gnostic v0.5.1 h1:A8Yhf6EtqTv9RMsU6MQTyrtV1TjWlR6xU9BsZIwuTCM= +github.com/googleapis/gnostic v0.5.1/go.mod h1:6U4PtQXGIEt/Z3h5MAT7FNofLnw9vXk2cUuW7uA/OeU= github.com/gophercloud/gophercloud v0.6.1-0.20191122030953-d8ac278c1c9d/go.mod h1:ozGNgr9KYOVATV5jsgHl/ceCDXGuguqOZAzoQ/2vcNM= github.com/gophercloud/gophercloud v0.10.1-0.20200424014253-c3bfe50899e5/go.mod h1:gmC5oQqMDOMO1t1gq5DquX/yAU808e/4mzjjDA76+Ss= github.com/gophercloud/utils v0.0.0-20200423144003-7c72efc7435d/go.mod h1:ehWUbLQJPqS0Ep+CxeD559hsm9pthPXadJNKwZkp43w= @@ -328,6 +345,7 @@ github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmg github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.8.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= +github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/hashicorp/aws-sdk-go-base v0.6.0/go.mod h1:2fRjWDv3jJBeN6mVWFHV6hFTNeFBx2gpDLQaZNxUVAY= github.com/hashicorp/consul v0.0.0-20171026175957-610f3c86a089/go.mod h1:mFrjN1mfidgJfYP1xrJCF+AfRhr6Eaqhb2+sfyn/OOI= @@ -354,8 +372,6 @@ github.com/hashicorp/go-slug v0.4.1 h1:/jAo8dNuLgSImoLXaX7Od7QB4TfYCVPam+OpAt5bZ github.com/hashicorp/go-slug v0.4.1/go.mod h1:I5tq5Lv0E2xcNXNkmx7BSfzi1PsJ2cNjs3cC3LwyhK8= github.com/hashicorp/go-sockaddr v0.0.0-20180320115054-6d291a969b86/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= github.com/hashicorp/go-tfe v0.8.1/go.mod h1:XAV72S4O1iP8BDaqiaPLmL2B4EE6almocnOn8E8stHc= -github.com/hashicorp/go-tfe v0.11.1 h1:BD0HlSTcptjHkIYLgZ2+mgfyfXRBXnkkHoJpzWP4vkI= -github.com/hashicorp/go-tfe v0.11.1/go.mod h1:XAV72S4O1iP8BDaqiaPLmL2B4EE6almocnOn8E8stHc= github.com/hashicorp/go-tfe v0.15.0 h1:vdnz1NjOhvmap+cj8iPsL8SbS4iFFVuNYFkGpF5SdoA= github.com/hashicorp/go-tfe v0.15.0/go.mod h1:c8glB5p6XzocEWLNkuy5RxcjqN5X2PpY6NF3f2W6nIo= github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= @@ -389,8 +405,9 @@ github.com/hashicorp/yamux v0.0.0-20181012175058-2f1d1f20f75d/go.mod h1:+NfK9FKe github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= -github.com/imdario/mergo v0.3.9 h1:UauaLniWCFHWd+Jp9oCEkTBj8VO/9DKg3PV3VCNMDIg= github.com/imdario/mergo v0.3.9/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= +github.com/imdario/mergo v0.3.10 h1:6q5mVkdH/vYmqngx7kZQTjJ5HRsx+ImorDIEQ+beJgc= +github.com/imdario/mergo v0.3.10/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/jhump/protoreflect v1.6.0/go.mod h1:eaTn3RZAmMBcV0fifFvlm6VHNz3wSkYyXYWUh7ymB74= github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= @@ -403,7 +420,6 @@ github.com/json-iterator/go v0.0.0-20180612202835-f2b4162afba3/go.mod h1:+SdeFBv github.com/json-iterator/go v0.0.0-20180701071628-ab8a2e0c74be/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.8/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.10 h1:Kz6Cvnvv2wGdaG/V8yMvfkmNiXq9Ya2KUv4rouJJr68= github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= @@ -415,9 +431,11 @@ github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvW github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= 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/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= -github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= +github.com/kr/pretty v0.2.0 h1:s5hAObm+yFO5uHYt5dYjxi2rXrsnmRpJx4OYvIWUaQs= +github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/pty v1.1.5/go.mod h1:9r2w37qlBe7rQ6e1fg1S/9xpWHSnaqNdHD3WcMdbPDA= github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE= @@ -452,8 +470,9 @@ github.com/mattn/go-isatty v0.0.5/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hd github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.4/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-shellwords v1.0.4/go.mod h1:3xCvwCdWdlDJUrvuMn7Wuy9eWs4pE8vqg+NOMyg4B2o= -github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU= 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 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= +github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= github.com/miekg/dns v1.0.8/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/mitchellh/cli v1.1.0/go.mod h1:xcISNoH86gajksDmfB23e/pu+B+GeFRMYmoHXxx3xhI= github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db/go.mod h1:l0dey0ia/Uv7NcFFVbCLtqEBQbrT4OCwCSKTEv6enCw= @@ -475,6 +494,7 @@ github.com/mitchellh/prefixedio v0.0.0-20190213213902-5733675afd51/go.mod h1:kB1 github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/mitchellh/reflectwalk v1.0.1 h1:FVzMWA5RllMAKIdUSC8mdWo3XtwoecrH79BY70sEEpE= github.com/mitchellh/reflectwalk v1.0.1/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= +github.com/moby/term v0.0.0-20200312100748-672ec06f55cd/go.mod h1:DdlQx2hp0Ss5/fLikoLlEeIYiATotOjgB//nb973jeo= 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= @@ -491,20 +511,23 @@ github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d/go.mod h1:YUTz3bUH github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= +github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo= 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.8.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.11.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.12.1 h1:mFwc4LvZ0xpSvDZ3E+k8Yte0hLOMxXUlP+yXtJqkYfQ= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.14.1 h1:jMU0WaQrP0a/YAEq8eJmJKjBoMs+pClEr1vDMlM/Do4= +github.com/onsi/ginkgo v1.14.1/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= github.com/onsi/gomega v0.0.0-20190113212917-5533ce8a0da3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.5.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.1 h1:o0+MgICZLuZ7xjH7Vx6zS/zcu93/BEp1VwkIW1mEXCE= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= +github.com/onsi/gomega v1.10.2 h1:aY/nuoWlKJud2J6U0E3NWsjlg+0GtwXxgEqthRdzlcs= +github.com/onsi/gomega v1.10.2/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/packer-community/winrmcp v0.0.0-20180921211025-c76d91c1e7db/go.mod h1:f6Izs6JvFTdnRbziASagjZ2vmf55NSIkC/weStxCHqk= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= @@ -523,40 +546,50 @@ github.com/posener/complete v1.2.1/go.mod h1:6gapUrK/U1TAN7ciCoNRIdVC5sbdBTUh1DK 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-0.20190127221311-3c4408c8b829/go.mod h1:p2iRAGwDERtqlqzRXnrOVns+ignqQo//hLXqYxZYVNs= -github.com/prometheus/client_golang v1.0.0 h1:vrDKnkGzuGvhNAL56c7DBz29ZL+KxnoR0x7enabFceM= +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 h1:NTGy1Ja9pByO+xAeH/qiWnLrKtr3hJPNjaVUwnjpdpA= +github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/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 h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M= 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.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.4.1 h1:K0MGApIoQvMw27RTdJkPbr3JZ7DNbtxQNyi5STVM6Kw= +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 h1:RyRA7RzGXQZiW+tGMr7sxa85G1z0yOpM1qq5c8lNawc= +github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/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.0.11 h1:DhHlBtkHWPYi8O2y31JkK0TF+DGM+51OopZjH/Ia5qI= -github.com/prometheus/procfs v0.0.11/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= +github.com/prometheus/procfs v0.1.3 h1:F0+tqvhOksq22sc6iCHF5WGlWjdwj92p0udFh1VFBS8= +github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= +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/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= -github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= +github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/sergi/go-diff v1.0.0 h1:Kpca3qRNrduNnOQeazBd0ysaKrUJiIuISHxogkT9RPQ= github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= +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.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= +github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/goconvey v0.0.0-20180222194500-ef6db91d284a/go.mod h1:XDJAKZRPZ1CvBcN2aX5YOUTYGHki24fSF0Iv48Ibg0s= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= +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 h1:5jhuqJyZCZf2JRofRvN/nIFgIWNzPa3/Vz8mYylgbWc= github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= +github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE= github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= @@ -564,10 +597,10 @@ github.com/spf13/pflag v1.0.2/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnIn 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.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= +github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= +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/testify v0.0.0-20151208002404-e3a8ff8ce365/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= @@ -576,16 +609,16 @@ github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81P github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/svanharmelen/jsonapi v0.0.0-20180618144545-0c0828c3f16d h1:Z4EH+5EffvBEhh37F0C0DnpklTMh00JOkjW5zK3ofBI= github.com/svanharmelen/jsonapi v0.0.0-20180618144545-0c0828c3f16d/go.mod h1:BSTlc8jOjh0niykqEGVXOLXdi9o0r0kR8tCYiMvjFgw= github.com/tencentcloud/tencentcloud-sdk-go v3.0.82+incompatible/go.mod h1:0PfYow01SHPMhKY31xa+EFz2RStxIqj6JFAJS+IkCi4= github.com/tencentyun/cos-go-sdk-v5 v0.0.0-20190808065407-f07404cefc8c/go.mod h1:wk2XFUg6egk4tSDNZtXeKfe2G6690UVyt163PuUxBZk= github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tmc/grpc-websocket-proxy v0.0.0-20171017195756-830351dc03c6/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= +github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tombuildsstuff/giovanni v0.12.0/go.mod h1:qJ5dpiYWkRsuOSXO8wHbee7+wElkLNfWVolcf59N84E= github.com/ugorji/go v0.0.0-20180813092308-00b869d2f4a5/go.mod h1:hnLbHMwcvSihnDhEfx2/BzKp2xb0Y+ErdfYcrs9tkJQ= -github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= +github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= github.com/ulikunitz/xz v0.5.8/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= github.com/vektah/gqlparser v1.1.2/go.mod h1:1ycwN7Ij5njmMkPPAOaRFY4rET2Enx7IkVv3vaXspKw= @@ -604,11 +637,14 @@ github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9dec github.com/zclconf/go-cty v1.0.0/go.mod h1:xnAOWiHeOqg2nWS62VtQ7pbOu17FtxJNW8RLEih+O3s= github.com/zclconf/go-cty v1.1.0/go.mod h1:xnAOWiHeOqg2nWS62VtQ7pbOu17FtxJNW8RLEih+O3s= github.com/zclconf/go-cty v1.2.0/go.mod h1:hOPWgoHbaTUnI5k4D2ld+GRpFJSCe6bCM7m1q/N4PQ8= -github.com/zclconf/go-cty v1.7.1 h1:AvsC01GMhMLFL8CgEYdHGM+yLnnDOwhPAYcgTkeF0Gw= github.com/zclconf/go-cty v1.7.1/go.mod h1:VDR4+I79ubFBGm1uJac1226K5yANQFHeauxPBoP54+o= +github.com/zclconf/go-cty v1.8.3 h1:48gwZXrdSADU2UW9eZKHprxAI7APZGW9XmExpJpSjT0= +github.com/zclconf/go-cty v1.8.3/go.mod h1:vVKLxnk3puL4qRAv72AO+W99LUD4da90g3uUAzyuvAk= github.com/zclconf/go-cty-yaml v1.0.2/go.mod h1:IP3Ylp0wQpYm50IHK8OZWKMu6sPJIUgKa8XhiVHura0= +go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg= +go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ= +go.etcd.io/etcd v0.5.0-alpha.5.0.20200819165624-17cef6e3e9d5/go.mod h1:skWido08r9w6Lq/w70DO5XYIKMu4QFu1+4VsqLQuJy8= go.mongodb.org/mongo-driver v1.0.3/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM= go.mongodb.org/mongo-driver v1.1.1/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM= go.mongodb.org/mongo-driver v1.1.2/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM= @@ -618,16 +654,22 @@ go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.4.0 h1:cxzIVoETapQEqDhQu3QfnvXAV4AlzcvUCxkVUFw3+EU= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/multierr v1.1.0 h1:HoEmRHQPVSqub6w2z2d2EOVs2fjyFRGyofhKuyDq0QI= +go.uber.org/atomic v1.6.0 h1:Ezj3JGmsOnG1MoRWQkPBsKLe9DwWD9QeXzTRzzldNVk= +go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= +go.uber.org/goleak v1.1.10 h1:z+mqJhf6ss6BSfSM671tgKyZBFPTTJM+HLxnhPC3wu0= +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.5.0 h1:KCa4XfM8CWFCpxXRGok+Q0SS/0XBhMDbHHGABQLvD2A= +go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= +go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee h1:0mgffUl7nfd+FpvXMVz4IDEaUSmT1ysygQC7qYo7sG4= +go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= +go.uber.org/zap v1.8.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= -go.uber.org/zap v1.10.0 h1:ORx85nbTijNz8ljznvCMR1ZBIPKFn3jQrag10X2AsuM= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= +go.uber.org/zap v1.15.0 h1:ZZCA22JRF2gQE5FoNmhmrf7jeJJ2uhqDUNRYKm8dvmM= +go.uber.org/zap v1.15.0/go.mod h1:Mb2vm2krFEG5DV0W9qcHBYFtp/Wku1cvYaqPsS/WYfc= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20190211182817-74369b46fc67/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190219172222-a4c6cb3142f2/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190222235706-ffb98f73852f/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= @@ -639,7 +681,7 @@ golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20190617133340-57b3e21c3d56/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191202143827-86a70503ff7e/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200220183623-bac4c82f6975/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -663,6 +705,7 @@ golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHl golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs= golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= +golang.org/x/lint v0.0.0-20200302205851-738671d3881b h1:Wh+f8QHJXR411sJR8/vRBTZ7YapZaRvUcLFFJhusH0k= golang.org/x/lint v0.0.0-20200302205851-738671d3881b/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= @@ -691,6 +734,7 @@ golang.org/x/net v0.0.0-20190320064053-1272bf9dcd53/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= 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-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= 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= @@ -699,7 +743,6 @@ golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190812203447-cdfb69ac37fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20191004110552-13f9640d40b9/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191009170851-d66e71096ffb/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191126235420-ef20fe5d7933/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -742,8 +785,6 @@ golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190209173611-3b5209105503/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190221075227-b4e8571b14e0/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -763,7 +804,6 @@ golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7w 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-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191128015809-6d18c012aee9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -780,7 +820,10 @@ golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 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-20200622214017-ed371f2e16b4/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-20200930185726-fdedc70b468f h1:+Nyd8tzPX9R7BWHguqsrbFdRx3WQ/1ib8I44HXV5yTA= @@ -791,13 +834,15 @@ golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20181227161524-e6919f6577db/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= -golang.org/x/text v0.3.3 h1:cokOdA+Jmi5PJGXLlLllQSgYigAEfHXJAERHVMaCc2k= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.3.5 h1:i6eZZ+zk0SOf0xgBpEpPD18qWcJda6q1sxt3S0kzyUQ= +golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= 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 h1:/5xXl8Y5W96D+TtHSlonuFqGHIWVuyCkGJLwGh9JJFs= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.0.0-20200630173020-3af7569d3a1e h1:EHBhcS0mlXEAVwNyO2dLfjToGsyY4j24pTs2ScHnX7s= +golang.org/x/time v0.0.0-20200630173020-3af7569d3a1e/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-20181011042414-1f849cf54d09/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= @@ -815,11 +860,14 @@ golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgw golang.org/x/tools v0.0.0-20190614205625-5aca471b1d59/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190617190820-da514acc4774/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-20190920225731-5eefd052ad72/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-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/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-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -842,19 +890,21 @@ golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWc golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= +golang.org/x/tools v0.0.0-20200616133436-c1934b75d054/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= +golang.org/x/tools v0.0.0-20201028111035-eafbe7b904eb h1:KVWk3RW1AZlxWum4tYqegLgwJHb5oouozcGM8HfNQaw= golang.org/x/tools v0.0.0-20201028111035-eafbe7b904eb/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= 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= -gomodules.xyz/jsonpatch/v2 v2.0.1 h1:xyiBuvkD2g5n7cYzx6u2sxQvsAy4QJsZFCzGVdzOXZ0= -gomodules.xyz/jsonpatch/v2 v2.0.1/go.mod h1:IhYNNY4jnS53ZnfE4PAmpKtDpTCj1JFXc+3mwe7XcUU= +gomodules.xyz/jsonpatch/v2 v2.1.0 h1:Phva6wqu+xR//Njw6iorylFFgn/z547tw5Ne3HZPQ+k= +gomodules.xyz/jsonpatch/v2 v2.1.0/go.mod h1:IhYNNY4jnS53ZnfE4PAmpKtDpTCj1JFXc+3mwe7XcUU= 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= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -913,9 +963,9 @@ google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d/go.mod h1:FWY/as6D google.golang.org/grpc v1.8.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= 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.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= @@ -958,63 +1008,67 @@ gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bl 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.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.7/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 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776 h1:tQIYjPdBoyREyB9XMu+nnTclpTYkz2zFM+lzLJFO4gQ= +gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= +gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= 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= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= +honnef.co/go/tools v0.0.1-2020.1.4 h1:UoveltGrhghAA7ePc+e+QYDHXrBps2PqFZiHkGR/xK8= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= k8s.io/api v0.0.0-20190620084959-7cf5895f2711/go.mod h1:TBhBqb1AWbBQbW3XRusr7n7E4v2+5ZY8r8sAMnyFC5A= -k8s.io/api v0.18.6 h1:osqrAXbOQjkKIWDTjrqxWQ3w0GkKb1KA1XkUGHHYpeE= -k8s.io/api v0.18.6/go.mod h1:eeyxr+cwCjMdLAmr2W3RyDI0VvTawSg/3RFFBEnmZGI= -k8s.io/apiextensions-apiserver v0.18.6 h1:vDlk7cyFsDyfwn2rNAO2DbmUbvXy5yT5GE3rrqOzaMo= -k8s.io/apiextensions-apiserver v0.18.6/go.mod h1:lv89S7fUysXjLZO7ke783xOwVTm6lKizADfvUM/SS/M= +k8s.io/api v0.19.2 h1:q+/krnHWKsL7OBZg/rxnycsl9569Pud76UJ77MvKXms= +k8s.io/api v0.19.2/go.mod h1:IQpK0zFQ1xc5iNIQPqzgoOwuFugaYHK4iCknlAQP9nI= +k8s.io/apiextensions-apiserver v0.19.2 h1:oG84UwiDsVDu7dlsGQs5GySmQHCzMhknfhFExJMz9tA= +k8s.io/apiextensions-apiserver v0.19.2/go.mod h1:EYNjpqIAvNZe+svXVx9j4uBaVhTB4C94HkY3w058qcg= k8s.io/apimachinery v0.0.0-20190612205821-1799e75a0719/go.mod h1:I4A+glKBHiTgiEjQiCCQfCAIcIMFGt291SmsvcrFzJA= k8s.io/apimachinery v0.0.0-20190913080033-27d36303b655/go.mod h1:nL6pwRT8NgfF8TT68DBI8uEePRt89cSvoXUVqbkWHq4= -k8s.io/apimachinery v0.18.6 h1:RtFHnfGNfd1N0LeSrKCUznz5xtUP1elRGvHJbL3Ntag= -k8s.io/apimachinery v0.18.6/go.mod h1:OaXp26zu/5J7p0f92ASynJa1pZo06YlV9fG7BoWbCko= -k8s.io/apiserver v0.18.6/go.mod h1:Zt2XvTHuaZjBz6EFYzpp+X4hTmgWGy8AthNVnTdm3Wg= -k8s.io/client-go v0.18.6 h1:I+oWqJbibLSGsZj8Xs8F0aWVXJVIoUHWaaJV3kUN/Zw= -k8s.io/client-go v0.18.6/go.mod h1:/fwtGLjYMS1MaM5oi+eXhKwG+1UHidUEXRh6cNsdO0Q= -k8s.io/code-generator v0.18.6/go.mod h1:TgNEVx9hCyPGpdtCWA34olQYLkh3ok9ar7XfSsr8b6c= -k8s.io/component-base v0.18.6/go.mod h1:knSVsibPR5K6EW2XOjEHik6sdU5nCvKMrzMt2D4In14= +k8s.io/apimachinery v0.19.2 h1:5Gy9vQpAGTKHPVOh5c4plE274X8D/6cuEiTO2zve7tc= +k8s.io/apimachinery v0.19.2/go.mod h1:DnPGDnARWFvYa3pMHgSxtbZb7gpzzAZ1pTfaUNDVlmA= +k8s.io/apiserver v0.19.2/go.mod h1:FreAq0bJ2vtZFj9Ago/X0oNGC51GfubKK/ViOKfVAOA= +k8s.io/client-go v0.19.2 h1:gMJuU3xJZs86L1oQ99R4EViAADUPMHHtS9jFshasHSc= +k8s.io/client-go v0.19.2/go.mod h1:S5wPhCqyDNAlzM9CnEdgTGV4OqhsW3jGO1UM1epwfJA= +k8s.io/code-generator v0.19.2/go.mod h1:moqLn7w0t9cMs4+5CQyxnfA/HV8MF6aAVENF+WZZhgk= +k8s.io/component-base v0.19.2 h1:jW5Y9RcZTb79liEhW3XDVTW7MuvEGP0tQZnfSX6/+gs= +k8s.io/component-base v0.19.2/go.mod h1:g5LrsiTiabMLZ40AR6Hl45f088DevyGY+cCE2agEIVo= k8s.io/gengo v0.0.0-20190128074634-0689ccc1d7d6/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0= -k8s.io/gengo v0.0.0-20200114144118-36b2048a9120/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0= +k8s.io/gengo v0.0.0-20200413195148-3a45101e95ac/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0= +k8s.io/gengo v0.0.0-20200428234225-8167cfdcfc14/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0= k8s.io/klog v0.0.0-20181102134211-b9b56d5dfc92/go.mod h1:Gq+BEi5rUBO/HRz0bTSXDUcqjScdoY3a9IHpCEIOOfk= -k8s.io/klog v0.3.0/go.mod h1:Gq+BEi5rUBO/HRz0bTSXDUcqjScdoY3a9IHpCEIOOfk= k8s.io/klog v0.3.1/go.mod h1:Gq+BEi5rUBO/HRz0bTSXDUcqjScdoY3a9IHpCEIOOfk= +k8s.io/klog v0.4.0 h1:lCJCxf/LIowc2IGS9TPjWDyXY4nOmdGdfcwwDQCOURQ= k8s.io/klog v0.4.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I= -k8s.io/klog v1.0.0 h1:Pt+yjF5aB1xDSVbau4VsWe+dQNzA0qv1LlXdC2dF6Q8= -k8s.io/klog v1.0.0/go.mod h1:4Bi6QPql/J/LkTDqv7R/cd3hPo4k2DG6Ptcz060Ez5I= -k8s.io/klog/v2 v2.0.0 h1:Foj74zO6RbjjP4hBEKjnYtjjAhGg4jNynUdYF6fJrok= k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE= +k8s.io/klog/v2 v2.2.0 h1:XRvcwJozkgZ1UQJmfMGpvRthQHOvihEhYtDfAaxMz/A= +k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y= k8s.io/kube-openapi v0.0.0-20190228160746-b3a7cee44a30/go.mod h1:BXM9ceUBTj2QnfH2MK1odQs778ajze1RxcmP6S8RVVc= k8s.io/kube-openapi v0.0.0-20190816220812-743ec37842bf/go.mod h1:1TqjTSzOxsLGIKfj0lK8EeCP7K1iUG65v09OM0/WG5E= -k8s.io/kube-openapi v0.0.0-20200410145947-61e04a5be9a6 h1:Oh3Mzx5pJ+yIumsAD0MOECPVeXsVot0UkiaCGVyfGQY= -k8s.io/kube-openapi v0.0.0-20200410145947-61e04a5be9a6/go.mod h1:GRQhZsXIAJ1xR0C9bd8UpWHZ5plfAS9fzPjJuQ6JL3E= -k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89/go.mod h1:sZAwmy6armz5eXlNoLmJcl4F1QuKu7sr+mFQ0byX7Ew= +k8s.io/kube-openapi v0.0.0-20200805222855-6aeccd4b50c6 h1:+WnxoVtG8TMiudHBSEtrVL1egv36TkkJm+bA8AxicmQ= +k8s.io/kube-openapi v0.0.0-20200805222855-6aeccd4b50c6/go.mod h1:UuqjUnNftUyPE5H64/qeyjQoUZhGpeFDVdxjTeEVN2o= k8s.io/utils v0.0.0-20200411171748-3d5a2fe318e4/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= -k8s.io/utils v0.0.0-20200603063816-c1c6865ac451 h1:v8ud2Up6QK1lNOKFgiIVrZdMg7MpmSnvtrOieolJKoE= -k8s.io/utils v0.0.0-20200603063816-c1c6865ac451/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= +k8s.io/utils v0.0.0-20200729134348-d5654de09c73/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= +k8s.io/utils v0.0.0-20200912215256-4140de9c8800 h1:9ZNvfPvVIEsp/T1ez4GQuzCcCTEQWhovSofhqR73A6g= +k8s.io/utils v0.0.0-20200912215256-4140de9c8800/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= 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.7/go.mod h1:PHgbrJT7lCHcxMU+mDHEm+nx46H4zuuHZkDP6icnhu0= -sigs.k8s.io/controller-runtime v0.6.3 h1:SBbr+inLPEKhvlJtrvDcwIpm+uhDvp63Bl72xYJtoOE= -sigs.k8s.io/controller-runtime v0.6.3/go.mod h1:WlZNXcM0++oyaQt4B7C2lEE5JYRs8vJUzRP4N4JpdAY= +sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.0.9/go.mod h1:dzAXnQbTRyDlZPJX2SUPEqvnB+j7AJjtlox7PEwigU0= +sigs.k8s.io/controller-runtime v0.7.2 h1:gD2JZp0bBLLuvSRYVNvox+bRCz1UUUxKDjPUCb56Ukk= +sigs.k8s.io/controller-runtime v0.7.2/go.mod h1:pJ3YBrJiAqMAZKi6UVGuE98ZrroV1p+pIhoHsMm9wdU= sigs.k8s.io/structured-merge-diff v0.0.0-20190525122527-15d366b2352e h1:4Z09Hglb792X0kfOBBJUPFEyvVfQWrYT/l8h5EKA6JQ= sigs.k8s.io/structured-merge-diff v0.0.0-20190525122527-15d366b2352e/go.mod h1:wWxsB5ozmmv/SG7nM11ayaAW51xMvak/t1r0CSlcokI= -sigs.k8s.io/structured-merge-diff/v3 v3.0.0-20200116222232-67a7b8c61874/go.mod h1:PlARxl6Hbt/+BC80dRLi1qAmnMqwqDg62YvvVkZjemw= -sigs.k8s.io/structured-merge-diff/v3 v3.0.0 h1:dOmIZBMfhcHS09XZkMyUgkq5trg3/jRyJYFZUiaOp8E= -sigs.k8s.io/structured-merge-diff/v3 v3.0.0/go.mod h1:PlARxl6Hbt/+BC80dRLi1qAmnMqwqDg62YvvVkZjemw= +sigs.k8s.io/structured-merge-diff/v4 v4.0.1 h1:YXTMot5Qz/X1iBRJhAt+vI+HVttY0WkSqqhKxQ0xVbA= +sigs.k8s.io/structured-merge-diff/v4 v4.0.1/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw= sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o= sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q= sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc= diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index 96433791..a956c848 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -4,6 +4,7 @@ import ( "context" "fmt" "io/ioutil" + "k8s.io/client-go/util/retry" "os" "reflect" "time" @@ -138,7 +139,7 @@ func (r *WorkspaceHelper) reconcileWorkspace(instance *appv1alpha1.Workspace) er if instance.Status.WorkspaceID != workspaceID { instance.Status.WorkspaceID = workspaceID instance.Status.Outputs = []*appv1alpha1.OutputStatus{} - if err := r.client.Status().Update(context.TODO(), instance); err != nil { + if err := retryableUpdateStatus(r.client, instance); err != nil { r.reqLogger.Error(err, "Failed to update output status") return err } @@ -242,7 +243,7 @@ func (r *WorkspaceHelper) processFinishedRun(instance *appv1alpha1.Workspace) er if !reflect.DeepEqual(outputs, instance.Status.Outputs) { instance.Status.Outputs = outputs - err := r.client.Status().Update(context.TODO(), instance) + err := retryableUpdateStatus(r.client, instance) if err != nil { r.reqLogger.Error(err, "Failed to update output status") return err @@ -420,7 +421,7 @@ func (r *WorkspaceHelper) startRun(instance *appv1alpha1.Workspace) error { // Note: // The Controller will requeue the Request to be processed again if the returned error is non-nil or // Result.Requeue is true, otherwise upon completion it will remove the work from the queue. -func (r *WorkspaceHelper) Reconcile(request reconcile.Request) (reconcile.Result, error) { +func (r *WorkspaceHelper) Reconcile(ctx context.Context, request reconcile.Request) (reconcile.Result, error) { // Get instance, check if org and secrets exist or not instance, err := r.initializeReconciliation(request) if err != nil { @@ -523,3 +524,17 @@ func (r *WorkspaceHelper) updateAwsCredentials(instance *appv1alpha1.Workspace) } return nil } + +func retryableUpdateStatus(client client.Client, w *appv1alpha1.Workspace) error { + retryErr := retry.RetryOnConflict(retry.DefaultRetry, func() error { + temp := &appv1alpha1.Workspace{} + err := client.Get(context.TODO(), types.NamespacedName{Name: w.Name, Namespace: w.Namespace}, temp) + if err != nil { + panic(fmt.Errorf("failed to get latest version of workspace: %v", err)) + } + temp.Status = w.Status + updateErr := client.Update(context.TODO(), temp) + return updateErr + }) + return retryErr +} From 8077a5aba248f0bee38d9d56c20abf61f6a85d61 Mon Sep 17 00:00:00 2001 From: kunalvalia <66709086+kunalvalia@users.noreply.github.com> Date: Thu, 24 Jun 2021 09:43:12 -0700 Subject: [PATCH 13/17] Added ability to configure run triggers (#103) --- api/v1alpha1/workspace_types.go | 9 + api/v1alpha1/zz_generated.deepcopy.go | 26 + .../bases/app.terraform.io_workspaces.yaml | 530 ++++++++++-------- workspacehelper/tfc_run_trigger.go | 116 ++++ workspacehelper/workspace_helper.go | 33 +- 5 files changed, 455 insertions(+), 259 deletions(-) create mode 100644 workspacehelper/tfc_run_trigger.go diff --git a/api/v1alpha1/workspace_types.go b/api/v1alpha1/workspace_types.go index 4483e0cc..439d0d45 100644 --- a/api/v1alpha1/workspace_types.go +++ b/api/v1alpha1/workspace_types.go @@ -96,6 +96,12 @@ type Notification struct { Users []string `json:"users,omitempty"` } +// Run Trigger from a source workspace +type RunTrigger struct { + // Name of source workspace that triggers the current workspace + SourceableName string `json:"sourceableName"` +} + // WorkspaceSpec defines the desired state of Workspace // +k8s:openapi-gen=true type WorkspaceSpec struct { @@ -112,6 +118,9 @@ type WorkspaceSpec struct { // Variables as inputs to module // +optional Variables []*Variable `json:"variables,omitempty"` + // Run Triggers from source workspaces to trigger this workspace + // +optional + RunTriggers []*RunTrigger `json:"runTriggers,omitempty"` // File path within operator pod to load workspace secrets SecretsMountPath string `json:"secretsMountPath"` // SSH Key ID. This key must already exist in the TF Cloud organization. This can either be the user assigned name of the SSH Key, or the system assigned ID. diff --git a/api/v1alpha1/zz_generated.deepcopy.go b/api/v1alpha1/zz_generated.deepcopy.go index 146f8fc3..e85e40dd 100644 --- a/api/v1alpha1/zz_generated.deepcopy.go +++ b/api/v1alpha1/zz_generated.deepcopy.go @@ -84,6 +84,21 @@ func (in *OutputStatus) DeepCopy() *OutputStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RunTrigger) DeepCopyInto(out *RunTrigger) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RunTrigger. +func (in *RunTrigger) DeepCopy() *RunTrigger { + if in == nil { + return nil + } + out := new(RunTrigger) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *VCS) DeepCopyInto(out *VCS) { *out = *in @@ -202,6 +217,17 @@ func (in *WorkspaceSpec) DeepCopyInto(out *WorkspaceSpec) { } } } + if in.RunTriggers != nil { + in, out := &in.RunTriggers, &out.RunTriggers + *out = make([]*RunTrigger, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(RunTrigger) + **out = **in + } + } + } if in.Outputs != nil { in, out := &in.Outputs, &out.Outputs *out = make([]*OutputSpec, len(*in)) diff --git a/config/crd/bases/app.terraform.io_workspaces.yaml b/config/crd/bases/app.terraform.io_workspaces.yaml index b024984e..0727030d 100644 --- a/config/crd/bases/app.terraform.io_workspaces.yaml +++ b/config/crd/bases/app.terraform.io_workspaces.yaml @@ -1,10 +1,10 @@ --- -apiVersion: apiextensions.k8s.io/v1 +apiVersion: apiextensions.k8s.io/v1beta1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.4.1 + controller-gen.kubebuilder.io/version: v0.3.0 creationTimestamp: null name: workspaces.app.terraform.io spec: @@ -15,259 +15,307 @@ spec: plural: workspaces singular: workspace scope: Namespaced - versions: - - name: v1alpha1 - schema: - openAPIV3Schema: - description: Workspace is the Schema for the workspaces API - properties: - apiVersion: - description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' - type: string - kind: - description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' - type: string - metadata: - type: object - spec: - description: WorkspaceSpec defines the desired state of Workspace - properties: - agentPoolID: - description: Specifies the agent pool ID we wish to use. - type: string - module: - description: Module source and version to use - nullable: true + subresources: + status: {} + validation: + openAPIV3Schema: + description: Workspace is the Schema for the workspaces API + properties: + apiVersion: + description: 'APIVersion defines the versioned schema of this representation + of an object. Servers should convert recognized schemas to the latest + internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + kind: + description: 'Kind is a string value representing the REST resource this + object represents. Servers may infer this from the endpoint the client + submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + type: object + spec: + description: WorkspaceSpec defines the desired state of Workspace + properties: + agentPoolID: + description: Specifies the agent pool ID we wish to use. + type: string + module: + description: Module source and version to use + nullable: true + properties: + source: + description: Any remote module source (version control, registry) + type: string + version: + description: Module version for registry modules + type: string + required: + - source + type: object + notifications: + description: Notification configuration + items: + description: Notification notification holds all the necessary information + required to configure any workspace notification properties: - source: - description: Any remote module source (version control, registry) - type: string - version: - description: Module version for registry modules + enabled: + description: Control if the notification is enabled or not + type: boolean + name: + description: Name of the hook type: string - required: - - source - type: object - notifications: - description: Notification configuration - items: - description: Notification notification holds all the necessary information required to configure any workspace notification - properties: - enabled: - description: Control if the notification is enabled or not - type: boolean - name: - description: Name of the hook - type: string - recipients: - description: List of recipients' email addresses. Only applicable for TFE endpoints. - items: - type: string - type: array - token: - description: Token used to generate an HMAC on the verificatio0n request - type: string - triggers: - description: When the web hook gets triggered. Acceptable values are run:created, run:planning, run:needs_attention, run:applying, run:completed, run:errored. - items: - type: string - type: array - type: - description: Notification type. Can be one of email, generic, or slack - type: string - url: - description: URL of the hook + recipients: + description: List of recipients' email addresses. Only applicable + for TFE endpoints. + items: type: string - users: - description: List of users to receive the notificaiton email. - items: - type: string - type: array - required: - - enabled - - name - - type - type: object - type: array - organization: - description: Terraform Cloud organization - type: string - outputs: - description: Outputs denote outputs wanted - items: - description: OutputSpec specifies which values need to be output - properties: - key: - description: Output name - type: string - moduleOutputName: - description: Attribute name in module - type: string - type: object - type: array - secretsMountPath: - description: File path within operator pod to load workspace secrets - type: string - sshKeyID: - description: SSH Key ID. This key must already exist in the TF Cloud organization. This can either be the user assigned name of the SSH Key, or the system assigned ID. - type: string - terraformVersion: - description: Terraform version used for this workspace. The default is `latest`. - type: string - variables: - description: Variables as inputs to module - items: - description: Variable denotes an input to the module - properties: - environmentVariable: - description: EnvironmentVariable denotes if this variable should be created as environment variable - type: boolean - hcl: - description: String input should be an HCL-formatted variable - type: boolean - key: - description: Variable name + type: array + token: + description: Token used to generate an HMAC on the verificatio0n + request + type: string + triggers: + description: When the web hook gets triggered. Acceptable values + are run:created, run:planning, run:needs_attention, run:applying, + run:completed, run:errored. + items: type: string - sensitive: - description: Variable is a secret and should be retrieved from file - type: boolean - value: - description: Variable value + type: array + type: + description: Notification type. Can be one of email, generic, + or slack + type: string + url: + description: URL of the hook + type: string + users: + description: List of users to receive the notificaiton email. + items: type: string - valueFrom: - description: Source for the variable's value. Cannot be used if value is not empty. - properties: - configMapKeyRef: - description: Selects a key of a ConfigMap. - properties: - key: - description: The key to select. - type: string - name: - description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?' - type: string - optional: - description: Specify whether the ConfigMap or its key must be defined - type: boolean - required: - - key - type: object - fieldRef: - description: 'Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP, status.podIPs.' - properties: - apiVersion: - description: Version of the schema the FieldPath is written in terms of, defaults to "v1". - type: string - fieldPath: - description: Path of the field to select in the specified API version. - type: string - required: - - fieldPath - type: object - resourceFieldRef: - description: 'Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, limits.ephemeral-storage, requests.cpu, requests.memory and requests.ephemeral-storage) are currently supported.' - properties: - containerName: - description: 'Container name: required for volumes, optional for env vars' - type: string - divisor: - anyOf: - - type: integer - - type: string - description: Specifies the output format of the exposed resources, defaults to "1" - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - resource: - description: 'Required: resource to select' - type: string - required: - - resource - type: object - secretKeyRef: - description: Selects a key of a secret in the pod's namespace - properties: - key: - description: The key of the secret to select from. Must be a valid secret key. - type: string - name: - description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?' - type: string - optional: - description: Specify whether the Secret or its key must be defined - type: boolean - required: - - key - type: object - type: object - required: - - environmentVariable - - key - - sensitive - type: object - type: array - vcs: - description: Details of the VCS repository we want to connect to the workspace - nullable: true + type: array + required: + - enabled + - name + - type + type: object + type: array + organization: + description: Terraform Cloud organization + type: string + outputs: + description: Outputs denote outputs wanted + items: + description: OutputSpec specifies which values need to be output properties: - branch: - description: The repository branch to use + key: + description: Output name + type: string + moduleOutputName: + description: Attribute name in module type: string - ingress_submodules: - description: Whether submodules should be fetched when cloning the VCS repository (Defaults to false) + type: object + type: array + runTriggers: + description: Run Triggers from source workspaces to trigger this workspace + items: + description: Run Trigger from a source workspace + properties: + sourceableName: + description: Name of source workspace that triggers the current + workspace + type: string + required: + - sourceableName + type: object + type: array + secretsMountPath: + description: File path within operator pod to load workspace secrets + type: string + sshKeyID: + description: SSH Key ID. This key must already exist in the TF Cloud + organization. This can either be the user assigned name of the SSH + Key, or the system assigned ID. + type: string + terraformVersion: + description: Terraform version used for this workspace. The default + is `latest`. + type: string + variables: + description: Variables as inputs to module + items: + description: Variable denotes an input to the module + properties: + environmentVariable: + description: EnvironmentVariable denotes if this variable should + be created as environment variable type: boolean - repo_identifier: - description: A reference to your VCS repository in the format org/repo + hcl: + description: String input should be an HCL-formatted variable + type: boolean + key: + description: Variable name type: string - token_id: - description: Token ID of the VCS Connection (OAuth Connection Token) to use https://www.terraform.io/docs/cloud/vcs + sensitive: + description: Variable is a secret and should be retrieved from + file + type: boolean + value: + description: Variable value type: string + valueFrom: + description: Source for the variable's value. Cannot be used if + value is not empty. + properties: + configMapKeyRef: + description: Selects a key of a ConfigMap. + properties: + key: + description: The key to select. + type: string + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + optional: + description: Specify whether the ConfigMap or its key + must be defined + type: boolean + required: + - key + type: object + fieldRef: + description: 'Selects a field of the pod: supports metadata.name, + metadata.namespace, metadata.labels, metadata.annotations, + spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP, + status.podIPs.' + properties: + apiVersion: + description: Version of the schema the FieldPath is written + in terms of, defaults to "v1". + type: string + fieldPath: + description: Path of the field to select in the specified + API version. + type: string + required: + - fieldPath + type: object + resourceFieldRef: + description: 'Selects a resource of the container: only resources + limits and requests (limits.cpu, limits.memory, limits.ephemeral-storage, + requests.cpu, requests.memory and requests.ephemeral-storage) + are currently supported.' + properties: + containerName: + description: 'Container name: required for volumes, optional + for env vars' + type: string + divisor: + anyOf: + - type: integer + - type: string + description: Specifies the output format of the exposed + resources, defaults to "1" + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + description: 'Required: resource to select' + type: string + required: + - resource + type: object + secretKeyRef: + description: Selects a key of a secret in the pod's namespace + properties: + key: + description: The key of the secret to select from. Must + be a valid secret key. + type: string + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + optional: + description: Specify whether the Secret or its key must + be defined + type: boolean + required: + - key + type: object + type: object required: - - repo_identifier - - token_id + - environmentVariable + - key + - sensitive type: object - required: - - organization - - secretsMountPath - type: object - status: - description: WorkspaceStatus defines the observed state of Workspace - properties: - configVersionID: - description: Configuration Version ID - type: string - outputs: - description: Outputs from state file - items: - description: OutputStatus outputs the values of Terraform output - properties: - key: - description: Attribute name in module - type: string - value: - description: Value - type: string - type: object - type: array - runID: - description: Run ID - type: string - runStatus: - description: Run Status gets the run status - type: string - workspaceID: - description: Workspace ID - type: string - required: - - configVersionID - - runID - - runStatus - - workspaceID - type: object - type: object + type: array + vcs: + description: Details of the VCS repository we want to connect to the + workspace + nullable: true + properties: + branch: + description: The repository branch to use + type: string + ingress_submodules: + description: Whether submodules should be fetched when cloning the + VCS repository (Defaults to false) + type: boolean + repo_identifier: + description: A reference to your VCS repository in the format org/repo + type: string + token_id: + description: Token ID of the VCS Connection (OAuth Connection Token) + to use https://www.terraform.io/docs/cloud/vcs + type: string + required: + - repo_identifier + - token_id + type: object + required: + - organization + - secretsMountPath + type: object + status: + description: WorkspaceStatus defines the observed state of Workspace + properties: + configVersionID: + description: Configuration Version ID + type: string + outputs: + description: Outputs from state file + items: + description: OutputStatus outputs the values of Terraform output + properties: + key: + description: Attribute name in module + type: string + value: + description: Value + type: string + type: object + type: array + runID: + description: Run ID + type: string + runStatus: + description: Run Status gets the run status + type: string + workspaceID: + description: Workspace ID + type: string + required: + - configVersionID + - runID + - runStatus + - workspaceID + type: object + type: object + version: v1alpha1 + versions: + - name: v1alpha1 served: true storage: true - subresources: - status: {} status: acceptedNames: kind: "" diff --git a/workspacehelper/tfc_run_trigger.go b/workspacehelper/tfc_run_trigger.go new file mode 100644 index 00000000..27e98eae --- /dev/null +++ b/workspacehelper/tfc_run_trigger.go @@ -0,0 +1,116 @@ +package workspacehelper + +import ( + tfc "github.com/hashicorp/go-tfe" + + "context" + "github.com/hashicorp/terraform-k8s/api/v1alpha1" +) + +// MapToTFCRunTrigger changes controller spec to a TFC RunTrigger +func MapToTFCRunTrigger(workspace string, specRunTriggers []*v1alpha1.RunTrigger) []*tfc.RunTrigger { + tfcRunTriggers := []*tfc.RunTrigger{} + for _, runTrigger := range specRunTriggers { + tfcRunTriggers = append(tfcRunTriggers, &tfc.RunTrigger{ + SourceableName: runTrigger.SourceableName, + WorkspaceName: workspace, + }) + } + return tfcRunTriggers +} + +// Deletes run triggers in TFC that were not defined in controller spec +func (t *TerraformCloudClient) deleteRunTriggersFromTFC(specTFCRunTriggers []*tfc.RunTrigger, workspaceRunTriggers []*tfc.RunTrigger) error { + for _, rt := range workspaceRunTriggers { + index := findRT(specTFCRunTriggers, rt.SourceableName) + if index < 0 { + err := t.DeleteRunTrigger(rt) + if err != nil { + return err + } + } + } + return nil +} + +// Creates run triggers in TFC that were defined in controller spec but not created +func (t *TerraformCloudClient) createRunTriggersOnTFC(workspace *tfc.Workspace, specTFCRunTriggers []*tfc.RunTrigger, workspaceRunTriggers []*tfc.RunTrigger) (bool, error) { + updated := false + for _, rt := range specTFCRunTriggers { + index := findRT(workspaceRunTriggers, rt.SourceableName) + if index < 0 { + err := t.CreateTerraformRunTrigger(workspace, rt) + if err != nil { + return false, err + } + updated = true + continue + } + } + return updated, nil +} + +// CheckRunTriggers deletes and update TFC run triggers as needed +func (t *TerraformCloudClient) CheckRunTriggers(workspace string, specRunTriggers []*v1alpha1.RunTrigger) (bool, error) { + tfcWorkspace, err := t.Client.Workspaces.Read(context.TODO(), t.Organization, workspace) + if err != nil { + return false, err + } + + specTFCRunTriggers := MapToTFCRunTrigger(workspace, specRunTriggers) + workspaceRunTriggers, err := t.listRunTriggers(tfcWorkspace.ID) + if err != nil { + return false, err + } + if err := t.deleteRunTriggersFromTFC(specTFCRunTriggers, workspaceRunTriggers); err != nil { + return false, err + } + createdRunTriggers, err := t.createRunTriggersOnTFC(tfcWorkspace, specTFCRunTriggers, workspaceRunTriggers) + if err != nil { + return false, err + } + return createdRunTriggers, err +} + +func (t *TerraformCloudClient) listRunTriggers(workspaceID string) ([]*tfc.RunTrigger, error) { + options := tfc.RunTriggerListOptions{ + RunTriggerType: tfc.String("inbound"), + } + runTriggers, err := t.Client.RunTriggers.List(context.TODO(), workspaceID, options) + if err != nil { + return nil, err + } + return runTriggers.Items, nil +} + +func findRT(tfcRunTriggers []*tfc.RunTrigger, sourceableName string) int { + for index, runTrigger := range tfcRunTriggers { + if runTrigger.SourceableName == sourceableName { + return index + } + } + return -1 +} + +func (t *TerraformCloudClient) DeleteRunTrigger(runTrigger *tfc.RunTrigger) error { + err := t.Client.RunTriggers.Delete(context.TODO(), runTrigger.ID) + if err != nil { + return err + } + return nil +} + +func (t *TerraformCloudClient) CreateTerraformRunTrigger(workspace *tfc.Workspace, runTrigger *tfc.RunTrigger) error { + tfcSourceWorkspace, err := t.Client.Workspaces.Read(context.TODO(), t.Organization, runTrigger.SourceableName) + if err != nil { + return err + } + options := tfc.RunTriggerCreateOptions{ + Sourceable: tfcSourceWorkspace, + } + t.Client.RunTriggers.Create(context.TODO(), workspace.ID, options) + if err != nil { + return err + } + return nil +} diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index c349a8ea..13ba0e16 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -4,7 +4,6 @@ import ( "context" "fmt" "io/ioutil" - "k8s.io/client-go/util/retry" "os" "reflect" "time" @@ -139,7 +138,7 @@ func (r *WorkspaceHelper) reconcileWorkspace(instance *appv1alpha1.Workspace) er if instance.Status.WorkspaceID != workspaceID { instance.Status.WorkspaceID = workspaceID instance.Status.Outputs = []*appv1alpha1.OutputStatus{} - if err := retryableUpdateStatus(r.client, instance); err != nil { + if err := r.client.Status().Update(context.TODO(), instance); err != nil { r.reqLogger.Error(err, "Failed to update output status") return err } @@ -243,7 +242,7 @@ func (r *WorkspaceHelper) processFinishedRun(instance *appv1alpha1.Workspace) er if !reflect.DeepEqual(outputs, instance.Status.Outputs) { instance.Status.Outputs = outputs - err := retryableUpdateStatus(r.client, instance) + err := r.client.Status().Update(context.TODO(), instance) if err != nil { r.reqLogger.Error(err, "Failed to update output status") return err @@ -299,6 +298,18 @@ func (r *WorkspaceHelper) updateVariables(instance *appv1alpha1.Workspace) (bool return updatedVariables, nil } +func (r *WorkspaceHelper) updateRunTriggers(instance *appv1alpha1.Workspace) (bool, error) { + workspace := fmt.Sprintf("%s-%s", instance.Namespace, instance.Name) + + updatedRunTriggers, err := r.tfclient.CheckRunTriggers(workspace, instance.Spec.RunTriggers) + if err != nil { + r.reqLogger.Error(err, "Could not update run triggers") + return false, err + } + + return updatedRunTriggers, nil +} + func (r *WorkspaceHelper) prepareModuleRun(instance *appv1alpha1.Workspace, options tfe.RunCreateOptions) (bool, error) { r.reqLogger.Info("Starting module backed run", "Organization", instance.Spec.Organization, "Name", instance.Name, "Namespace", instance.Namespace) @@ -538,18 +549,4 @@ func (r *WorkspaceHelper) updateAwsCredentials(instance *appv1alpha1.Workspace) return err } return nil -} - -func retryableUpdateStatus(client client.Client, w *appv1alpha1.Workspace) error { - retryErr := retry.RetryOnConflict(retry.DefaultRetry, func() error { - temp := &appv1alpha1.Workspace{} - err := client.Get(context.TODO(), types.NamespacedName{Name: w.Name, Namespace: w.Namespace}, temp) - if err != nil { - panic(fmt.Errorf("failed to get latest version of workspace: %v", err)) - } - temp.Status = w.Status - updateErr := client.Update(context.TODO(), temp) - return updateErr - }) - return retryErr -} +} \ No newline at end of file From aae2b9ffb972478d6373c180548d27324c34283d Mon Sep 17 00:00:00 2001 From: kunalvalia <66709086+kunalvalia@users.noreply.github.com> Date: Tue, 29 Jun 2021 14:34:15 -0700 Subject: [PATCH 14/17] Added flag to omit namespace prefix (#105) --- api/v1alpha1/workspace_types.go | 3 +++ config/crd/bases/app.terraform.io_workspaces.yaml | 3 +++ workspacehelper/workspace_helper.go | 10 ++++++++++ 3 files changed, 16 insertions(+) diff --git a/api/v1alpha1/workspace_types.go b/api/v1alpha1/workspace_types.go index 439d0d45..6e0e0a55 100644 --- a/api/v1alpha1/workspace_types.go +++ b/api/v1alpha1/workspace_types.go @@ -138,6 +138,9 @@ type WorkspaceSpec struct { // Notification configuration // +optional Notifications []*Notification `json:"notifications,omitempty"` + // Omit namespace prefix in workspace name + // +optional + OmitNamespacePrefix bool `json:"omitNamespacePrefix,omitempty"` } // WorkspaceStatus defines the observed state of Workspace diff --git a/config/crd/bases/app.terraform.io_workspaces.yaml b/config/crd/bases/app.terraform.io_workspaces.yaml index 0727030d..11105efe 100644 --- a/config/crd/bases/app.terraform.io_workspaces.yaml +++ b/config/crd/bases/app.terraform.io_workspaces.yaml @@ -99,6 +99,9 @@ spec: - type type: object type: array + omitNamespacePrefix: + description: Omit namespace prefix in workspace name + type: boolean organization: description: Terraform Cloud organization type: string diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index 13ba0e16..1a324d3d 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -126,6 +126,10 @@ func (r *WorkspaceHelper) initializeReconciliation(request reconcile.Request) (* func (r *WorkspaceHelper) reconcileWorkspace(instance *appv1alpha1.Workspace) error { workspace := fmt.Sprintf("%s-%s", instance.Namespace, instance.Name) + if instance.Spec.OmitNamespacePrefix { + workspace = fmt.Sprintf("%s", instance.Name) + } + organization := instance.Spec.Organization ws, err := r.tfclient.CheckWorkspace(workspace, instance) @@ -280,6 +284,9 @@ func (r *WorkspaceHelper) updateTerraformTemplate(instance *appv1alpha1.Workspac func (r *WorkspaceHelper) updateVariables(instance *appv1alpha1.Workspace) (bool, error) { workspace := fmt.Sprintf("%s-%s", instance.Namespace, instance.Name) + if instance.Spec.OmitNamespacePrefix { + workspace = fmt.Sprintf("%s", instance.Name) + } for _, variable := range instance.Spec.Variables { err := r.GetConfigMapForVariable(instance.Namespace, variable) @@ -300,6 +307,9 @@ func (r *WorkspaceHelper) updateVariables(instance *appv1alpha1.Workspace) (bool func (r *WorkspaceHelper) updateRunTriggers(instance *appv1alpha1.Workspace) (bool, error) { workspace := fmt.Sprintf("%s-%s", instance.Namespace, instance.Name) + if instance.Spec.OmitNamespacePrefix { + workspace = fmt.Sprintf("%s", instance.Name) + } updatedRunTriggers, err := r.tfclient.CheckRunTriggers(workspace, instance.Spec.RunTriggers) if err != nil { From 5d58ed5fe93257cb6c0d95e9a9cd367e6947db9c Mon Sep 17 00:00:00 2001 From: Rohit Verma <80032502+rverma-nsl@users.noreply.github.com> Date: Sat, 3 Jul 2021 11:43:38 +0530 Subject: [PATCH 15/17] fixed workspace omit namespace behaviour --- workspacehelper/workspace_helper.go | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/workspacehelper/workspace_helper.go b/workspacehelper/workspace_helper.go index e994069f..4eeadaf4 100644 --- a/workspacehelper/workspace_helper.go +++ b/workspacehelper/workspace_helper.go @@ -511,18 +511,18 @@ func (r *WorkspaceHelper) Reconcile(ctx context.Context, request reconcile.Reque return reconcile.Result{}, err } - // check that correct run triggers are configured to trigger the workspace + // check that correct run triggers are configured to trigger the workspace updatedRunTriggers, err := r.updateRunTriggers(instance) if err != nil { return reconcile.Result{}, err } if updatedTerraform || updatedVariables || updatedRunTriggers || instance.Status.RunID == "" || instance.Status.ConfigVersionID != "" { - err = r.updateAwsCredentials(instance) + err = r.updateAwsCredentials(instance) if err != nil { return reconcile.Result{}, err } - err := r.startRun(instance) + err := r.startRun(instance) if err != nil { return reconcile.Result{}, err } @@ -546,7 +546,9 @@ func (r *WorkspaceHelper) Reconcile(ctx context.Context, request reconcile.Reque func (r *WorkspaceHelper) updateAwsCredentials(instance *appv1alpha1.Workspace) error { workspace := fmt.Sprintf("%s-%s", instance.Namespace, instance.Name) - + if instance.Spec.OmitNamespacePrefix { + workspace = instance.Name + } // added for mocking if workspace == "terraform-system-awesome-workspace" { return nil @@ -564,4 +566,4 @@ func (r *WorkspaceHelper) updateAwsCredentials(instance *appv1alpha1.Workspace) return err } return nil -} \ No newline at end of file +} From 88deada759d16e18fd0cb37562e594eb2a6a5bdf Mon Sep 17 00:00:00 2001 From: mvkrishna86 Date: Tue, 21 Mar 2023 15:01:42 +0530 Subject: [PATCH 16/17] Removed beta1 for k8s upgrade --- config/crd/bases/app.terraform.io_workspaces.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/crd/bases/app.terraform.io_workspaces.yaml b/config/crd/bases/app.terraform.io_workspaces.yaml index 11105efe..1c749cb4 100644 --- a/config/crd/bases/app.terraform.io_workspaces.yaml +++ b/config/crd/bases/app.terraform.io_workspaces.yaml @@ -1,6 +1,6 @@ --- -apiVersion: apiextensions.k8s.io/v1beta1 +apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: From ab78d23b86fea82f93aa3c6407a57dac3cc135d4 Mon Sep 17 00:00:00 2001 From: Abhishek Verma Date: Thu, 23 Mar 2023 15:38:01 +0530 Subject: [PATCH 17/17] Update app.terraform.io_workspaces.yaml --- .../bases/app.terraform.io_workspaces.yaml | 595 +++++++++--------- 1 file changed, 302 insertions(+), 293 deletions(-) diff --git a/config/crd/bases/app.terraform.io_workspaces.yaml b/config/crd/bases/app.terraform.io_workspaces.yaml index 1c749cb4..298b6f40 100644 --- a/config/crd/bases/app.terraform.io_workspaces.yaml +++ b/config/crd/bases/app.terraform.io_workspaces.yaml @@ -1,10 +1,9 @@ - --- apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.3.0 + controller-gen.kubebuilder.io/version: v0.8.0 creationTimestamp: null name: workspaces.app.terraform.io spec: @@ -15,313 +14,323 @@ spec: plural: workspaces singular: workspace scope: Namespaced - subresources: - status: {} - validation: - openAPIV3Schema: - description: Workspace is the Schema for the workspaces API - properties: - apiVersion: - description: 'APIVersion defines the versioned schema of this representation - of an object. Servers should convert recognized schemas to the latest - internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' - type: string - kind: - description: 'Kind is a string value representing the REST resource this - object represents. Servers may infer this from the endpoint the client - submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' - type: string - metadata: - type: object - spec: - description: WorkspaceSpec defines the desired state of Workspace - properties: - agentPoolID: - description: Specifies the agent pool ID we wish to use. - type: string - module: - description: Module source and version to use - nullable: true - properties: - source: - description: Any remote module source (version control, registry) - type: string - version: - description: Module version for registry modules - type: string - required: - - source - type: object - notifications: - description: Notification configuration - items: - description: Notification notification holds all the necessary information - required to configure any workspace notification + versions: + - additionalPrinterColumns: + - jsonPath: .metadata.creationTimestamp + name: Age + type: date + - jsonPath: .status.runStatus + name: Status + type: string + name: v1alpha1 + schema: + openAPIV3Schema: + description: Workspace is the Schema for the workspaces API + properties: + apiVersion: + description: 'APIVersion defines the versioned schema of this representation + of an object. Servers should convert recognized schemas to the latest + internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + kind: + description: 'Kind is a string value representing the REST resource this + object represents. Servers may infer this from the endpoint the client + submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + type: object + spec: + description: WorkspaceSpec defines the desired state of Workspace + properties: + agentPoolID: + description: Specifies the agent pool ID we wish to use. + type: string + agentPoolName: + description: Specifies the agent pool name we wish to use. + type: string + module: + description: Module source and version to use + nullable: true properties: - enabled: - description: Control if the notification is enabled or not - type: boolean - name: - description: Name of the hook - type: string - recipients: - description: List of recipients' email addresses. Only applicable - for TFE endpoints. - items: - type: string - type: array - token: - description: Token used to generate an HMAC on the verificatio0n - request + source: + description: Any remote module source (version control, registry) type: string - triggers: - description: When the web hook gets triggered. Acceptable values - are run:created, run:planning, run:needs_attention, run:applying, - run:completed, run:errored. - items: - type: string - type: array - type: - description: Notification type. Can be one of email, generic, - or slack - type: string - url: - description: URL of the hook + version: + description: Module version for registry modules type: string - users: - description: List of users to receive the notificaiton email. - items: - type: string - type: array required: - - enabled - - name - - type - type: object - type: array - omitNamespacePrefix: - description: Omit namespace prefix in workspace name - type: boolean - organization: - description: Terraform Cloud organization - type: string - outputs: - description: Outputs denote outputs wanted - items: - description: OutputSpec specifies which values need to be output - properties: - key: - description: Output name - type: string - moduleOutputName: - description: Attribute name in module - type: string + - source type: object - type: array - runTriggers: - description: Run Triggers from source workspaces to trigger this workspace - items: - description: Run Trigger from a source workspace + notifications: + description: Notification configuration + items: + description: Notification notification holds all the necessary information + required to configure any workspace notification + properties: + enabled: + description: Control if the notification is enabled or not + type: boolean + name: + description: Name of the hook + type: string + recipients: + description: List of recipients' email addresses. Only applicable + for TFE endpoints. + items: + type: string + type: array + token: + description: Token used to generate an HMAC on the verificatio0n + request + type: string + triggers: + description: When the web hook gets triggered. Acceptable values + are run:created, run:planning, run:needs_attention, run:applying, + run:completed, run:errored. + items: + type: string + type: array + type: + description: Notification type. Can be one of email, generic, + or slack + type: string + url: + description: URL of the hook + type: string + users: + description: List of users to receive the notificaiton email. + items: + type: string + type: array + required: + - enabled + - name + - type + type: object + type: array + omitNamespacePrefix: + description: Omit namespace prefix in workspace name + type: boolean + organization: + description: Terraform Cloud organization + type: string + outputs: + description: Outputs denote outputs wanted + items: + description: OutputSpec specifies which values need to be output + properties: + key: + description: Output name + type: string + moduleOutputName: + description: Attribute name in module + type: string + type: object + type: array + runTriggers: + description: Run Triggers from source workspaces to trigger this workspace + items: + description: Run Trigger from a source workspace + properties: + sourceableName: + description: Name of source workspace that triggers the current + workspace + type: string + required: + - sourceableName + type: object + type: array + secretsMountPath: + description: File path within operator pod to load workspace secrets + type: string + sshKeyID: + description: SSH Key ID. This key must already exist in the TF Cloud + organization. This can either be the user assigned name of the + SSH Key, or the system assigned ID. + type: string + terraformVersion: + description: Terraform version used for this workspace. The default + is `latest`. + type: string + variables: + description: Variables as inputs to module + items: + description: Variable denotes an input to the module + properties: + environmentVariable: + description: EnvironmentVariable denotes if this variable should + be created as environment variable + type: boolean + hcl: + description: String input should be an HCL-formatted variable + type: boolean + key: + description: Variable name + type: string + sensitive: + description: Variable is a secret and should be retrieved from + file + type: boolean + value: + description: Variable value + type: string + valueFrom: + description: Source for the variable's value. Cannot be used + if value is not empty. + properties: + configMapKeyRef: + description: Selects a key of a ConfigMap. + properties: + key: + description: The key to select. + type: string + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + optional: + description: Specify whether the ConfigMap or its key + must be defined + type: boolean + required: + - key + type: object + fieldRef: + description: 'Selects a field of the pod: supports metadata.name, + metadata.namespace, `metadata.labels['''']`, `metadata.annotations['''']`, + spec.nodeName, spec.serviceAccountName, status.hostIP, + status.podIP, status.podIPs.' + properties: + apiVersion: + description: Version of the schema the FieldPath is + written in terms of, defaults to "v1". + type: string + fieldPath: + description: Path of the field to select in the specified + API version. + type: string + required: + - fieldPath + type: object + resourceFieldRef: + description: 'Selects a resource of the container: only + resources limits and requests (limits.cpu, limits.memory, + limits.ephemeral-storage, requests.cpu, requests.memory + and requests.ephemeral-storage) are currently supported.' + properties: + containerName: + description: 'Container name: required for volumes, + optional for env vars' + type: string + divisor: + anyOf: + - type: integer + - type: string + description: Specifies the output format of the exposed + resources, defaults to "1" + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + description: 'Required: resource to select' + type: string + required: + - resource + type: object + secretKeyRef: + description: Selects a key of a secret in the pod's namespace + properties: + key: + description: The key of the secret to select from. Must + be a valid secret key. + type: string + name: + description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + TODO: Add other useful fields. apiVersion, kind, uid?' + type: string + optional: + description: Specify whether the Secret or its key must + be defined + type: boolean + required: + - key + type: object + type: object + required: + - environmentVariable + - key + - sensitive + type: object + type: array + vcs: + description: Details of the VCS repository we want to connect to the + workspace + nullable: true properties: - sourceableName: - description: Name of source workspace that triggers the current - workspace + branch: + description: The repository branch to use type: string - required: - - sourceableName - type: object - type: array - secretsMountPath: - description: File path within operator pod to load workspace secrets - type: string - sshKeyID: - description: SSH Key ID. This key must already exist in the TF Cloud - organization. This can either be the user assigned name of the SSH - Key, or the system assigned ID. - type: string - terraformVersion: - description: Terraform version used for this workspace. The default - is `latest`. - type: string - variables: - description: Variables as inputs to module - items: - description: Variable denotes an input to the module - properties: - environmentVariable: - description: EnvironmentVariable denotes if this variable should - be created as environment variable - type: boolean - hcl: - description: String input should be an HCL-formatted variable + ingress_submodules: + description: Whether submodules should be fetched when cloning + the VCS repository (Defaults to false) type: boolean - key: - description: Variable name + repo_identifier: + description: A reference to your VCS repository in the format + org/repo type: string - sensitive: - description: Variable is a secret and should be retrieved from - file - type: boolean - value: - description: Variable value + token_id: + description: Token ID of the VCS Connection (OAuth Connection + Token) to use https://www.terraform.io/docs/cloud/vcs type: string - valueFrom: - description: Source for the variable's value. Cannot be used if - value is not empty. - properties: - configMapKeyRef: - description: Selects a key of a ConfigMap. - properties: - key: - description: The key to select. - type: string - name: - description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names - TODO: Add other useful fields. apiVersion, kind, uid?' - type: string - optional: - description: Specify whether the ConfigMap or its key - must be defined - type: boolean - required: - - key - type: object - fieldRef: - description: 'Selects a field of the pod: supports metadata.name, - metadata.namespace, metadata.labels, metadata.annotations, - spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP, - status.podIPs.' - properties: - apiVersion: - description: Version of the schema the FieldPath is written - in terms of, defaults to "v1". - type: string - fieldPath: - description: Path of the field to select in the specified - API version. - type: string - required: - - fieldPath - type: object - resourceFieldRef: - description: 'Selects a resource of the container: only resources - limits and requests (limits.cpu, limits.memory, limits.ephemeral-storage, - requests.cpu, requests.memory and requests.ephemeral-storage) - are currently supported.' - properties: - containerName: - description: 'Container name: required for volumes, optional - for env vars' - type: string - divisor: - anyOf: - - type: integer - - type: string - description: Specifies the output format of the exposed - resources, defaults to "1" - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - resource: - description: 'Required: resource to select' - type: string - required: - - resource - type: object - secretKeyRef: - description: Selects a key of a secret in the pod's namespace - properties: - key: - description: The key of the secret to select from. Must - be a valid secret key. - type: string - name: - description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names - TODO: Add other useful fields. apiVersion, kind, uid?' - type: string - optional: - description: Specify whether the Secret or its key must - be defined - type: boolean - required: - - key - type: object - type: object required: - - environmentVariable - - key - - sensitive - type: object - type: array - vcs: - description: Details of the VCS repository we want to connect to the - workspace - nullable: true - properties: - branch: - description: The repository branch to use - type: string - ingress_submodules: - description: Whether submodules should be fetched when cloning the - VCS repository (Defaults to false) - type: boolean - repo_identifier: - description: A reference to your VCS repository in the format org/repo - type: string - token_id: - description: Token ID of the VCS Connection (OAuth Connection Token) - to use https://www.terraform.io/docs/cloud/vcs - type: string - required: - - repo_identifier - - token_id - type: object - required: - - organization - - secretsMountPath - type: object - status: - description: WorkspaceStatus defines the observed state of Workspace - properties: - configVersionID: - description: Configuration Version ID - type: string - outputs: - description: Outputs from state file - items: - description: OutputStatus outputs the values of Terraform output - properties: - key: - description: Attribute name in module - type: string - value: - description: Value - type: string + - repo_identifier + - token_id type: object - type: array - runID: - description: Run ID - type: string - runStatus: - description: Run Status gets the run status - type: string - workspaceID: - description: Workspace ID - type: string - required: - - configVersionID - - runID - - runStatus - - workspaceID - type: object - type: object - version: v1alpha1 - versions: - - name: v1alpha1 + required: + - organization + - secretsMountPath + type: object + status: + description: WorkspaceStatus defines the observed state of Workspace + properties: + configVersionID: + description: Configuration Version ID + type: string + outputs: + description: Outputs from state file + items: + description: OutputStatus outputs the values of Terraform output + properties: + key: + description: Attribute name in module + type: string + value: + description: Value + type: string + type: object + type: array + runID: + description: Run ID + type: string + runStatus: + description: Run Status gets the run status + type: string + workspaceID: + description: Workspace ID + type: string + required: + - configVersionID + - runID + - runStatus + - workspaceID + type: object + type: object served: true storage: true + subresources: + status: {} status: acceptedNames: kind: "" plural: "" conditions: [] - storedVersions: [] + storedVersions: [] \ No newline at end of file