From f2493b598915081ad00c459cf4c89fa2e3d90356 Mon Sep 17 00:00:00 2001 From: Ivan Sim <1330522+ihcsim@users.noreply.github.com> Date: Thu, 1 Sep 2022 15:06:14 -0700 Subject: [PATCH 01/15] Update README with info on issues lifecycle (#1618) Signed-off-by: Ivan Sim Signed-off-by: Ivan Sim --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index f9ed4b8cba..beb281deab 100644 --- a/README.md +++ b/README.md @@ -79,6 +79,12 @@ The Kanister architecture is documented If you have any questions or run into issues, feel free to reach out to us on [Slack](https://kanisterio.slack.com). +GitHub issues or pull requests that have been inactive for more than 60 days +will be labeled as stale. If they remained inactive for another 30 days, they +will be automatically closed. To be exempted from the issue lifecycle, discuss +with a maintainer the reasons behind the exemption, and add the `frozen` label +to the issue or pull request. + If you discovered any security issues, refer to our [`SECURITY.md`](SECURITY.md) documentation for our security policy, including steps on how to report vulnerabilities. From a9da6730ce7b080884478a0fe24b6427ca1bedc3 Mon Sep 17 00:00:00 2001 From: Rajat Gupta <37516416+r4rajat@users.noreply.github.com> Date: Fri, 2 Sep 2022 15:37:43 +0530 Subject: [PATCH 02/15] Integration Test - Remove Support for Helm v2 and Provide Support for Enable/Disable wait while Installing Charts (#1612) * Remove Support for Helm v2 - Removed Support for Helm v2 - Added functionality for enabling/disabling --wait flag while helm install Signed-off-by: Rajat Gupta * Add wait argument in Install Method - Added functionality for enabling/disabling --wait flag while helm install using wait argument in Install method. * Add wait argument in Install Method - Added functionality for enabling/disabling --wait flag while helm install using wait argument in Install method. Signed-off-by: Rajat Gupta * Fix Linting issues Signed-off-by: Rajat Gupta * Add a comment for wait argument Signed-off-by: Rajat Gupta * Remove else statement for wait Signed-off-by: Rajat Gupta Signed-off-by: Rajat Gupta Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- pkg/app/cassandra.go | 2 +- pkg/app/couchbase.go | 2 +- pkg/app/elasticsearch.go | 2 +- pkg/app/kafka.go | 2 +- pkg/app/mariadb.go | 2 +- pkg/app/mongodb.go | 2 +- pkg/app/mysql.go | 2 +- pkg/app/postgresql.go | 2 +- pkg/helm/client.go | 10 ++++------ pkg/helm/helm.go | 3 ++- pkg/testing/helm/helm_app.go | 2 +- 11 files changed, 15 insertions(+), 16 deletions(-) diff --git a/pkg/app/cassandra.go b/pkg/app/cassandra.go index 8318d7c5e4..d5b9c071e8 100644 --- a/pkg/app/cassandra.go +++ b/pkg/app/cassandra.go @@ -91,7 +91,7 @@ func (cas *CassandraInstance) Install(ctx context.Context, namespace string) err if err != nil { return err } - err = cli.Install(ctx, fmt.Sprintf("%s/%s", cas.chart.RepoName, cas.chart.Chart), cas.chart.Version, cas.chart.Release, cas.namespace, cas.chart.Values) + err = cli.Install(ctx, fmt.Sprintf("%s/%s", cas.chart.RepoName, cas.chart.Chart), cas.chart.Version, cas.chart.Release, cas.namespace, cas.chart.Values, true) if err != nil { return err } diff --git a/pkg/app/couchbase.go b/pkg/app/couchbase.go index 4ea63e81de..7f660fbdaa 100644 --- a/pkg/app/couchbase.go +++ b/pkg/app/couchbase.go @@ -96,7 +96,7 @@ func (cb *CouchbaseDB) Install(ctx context.Context, ns string) error { } // Install cb operator, admission controller and cluster - err = cli.Install(ctx, fmt.Sprintf("%s/%s", cb.chart.RepoName, cb.chart.Chart), cb.chart.Version, cb.chart.Release, cb.namespace, cb.chart.Values) + err = cli.Install(ctx, fmt.Sprintf("%s/%s", cb.chart.RepoName, cb.chart.Chart), cb.chart.Version, cb.chart.Release, cb.namespace, cb.chart.Values, true) return errors.Wrapf(err, "Failed to install helm chart. app=%s chart=%s release=%s", cb.name, cb.chart.Chart, cb.chart.Release) } diff --git a/pkg/app/elasticsearch.go b/pkg/app/elasticsearch.go index 91ea72ec91..637f352508 100644 --- a/pkg/app/elasticsearch.go +++ b/pkg/app/elasticsearch.go @@ -99,7 +99,7 @@ func (esi *ElasticsearchInstance) Install(ctx context.Context, namespace string) return err } - err = cli.Install(ctx, fmt.Sprintf("%s/%s", esi.chart.RepoName, esi.chart.Chart), esi.chart.Version, esi.chart.Release, esi.namespace, esi.chart.Values) + err = cli.Install(ctx, fmt.Sprintf("%s/%s", esi.chart.RepoName, esi.chart.Chart), esi.chart.Version, esi.chart.Release, esi.namespace, esi.chart.Values, true) if err != nil { return err } diff --git a/pkg/app/kafka.go b/pkg/app/kafka.go index b576e26917..1b51a20f5c 100644 --- a/pkg/app/kafka.go +++ b/pkg/app/kafka.go @@ -133,7 +133,7 @@ func (kc *KafkaCluster) Install(ctx context.Context, namespace string) error { return errors.Wrapf(err, "Error adding helm repo for app %s.", kc.name) } log.Print("Installing kafka operator using helm.", field.M{"app": kc.name}) - err = cli.Install(ctx, kc.chart.RepoName+"/"+kc.chart.Chart, kc.chart.Version, kc.chart.Release, kc.namespace, kc.chart.Values) + err = cli.Install(ctx, kc.chart.RepoName+"/"+kc.chart.Chart, kc.chart.Version, kc.chart.Release, kc.namespace, kc.chart.Values, true) if err != nil { return errors.Wrapf(err, "Error installing operator %s through helm.", kc.name) } diff --git a/pkg/app/mariadb.go b/pkg/app/mariadb.go index 0c35bfcf17..3d4a4c316f 100644 --- a/pkg/app/mariadb.go +++ b/pkg/app/mariadb.go @@ -87,7 +87,7 @@ func (m *MariaDB) Install(ctx context.Context, namespace string) error { } log.Print("Installing maria instance using helm.", field.M{"app": m.name}) - err = cli.Install(ctx, m.chart.RepoName+"/"+m.chart.Chart, m.chart.Version, m.chart.Release, m.namespace, m.chart.Values) + err = cli.Install(ctx, m.chart.RepoName+"/"+m.chart.Chart, m.chart.Version, m.chart.Release, m.namespace, m.chart.Values, true) if err != nil { return errors.Wrapf(err, "Error intalling application %s through helm.", m.name) } diff --git a/pkg/app/mongodb.go b/pkg/app/mongodb.go index ff75ecce05..e3a9a66399 100644 --- a/pkg/app/mongodb.go +++ b/pkg/app/mongodb.go @@ -94,7 +94,7 @@ func (mongo *MongoDB) Install(ctx context.Context, namespace string) error { } log.Print("Installing application using helm.", field.M{"app": mongo.name}) - err = cli.Install(ctx, fmt.Sprintf("%s/%s", mongo.chart.RepoName, mongo.chart.Chart), mongo.chart.Version, mongo.chart.Release, mongo.namespace, mongo.chart.Values) + err = cli.Install(ctx, fmt.Sprintf("%s/%s", mongo.chart.RepoName, mongo.chart.Chart), mongo.chart.Version, mongo.chart.Release, mongo.namespace, mongo.chart.Values, true) if err != nil { return err } diff --git a/pkg/app/mysql.go b/pkg/app/mysql.go index 1695601f69..0d1fc49b4a 100644 --- a/pkg/app/mysql.go +++ b/pkg/app/mysql.go @@ -86,7 +86,7 @@ func (mdb *MysqlDB) Install(ctx context.Context, namespace string) error { } log.Print("Installing mysql instance using helm.", field.M{"app": mdb.name}) - err = cli.Install(ctx, mdb.chart.RepoName+"/"+mdb.chart.Chart, mdb.chart.Version, mdb.chart.Release, mdb.namespace, mdb.chart.Values) + err = cli.Install(ctx, mdb.chart.RepoName+"/"+mdb.chart.Chart, mdb.chart.Version, mdb.chart.Release, mdb.namespace, mdb.chart.Values, true) if err != nil { return errors.Wrapf(err, "Error intalling application %s through helm.", mdb.name) } diff --git a/pkg/app/postgresql.go b/pkg/app/postgresql.go index 0614734498..c07707e0de 100644 --- a/pkg/app/postgresql.go +++ b/pkg/app/postgresql.go @@ -95,7 +95,7 @@ func (pdb *PostgresDB) Install(ctx context.Context, ns string) error { return err } // Install helm chart - return cli.Install(ctx, fmt.Sprintf("%s/%s", pdb.chart.RepoName, pdb.chart.Chart), pdb.chart.Version, pdb.chart.Release, pdb.namespace, pdb.chart.Values) + return cli.Install(ctx, fmt.Sprintf("%s/%s", pdb.chart.RepoName, pdb.chart.Chart), pdb.chart.Version, pdb.chart.Release, pdb.namespace, pdb.chart.Values, true) } func (pdb *PostgresDB) IsReady(ctx context.Context) (bool, error) { diff --git a/pkg/helm/client.go b/pkg/helm/client.go index 186d1000c6..159827cf77 100644 --- a/pkg/helm/client.go +++ b/pkg/helm/client.go @@ -125,18 +125,16 @@ func (h CliClient) UpdateRepo(ctx context.Context) error { } // Install installs helm chart with given release name -func (h CliClient) Install(ctx context.Context, chart, version, release, namespace string, values map[string]string) error { +func (h CliClient) Install(ctx context.Context, chart, version, release, namespace string, values map[string]string, wait bool) error { log.Debug().Print("Installing helm chart", field.M{"chart": chart, "version": version, "release": release, "namespace": namespace}) var setVals string for k, v := range values { setVals += fmt.Sprintf("%s=%s,", k, v) } - var cmd []string - if h.version == V3 { - cmd = []string{"install", release, "--version", version, "--namespace", namespace, chart, "--set", setVals, "--wait", "--create-namespace"} - } else { - cmd = []string{"install", "--name", release, "--version", version, "--namespace", namespace, chart, "--set", setVals, "--wait"} + cmd := []string{"install", release, "--version", version, "--namespace", namespace, chart, "--set", setVals, "--create-namespace"} + if wait { + cmd = append(cmd, "--wait") } out, err := RunCmdWithTimeout(ctx, h.helmBin, cmd) diff --git a/pkg/helm/helm.go b/pkg/helm/helm.go index a44090b1b3..80c1cd1a80 100644 --- a/pkg/helm/helm.go +++ b/pkg/helm/helm.go @@ -26,7 +26,8 @@ type Client interface { // RemoveRepo removes helm repo RemoveRepo(ctx context.Context, name string) error // Install installs helm chart with given release name in the namespace - Install(ctx context.Context, chart, version, release, namespace string, values map[string]string) error + // wait argument enables/disables --wait flag in 'helm install' command + Install(ctx context.Context, chart, version, release, namespace string, values map[string]string, wait bool) error // Uninstall deletes helm release from the given namespace Uninstall(ctx context.Context, release, namespace string) error // Upgrade upgrades an installed helm release diff --git a/pkg/testing/helm/helm_app.go b/pkg/testing/helm/helm_app.go index 7297b9c459..2bc769f2a2 100644 --- a/pkg/testing/helm/helm_app.go +++ b/pkg/testing/helm/helm_app.go @@ -52,7 +52,7 @@ func (h *HelmApp) AddRepo(name, url string) error { func (h *HelmApp) Install() error { ctx := context.Background() - return h.client.Install(ctx, h.chart, "", h.name, h.namespace, h.helmValues) + return h.client.Install(ctx, h.chart, "", h.name, h.namespace, h.helmValues, true) } func (h *HelmApp) Upgrade(chart string, updatedValues map[string]string) error { From 226f8ceca00ba4ba515066b0ed157e844776b6e8 Mon Sep 17 00:00:00 2001 From: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> Date: Fri, 2 Sep 2022 13:37:08 -0700 Subject: [PATCH 03/15] Update k8s dependencies patch version (#1619) * Update k8s dependencies patch version * Run go mod tidy without compat Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- go.mod | 14 +++++++------- go.sum | 41 ++++++++++++++++++----------------------- 2 files changed, 25 insertions(+), 30 deletions(-) diff --git a/go.mod b/go.mod index 47dacea6bd..714c6b1b1b 100644 --- a/go.mod +++ b/go.mod @@ -52,12 +52,12 @@ require ( gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637 //pinned k8s.io to v0.24.1 tag - k8s.io/api v0.24.3 - k8s.io/apiextensions-apiserver v0.24.3 - k8s.io/apimachinery v0.24.3 - k8s.io/cli-runtime v0.24.1 - k8s.io/client-go v0.24.3 - k8s.io/kubectl v0.24.1 + k8s.io/api v0.24.4 + k8s.io/apiextensions-apiserver v0.24.4 + k8s.io/apimachinery v0.24.4 + k8s.io/cli-runtime v0.24.4 + k8s.io/client-go v0.24.4 + k8s.io/kubectl v0.24.4 k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9 sigs.k8s.io/controller-runtime v0.12.3 ) @@ -184,7 +184,7 @@ require ( gopkg.in/ini.v1 v1.66.6 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/component-base v0.24.3 // indirect + k8s.io/component-base v0.24.4 // indirect k8s.io/klog/v2 v2.60.1 // indirect k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42 // indirect sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2 // indirect diff --git a/go.sum b/go.sum index e064951456..c0f141ee69 100644 --- a/go.sum +++ b/go.sum @@ -1649,39 +1649,34 @@ honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= k8s.io/api v0.18.3/go.mod h1:UOaMwERbqJMfeeeHc8XJKawj4P9TgDRnViIqqBeH2QA= k8s.io/api v0.19.0/go.mod h1:I1K45XlvTrDjmj5LoM5LuP/KYrhWbjUKT/SoPG0qTjw= -k8s.io/api v0.24.1/go.mod h1:JhoOvNiLXKTPQ60zh2g0ewpA+bnEYf5q44Flhquh4vQ= k8s.io/api v0.24.2/go.mod h1:AHqbSkTm6YrQ0ObxjO3Pmp/ubFF/KuM7jU+3khoBsOg= -k8s.io/api v0.24.3 h1:tt55QEmKd6L2k5DP6G/ZzdMQKvG5ro4H4teClqm0sTY= -k8s.io/api v0.24.3/go.mod h1:elGR/XSZrS7z7cSZPzVWaycpJuGIw57j9b95/1PdJNI= +k8s.io/api v0.24.4 h1:I5Y645gJ8zWKawyr78lVfDQkZrAViSbeRXsPZWTxmXk= +k8s.io/api v0.24.4/go.mod h1:42pVfA0NRxrtJhZQOvRSyZcJihzAdU59WBtTjYcB0/M= k8s.io/apiextensions-apiserver v0.24.2/go.mod h1:e5t2GMFVngUEHUd0wuCJzw8YDwZoqZfJiGOW6mm2hLQ= -k8s.io/apiextensions-apiserver v0.24.3 h1:kyx+Tmro1qEsTUr07ZGQOfvTsF61yn+AxnxytBWq8As= -k8s.io/apiextensions-apiserver v0.24.3/go.mod h1:cL0xkmUefpYM4f6IuOau+6NMFEIh6/7wXe/O4vPVJ8A= +k8s.io/apiextensions-apiserver v0.24.4 h1:w53Pm4zu8fCt9WfiRgS2YI6LE6I4NJ5aUi78GElD3K8= +k8s.io/apiextensions-apiserver v0.24.4/go.mod h1:iDK+Xb4jsPNnRGj5jU/WqqjLvt8363M7cKixKe1C9+U= k8s.io/apimachinery v0.18.3/go.mod h1:OaXp26zu/5J7p0f92ASynJa1pZo06YlV9fG7BoWbCko= k8s.io/apimachinery v0.19.0/go.mod h1:DnPGDnARWFvYa3pMHgSxtbZb7gpzzAZ1pTfaUNDVlmA= -k8s.io/apimachinery v0.24.1/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= k8s.io/apimachinery v0.24.2/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= -k8s.io/apimachinery v0.24.3 h1:hrFiNSA2cBZqllakVYyH/VyEh4B581bQRmqATJSeQTg= -k8s.io/apimachinery v0.24.3/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= +k8s.io/apimachinery v0.24.4 h1:S0Ur3J/PbivTcL43EdSdPhqCqKla2NIuneNwZcTDeGQ= +k8s.io/apimachinery v0.24.4/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= k8s.io/apiserver v0.24.2/go.mod h1:pSuKzr3zV+L+MWqsEo0kHHYwCo77AT5qXbFXP2jbvFI= -k8s.io/apiserver v0.24.3/go.mod h1:aXfwtIn4U27B7lYs5f2BKgz6DRbgWy+HJeYReN1jLJ8= -k8s.io/cli-runtime v0.24.1 h1:IW6L8dRBq+pPTzvXcB+m/hOabzbqXy57Bqo4XxmW7DY= -k8s.io/cli-runtime v0.24.1/go.mod h1:14aVvCTqkA7dNXY51N/6hRY3GUjchyWDOwW84qmR3bs= +k8s.io/apiserver v0.24.4/go.mod h1:mAuC3pZVc0IDXLx7lUHoisBOtBa1SobfLW/CI3klXQE= +k8s.io/cli-runtime v0.24.4 h1:YCSf0dZp+pYXVR/8aZQ6MEBSiicv8rLyVsGBEbRnwfY= +k8s.io/cli-runtime v0.24.4/go.mod h1:RF+cSLYXkPV3WyvPrX2qeRLEUJY38INWx6jLKVLFCxM= k8s.io/client-go v0.18.3/go.mod h1:4a/dpQEvzAhT1BbuWW09qvIaGw6Gbu1gZYiQZIi1DMw= k8s.io/client-go v0.19.0/go.mod h1:H9E/VT95blcFQnlyShFgnFT9ZnJOAceiUHM3MlRC+mU= -k8s.io/client-go v0.24.1/go.mod h1:f1kIDqcEYmwXS/vTbbhopMUbhKp2JhOeVTfxgaCIlF8= k8s.io/client-go v0.24.2/go.mod h1:zg4Xaoo+umDsfCWr4fCnmLEtQXyCNXCvJuSsglNcV30= -k8s.io/client-go v0.24.3 h1:Nl1840+6p4JqkFWEW2LnMKU667BUxw03REfLAVhuKQY= -k8s.io/client-go v0.24.3/go.mod h1:AAovolf5Z9bY1wIg2FZ8LPQlEdKHjLI7ZD4rw920BJw= +k8s.io/client-go v0.24.4 h1:hIAIJZIPyaw46AkxwyR0FRfM/pRxpUNTd3ysYu9vyRg= +k8s.io/client-go v0.24.4/go.mod h1:+AxlPWw/H6f+EJhRSjIeALaJT4tbeB/8g9BNvXGPd0Y= k8s.io/code-generator v0.18.3/go.mod h1:TgNEVx9hCyPGpdtCWA34olQYLkh3ok9ar7XfSsr8b6c= k8s.io/code-generator v0.19.0/go.mod h1:moqLn7w0t9cMs4+5CQyxnfA/HV8MF6aAVENF+WZZhgk= -k8s.io/code-generator v0.24.1/go.mod h1:dpVhs00hTuTdTY6jvVxvTFCk6gSMrtfRydbhZwHI15w= k8s.io/code-generator v0.24.2/go.mod h1:dpVhs00hTuTdTY6jvVxvTFCk6gSMrtfRydbhZwHI15w= -k8s.io/code-generator v0.24.3/go.mod h1:dpVhs00hTuTdTY6jvVxvTFCk6gSMrtfRydbhZwHI15w= -k8s.io/component-base v0.24.1/go.mod h1:DW5vQGYVCog8WYpNob3PMmmsY8A3L9QZNg4j/dV3s38= +k8s.io/code-generator v0.24.4/go.mod h1:dpVhs00hTuTdTY6jvVxvTFCk6gSMrtfRydbhZwHI15w= k8s.io/component-base v0.24.2/go.mod h1:ucHwW76dajvQ9B7+zecZAP3BVqvrHoOxm8olHEg0nmM= -k8s.io/component-base v0.24.3 h1:u99WjuHYCRJjS1xeLOx72DdRaghuDnuMgueiGMFy1ec= -k8s.io/component-base v0.24.3/go.mod h1:bqom2IWN9Lj+vwAkPNOv2TflsP1PeVDIwIN0lRthxYY= -k8s.io/component-helpers v0.24.1/go.mod h1:q5Z1pWV/QfX9ThuNeywxasiwkLw9KsR4Q9TAOdb/Y3s= +k8s.io/component-base v0.24.4 h1:WEGRp06GBYVwxp5JdiRaJ1zkdOhrqucxRv/8IrABLG0= +k8s.io/component-base v0.24.4/go.mod h1:sWxkgcMfbYHadw0OJ0N+vIscd14/nqSIM2veCdg843o= +k8s.io/component-helpers v0.24.4/go.mod h1:xAHlOKU8rAjLgXWJEsueWLR1LDMThbaPf2YvgKpSyQ8= 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= @@ -1701,9 +1696,9 @@ k8s.io/kube-openapi v0.0.0-20200805222855-6aeccd4b50c6/go.mod h1:UuqjUnNftUyPE5H k8s.io/kube-openapi v0.0.0-20210421082810-95288971da7e/go.mod h1:vHXdDvt9+2spS2Rx9ql3I8tycm3H9FDfdUoIuKCefvw= k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42 h1:Gii5eqf+GmIEwGNKQYQClCayuJCe2/4fZUvF7VG99sU= k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42/go.mod h1:Z/45zLw8lUo4wdiUkI+v/ImEGAvu3WatcZl3lPMR4Rk= -k8s.io/kubectl v0.24.1 h1:gxcjHrnwntV1c+G/BHWVv4Mtk8CQJ0WTraElLBG+ddk= -k8s.io/kubectl v0.24.1/go.mod h1:NzFqQ50B004fHYWOfhHTrAm4TY6oGF5FAAL13LEaeUI= -k8s.io/metrics v0.24.1/go.mod h1:vMs5xpcOyY9D+/XVwlaw8oUHYCo6JTGBCZfyXOOkAhE= +k8s.io/kubectl v0.24.4 h1:fPEBkAV3/cu3BQVIUCXNngCCY62AlZ+2rkRVHcmJPn0= +k8s.io/kubectl v0.24.4/go.mod h1:AVyJzxUwA5UMGTDyKGL6nd6RRW36FbmAdtIDMhrZtW0= +k8s.io/metrics v0.24.4/go.mod h1:7D8Xm3DGZoJaiCS8+QA2EzdMuDlq0Y8SiOPUB/1BaGU= k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89/go.mod h1:sZAwmy6armz5eXlNoLmJcl4F1QuKu7sr+mFQ0byX7Ew= k8s.io/utils v0.0.0-20200729134348-d5654de09c73/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= From 35977ce6e413cfe26a718039def596222216dfc3 Mon Sep 17 00:00:00 2001 From: Aishwarya Harpale Date: Sat, 3 Sep 2022 00:03:34 -0400 Subject: [PATCH 04/15] Added rST styling instructions (#1587) * Added rST styling instructions * Fixed spelling error * Addressed Ivan and Pavan's review comments Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> --- docs/README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/README.md b/docs/README.md index 591d013e20..c366daeb04 100644 --- a/docs/README.md +++ b/docs/README.md @@ -39,3 +39,13 @@ These guidelines are derived from the [cheatsheet](https://github.com/kubernetes/community/blob/master/contributors/guide/style-guide.md#cheatsheet-content-design-formatting-and-language) in the Kubernetes community style guide. Take a look at some of their examples [here](https://github.com/kubernetes/community/blob/master/contributors/guide/style-guide.md#language-grammar-and-tone). + +## reStructured Text Styling Guide + +* Use `*` for bullet points. +* Section headers are created using underlines with text. Underlining hierarchy is: + * `*` for chapters + * `=` for sections + * `-` for subsections + * `^` for subsubsections + * `"` for paragraphs \ No newline at end of file From 6eb573635710c23ff3415f6634446f252592a1d4 Mon Sep 17 00:00:00 2001 From: kale-amruta <41624751+kale-amruta@users.noreply.github.com> Date: Mon, 5 Sep 2022 12:50:39 +0530 Subject: [PATCH 05/15] add blueprint to backup and restore etcd using kopia (#1601) * add v2 blueprint for etcd * address review comments * change node selector lable from etcd-backup to etcd-restore * address review comments * address review comments * address review comments --- .../etcd-incluster-ocp-blueprint.yaml | 122 ++++++++++++++++++ .../ocp/blueprint-v2/pv-etcd-backup.yaml | 15 +++ .../ocp/blueprint-v2/pvc-etcd-backup.yaml | 12 ++ 3 files changed, 149 insertions(+) create mode 100644 examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml create mode 100644 examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pv-etcd-backup.yaml create mode 100644 examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pvc-etcd-backup.yaml diff --git a/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml new file mode 100644 index 0000000000..09caff0289 --- /dev/null +++ b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml @@ -0,0 +1,122 @@ +apiVersion: cr.kanister.io/v1alpha1 +kind: Blueprint +metadata: + name: etcd-blueprint +actions: + backup: + outputArtifacts: + etcdBackup: + kopiaSnapshot: "{{ .Phases.uploadSnapshot.Output.kopiaOutput }}" + phases: + - func: KubeTask + name: takeSnapshot + args: + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + command: + - sh + - -o + - errexit + - -o + - pipefail + - -c + - | + export endpoints="{{ index .Object.data "endpoints" | toString | b64dec }}" + export labels="{{ index .Object.data "labels" | toString | b64dec }}" + export etcdns="{{ index .Object.data "etcdns" | toString | b64dec }}" + # Get a member of etcd cluster + ETCD_POD=$(kubectl get pods -n $etcdns -l $labels -ojsonpath='{.items[0].metadata.name}') + # exec the snapshot save command + kubectl exec -it -n $etcdns $ETCD_POD -c etcd -- sh -c "ETCDCTL_ENDPOINTS=$endpoints etcdctl snapshot save /tmp/etcd-backup.db" + # this pod name will be used to copy and remove the snapshot + kando output etcdPod $ETCD_POD + kando output etcdNS $etcdns + + - func: KubeTask + name: uploadSnapshot + args: + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + command: + - sh + - -o + - errexit + - -o + - pipefail + - -c + - | + BACKUP_LOCATION='etcd-backup.db.gz' + kubectl cp -c etcd {{ .Phases.takeSnapshot.Output.etcdNS }}/{{ .Phases.takeSnapshot.Output.etcdPod }}:/tmp/etcd-backup.db /tmp/etcd-backup.db + gzip -c /tmp/etcd-backup.db | kando location push --profile '{{ toJson .Profile }}' --path "${BACKUP_LOCATION}" --output-name "kopiaOutput" - + + - func: KubeTask + name: removeSnapshot + args: + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + command: + - sh + - -o + - errexit + - -o + - pipefail + - -c + - | + kubectl exec -it -n {{ .Phases.takeSnapshot.Output.etcdNS }} "{{ .Phases.takeSnapshot.Output.etcdPod }}" -c etcd -- sh -c "rm -rf /tmp/etcd-backup.db" + restore: + # This phase is not actualy performing restore of the etcd data store but is used + # to copy backup data to one of the leader nodes. It spins a pod on a leader node + # having label `etcd-restore`. The pod is used to download the backup file from the + # object store and copy it to the /mnt/data location of the PV mapped to PVC `pvc-etcd`. + # The PV's mount path is /mnt/data on leader node where the cluster-ocp-restore.sh + # script would be executed. + inputArtifactNames: + - etcdBackup + phases: + - func: PrepareData + name: copyFromObjectStore + args: + image: "ghcr.io/kanisterio/kanister-tools:0.81.0" + namespace: "{{ .Object.metadata.namespace }}" + podOverride: + nodeSelector: + etcd-restore: "true" + tolerations: + - key: "node-role.kubernetes.io/master" + operator: "Exists" + effect: "NoSchedule" + containers: + - name: container + securityContext: + privileged: true + volumes: + pvc-etcd: "/mnt/data" + command: + - bash + - -o + - errexit + - -o + - pipefail + - -c + - | + BACKUP_LOCATION='etcd-backup.db.gz' + kopia_snap='{{ .ArtifactsIn.etcdBackup.KopiaSnapshot }}' + kando location pull --profile '{{ toJson .Profile }}' --path "${BACKUP_LOCATION}" --kopia-snapshot "${kopia_snap}" - | gzip -d >> /tmp/etcd-backup.db + cp /tmp/etcd-backup.db /mnt/data + delete: + inputArtifactNames: + - etcdBackup + phases: + - func: KubeTask + name: deleteFromObjectStore + args: + namespace: "{{ .Object.metadata.namespace }}" + image: "ghcr.io/kanisterio/kanister-tools:0.81.0" + command: + - bash + - -o + - errexit + - -o + - pipefail + - -c + - | + backup_file_path='etcd-backup.db.gz' + kopia_snap='{{ .ArtifactsIn.etcdBackup.KopiaSnapshot }}' + kando location delete --profile '{{ toJson .Profile }}' --path "${backup_file_path}" --kopia-snapshot "${kopia_snap}" diff --git a/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pv-etcd-backup.yaml b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pv-etcd-backup.yaml new file mode 100644 index 0000000000..99f373c762 --- /dev/null +++ b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pv-etcd-backup.yaml @@ -0,0 +1,15 @@ +apiVersion: v1 +kind: PersistentVolume +metadata: + name: pv-etcd + labels: + type: local +spec: + storageClassName: default + capacity: + # storage should be changed based on the size of etcd snapshot + storage: 10Gi + accessModes: + - ReadWriteOnce + hostPath: + path: "/mnt/data" diff --git a/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pvc-etcd-backup.yaml b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pvc-etcd-backup.yaml new file mode 100644 index 0000000000..fb96273cea --- /dev/null +++ b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/pvc-etcd-backup.yaml @@ -0,0 +1,12 @@ +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: pvc-etcd +spec: + storageClassName: default + accessModes: + - ReadWriteOnce + resources: + requests: + # storage should be changed based on the size of etcd snapshot + storage: 10Gi From 09018c89c8a576a141d9090edd843da275e6f764 Mon Sep 17 00:00:00 2001 From: Le Tran Date: Mon, 5 Sep 2022 17:18:16 -0400 Subject: [PATCH 06/15] Add azure managed identity to azure package in blockstorage (#1615) * Add utilities functions for Azure authentication + unit test to be added for utilities Signed-off-by: Le Tran * Add an interface for Azure blockstorage to Authenticate credentials to be added fro authenticate Signed-off-by: Le Tran * Add an option to use MSI Authorizer for Azure Signed-off-by: Le Tran * Add guarding for nil + clean up comment Signed-off-by: Le Tran * Update gomod and gosum files Signed-off-by: Le Tran * Expose functions checking for creds Signed-off-by: Le Tran * Add authenticator for client secret credentials type Signed-off-by: Le Tran * Clean up according to PR reviews Signed-off-by: Le Tran * Remove CredAvailibility, authentication status will be inferred from error Signed-off-by: Le Tran * Address review comments Signed-off-by: Le Tran * Make Azure authenticator a public interface that can be used directly Signed-off-by: Le Tran Signed-off-by: Le Tran Co-authored-by: Le Tran Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- go.mod | 2 +- go.sum | 3 +- pkg/blockstorage/azure/auth.go | 108 +++++++++++++++++++++++++++ pkg/blockstorage/azure/auth_tests.go | 94 +++++++++++++++++++++++ pkg/blockstorage/azure/client.go | 41 ++++++---- 5 files changed, 231 insertions(+), 17 deletions(-) create mode 100644 pkg/blockstorage/azure/auth.go create mode 100644 pkg/blockstorage/azure/auth_tests.go diff --git a/go.mod b/go.mod index 714c6b1b1b..44d26507a9 100644 --- a/go.mod +++ b/go.mod @@ -14,6 +14,7 @@ replace ( require ( github.com/Azure/azure-sdk-for-go v66.0.0+incompatible github.com/Azure/go-autorest/autorest v0.11.28 + github.com/Azure/go-autorest/autorest/adal v0.9.21 github.com/Azure/go-autorest/autorest/azure/auth v0.5.11 github.com/Azure/go-autorest/autorest/to v0.4.0 github.com/BurntSushi/toml v1.2.0 @@ -72,7 +73,6 @@ require ( github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0 // indirect github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 // indirect github.com/Azure/go-autorest v14.2.0+incompatible // indirect - github.com/Azure/go-autorest/autorest/adal v0.9.18 // indirect github.com/Azure/go-autorest/autorest/azure/cli v0.4.5 // indirect github.com/Azure/go-autorest/autorest/date v0.3.0 // indirect github.com/Azure/go-autorest/autorest/validation v0.3.1 // indirect diff --git a/go.sum b/go.sum index c0f141ee69..dd7a7469ec 100644 --- a/go.sum +++ b/go.sum @@ -94,8 +94,9 @@ github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEg 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.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M= github.com/Azure/go-autorest/autorest/adal v0.9.16/go.mod h1:tGMin8I49Yij6AQ+rvV+Xa/zwxYQB5hmsd6DkfAx2+A= -github.com/Azure/go-autorest/autorest/adal v0.9.18 h1:kLnPsRjzZZUF3K5REu/Kc+qMQrvuza2bwSnNdhmzLfQ= github.com/Azure/go-autorest/autorest/adal v0.9.18/go.mod h1:XVVeme+LZwABT8K5Lc3hA4nAe8LDBVle26gTrguhhPQ= +github.com/Azure/go-autorest/autorest/adal v0.9.21 h1:jjQnVFXPfekaqb8vIsv2G1lxshoW+oGv4MDlhRtnYZk= +github.com/Azure/go-autorest/autorest/adal v0.9.21/go.mod h1:zua7mBUaCc5YnSLKYgGJR/w5ePdMDA6H56upLsHzA9U= github.com/Azure/go-autorest/autorest/azure/auth v0.5.11 h1:P6bYXFoao05z5uhOQzbC3Qd8JqF3jUoocoTeIxkp2cA= github.com/Azure/go-autorest/autorest/azure/auth v0.5.11/go.mod h1:84w/uV8E37feW2NCJ08uT9VBfjfUHpgLVnG2InYD6cg= github.com/Azure/go-autorest/autorest/azure/cli v0.4.5 h1:0W/yGmFdTIT77fvdlGZ0LMISoLHFJ7Tx4U0yeB+uFs4= diff --git a/pkg/blockstorage/azure/auth.go b/pkg/blockstorage/azure/auth.go new file mode 100644 index 0000000000..3156b73159 --- /dev/null +++ b/pkg/blockstorage/azure/auth.go @@ -0,0 +1,108 @@ +package azure + +import ( + "context" + + "github.com/Azure/go-autorest/autorest/adal" + "github.com/Azure/go-autorest/autorest/azure/auth" + "github.com/kanisterio/kanister/pkg/blockstorage" + "github.com/pkg/errors" +) + +// currently avaialble types: https://docs.microsoft.com/en-us/azure/developer/go/azure-sdk-authorization +// to be available with azidentity: https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azidentity#readme-credential-types +// determine if the combination of creds are client secret creds +func isClientCredsAvailable(config map[string]string) bool { + return (config[blockstorage.AzureTenantID] != "" && + config[blockstorage.AzureCientID] != "" && + config[blockstorage.AzureClentSecret] != "") +} + +// determine if the combination of creds are MSI creds +func isMSICredsAvailable(config map[string]string) bool { + return (config[blockstorage.AzureTenantID] == "" && + config[blockstorage.AzureCientID] != "" && + config[blockstorage.AzureClentSecret] == "") +} + +// Public interface to authenticate with different Azure credentials type +type AzureAuthenticator interface { + Authenticate(creds map[string]string) error +} + +func NewAzureAutheticator(config map[string]string) (AzureAuthenticator, error) { + switch { + case isMSICredsAvailable(config): + return &msiAuthenticator{}, nil + case isClientCredsAvailable(config): + return &clientSecretAuthenticator{}, nil + default: + return nil, errors.New("Fail to get an authenticator for provided creds combination") + } +} + +// authenticate with MSI creds +type msiAuthenticator struct{} + +func (m *msiAuthenticator) Authenticate(creds map[string]string) error { + // check if MSI endpoint is available + if !adal.MSIAvailable(context.Background(), nil) { + return errors.New("MSI endpoint is not supported") + } + // create a service principal token + msiConfig := auth.NewMSIConfig() + msiConfig.ClientID = creds[blockstorage.AzureCientID] + spt, err := msiConfig.ServicePrincipalToken() + if err != nil { + return errors.Wrap(err, "Failed to create a service principal token") + } + // network call to check for token + err = spt.Refresh() + if err != nil { + return errors.Wrap(err, "Failed to refresh token") + } + // creds passed authentication + return nil +} + +// authenticate with client secret creds +type clientSecretAuthenticator struct{} + +func (c *clientSecretAuthenticator) Authenticate(creds map[string]string) error { + credConfig, err := getCredConfigForAuth(creds) + if err != nil { + return errors.Wrap(err, "Failed to get Client Secret config") + } + // create a service principal token + spt, err := credConfig.ServicePrincipalToken() + if err != nil { + return errors.Wrap(err, "Failed to create a service principal token") + } + // network call to check for token + err = spt.Refresh() + if err != nil { + return errors.Wrap(err, "Failed to refresh token") + } + // creds passed authentication + return nil +} + +func getCredConfigForAuth(config map[string]string) (auth.ClientCredentialsConfig, error) { + tenantID, ok := config[blockstorage.AzureTenantID] + if !ok { + return auth.ClientCredentialsConfig{}, errors.New("Cannot get tenantID from config") + } + + clientID, ok := config[blockstorage.AzureCientID] + if !ok { + return auth.ClientCredentialsConfig{}, errors.New("Cannot get clientID from config") + } + + clientSecret, ok := config[blockstorage.AzureClentSecret] + if !ok { + return auth.ClientCredentialsConfig{}, errors.New("Cannot get clientSecret from config") + } + + credConfig := auth.NewClientCredentialsConfig(clientID, clientSecret, tenantID) + return credConfig, nil +} diff --git a/pkg/blockstorage/azure/auth_tests.go b/pkg/blockstorage/azure/auth_tests.go new file mode 100644 index 0000000000..20c76fe8e2 --- /dev/null +++ b/pkg/blockstorage/azure/auth_tests.go @@ -0,0 +1,94 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package azure + +import ( + "github.com/kanisterio/kanister/pkg/blockstorage" + . "gopkg.in/check.v1" +) + +type AuthSuite struct{} + +var _ = Suite(&AuthSuite{}) + +func (s *AuthSuite) SetUpSuite(c *C) { +} + +func (s *AuthSuite) TestIsClientCredsvailable(c *C) { + // success + config := map[string]string{ + blockstorage.AzureTenantID: "some-tenant-id", + blockstorage.AzureCientID: "some-client-id", + blockstorage.AzureClentSecret: "someclient-secret", + } + c.Assert(isClientCredsAvailable(config), Equals, true) + + // remove tenantID + delete(config, blockstorage.AzureTenantID) + c.Assert(isClientCredsAvailable(config), Equals, false) + + // remove client secret, only client ID left + delete(config, blockstorage.AzureClentSecret) + c.Assert(isClientCredsAvailable(config), Equals, false) +} + +func (s *AuthSuite) TestIsMSICredsAvailable(c *C) { + // success + config := map[string]string{ + blockstorage.AzureTenantID: "some-tenant-id", + blockstorage.AzureCientID: "some-client-id", + blockstorage.AzureClentSecret: "someclient-secret", + } + c.Assert(isMSICredsAvailable(config), Equals, false) + + // remove tenantID + delete(config, blockstorage.AzureTenantID) + c.Assert(isMSICredsAvailable(config), Equals, false) + + // remove client secret, only client ID left + delete(config, blockstorage.AzureClentSecret) + c.Assert(isMSICredsAvailable(config), Equals, true) +} + +func (s *AuthSuite) TestNewAzureAutheticator(c *C) { + // successful with client secret creds + config := map[string]string{ + blockstorage.AzureTenantID: "some-tenant-id", + blockstorage.AzureCientID: "some-client-id", + blockstorage.AzureClentSecret: "some-client-secret", + } + authenticator, err := NewAzureAutheticator(config) + c.Assert(err, IsNil) + _, ok := authenticator.(*clientSecretAuthenticator) + c.Assert(ok, Equals, true) + + // successful with msi creds + config = map[string]string{ + blockstorage.AzureCientID: "some-client-id", + } + authenticator, err = NewAzureAutheticator(config) + c.Assert(err, IsNil) + _, ok = authenticator.(*msiAuthenticator) + c.Assert(ok, Equals, true) + + // unsuccessful with an undefined combo of creds + config = map[string]string{ + blockstorage.AzureCientID: "some-client-id", + blockstorage.AzureClentSecret: "some-client-secret", + } + authenticator, err = NewAzureAutheticator(config) + c.Assert(err, NotNil) + c.Assert(authenticator, IsNil) +} diff --git a/pkg/blockstorage/azure/client.go b/pkg/blockstorage/azure/client.go index 333b29a144..5233157f1b 100644 --- a/pkg/blockstorage/azure/client.go +++ b/pkg/blockstorage/azure/client.go @@ -98,15 +98,23 @@ func NewClient(ctx context.Context, config map[string]string) (*Client, error) { // nolint:unparam func getAuthorizer(env azure.Environment, config map[string]string) (*autorest.BearerAuthorizer, error) { + if isClientCredsAvailable(config) { + return getClientCredsAuthorizer(env, config) + } else if isMSICredsAvailable(config) { + return getMSIsAuthorizer(config) + } + return nil, errors.New("Missing credentials, or credential type not supported") +} + +func getClientCredsAuthorizer(env azure.Environment, config map[string]string) (*autorest.BearerAuthorizer, error) { credConfig, err := getCredConfig(env, config) if err != nil { - return nil, errors.Wrap(err, "Failed to get Azure ClientCredentialsConfig") + return nil, errors.Wrap(err, "Failed to get Azure Client Credentials Config") } a, err := credConfig.Authorizer() if err != nil { - return nil, errors.Wrap(err, "Failed to get Azure authorizer") + return nil, errors.Wrap(err, "Failed to get Azure Client Credentials authorizer") } - ba, ok := a.(*autorest.BearerAuthorizer) if !ok { return nil, errors.New("Failed to get Azure authorizer") @@ -114,23 +122,26 @@ func getAuthorizer(env azure.Environment, config map[string]string) (*autorest.B return ba, nil } -func getCredConfig(env azure.Environment, config map[string]string) (auth.ClientCredentialsConfig, error) { - tenantID, ok := config[blockstorage.AzureTenantID] - if !ok { - return auth.ClientCredentialsConfig{}, errors.New("Cannot get tenantID from config") +func getMSIsAuthorizer(config map[string]string) (*autorest.BearerAuthorizer, error) { + msiConfig := auth.NewMSIConfig() + msiConfig.ClientID = config[blockstorage.AzureCientID] + a, err := msiConfig.Authorizer() + if err != nil { + return nil, errors.Wrap(err, "Failed to get Azure MSI authorizer") } - - clientID, ok := config[blockstorage.AzureCientID] + ba, ok := a.(*autorest.BearerAuthorizer) if !ok { - return auth.ClientCredentialsConfig{}, errors.New("Cannot get clientID from config") + return nil, errors.New("Failed to get Azure authorizer") } + return ba, nil +} - clientSecret, ok := config[blockstorage.AzureClentSecret] - if !ok { - return auth.ClientCredentialsConfig{}, errors.New("Cannot get clientSecret from config") +func getCredConfig(env azure.Environment, config map[string]string) (auth.ClientCredentialsConfig, error) { + credConfig, err := getCredConfigForAuth(config) + if err != nil { + return auth.ClientCredentialsConfig{}, err } - - credConfig := auth.NewClientCredentialsConfig(clientID, clientSecret, tenantID) + var ok bool if credConfig.AADEndpoint, ok = config[blockstorage.AzureActiveDirEndpoint]; !ok || credConfig.AADEndpoint == "" { credConfig.AADEndpoint = env.ActiveDirectoryEndpoint config[blockstorage.AzureActiveDirEndpoint] = credConfig.AADEndpoint From 0503369a384d8a9b7e910626ff8e5f6c0dea52d4 Mon Sep 17 00:00:00 2001 From: Ankit Jain Date: Wed, 7 Sep 2022 12:26:06 +0530 Subject: [PATCH 07/15] Add workflow to build and consume kopia binary in kanister-tools (#1611) * Add workflow to build and consume kopia binary in kanister-tools Signed-off-by: Ankit Jain * Address review comments - update Copyright comment * Revert changes in kanister-tools Dockerfile * Remove timestamp for Dockerfile to avoid sha update on every build * Add Github Action to update kopia image and raise PR to update Kanister tools Dockerfile * Revert "Add Github Action to update kopia image and raise PR to update Kanister tools Dockerfile" This reverts commit 5434adb8ac95128c08224ed2b44237489b38c3c2. * Add comment, update variable name * Address review comment - remove duplicate, unnecessary lines * Update kopia build Dockerfile to use goreleaser * Use goreleaser docker image to get binary * Update base image versions Signed-off-by: Ankit Jain Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> --- .github/workflows/main.yaml | 1 + Makefile | 8 +++++++ build/update_kopia_image.sh | 36 ++++++++++++++++++++++++++++ docker/kopia-build/Dockerfile | 45 +++++++++++++++++++++++++++++++++++ 4 files changed, 90 insertions(+) create mode 100644 build/update_kopia_image.sh create mode 100644 docker/kopia-build/Dockerfile diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index cdc74bc9b6..4a55986dc2 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -87,5 +87,6 @@ jobs: username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - run: tar -xvf ./src.tar.gz + - run: make update-kopia-image - run: make release-snapshot - run: ./build/push_images.sh diff --git a/Makefile b/Makefile index f269194975..e4113f25c4 100644 --- a/Makefile +++ b/Makefile @@ -41,6 +41,11 @@ DOCKER_CONFIG ?= "$(HOME)/.docker" # Mention the vm-driver that should be used to install OpenShift vm-driver ?= "kvm" + +# Refers to https://github.com/kopia/kopia/commit/317cc36892707ab9bdc5f6e4dea567d1e638a070 +KOPIA_COMMIT_ID ?= "317cc36" + +KOPIA_REPO ?= "kopia" # Default OCP version in which the OpenShift apps are going to run ocp_version ?= "4.10" ### @@ -257,6 +262,9 @@ gorelease: release-snapshot: @$(MAKE) run CMD='-c "GORELEASER_CURRENT_TAG=v9.99.9-dev goreleaser --debug release --rm-dist --snapshot"' +update-kopia-image: + @/bin/bash ./build/update_kopia_image.sh $(KOPIA_COMMIT_ID) $(KOPIA_REPO) + go-mod-download: @$(MAKE) run CMD='-c "go mod download"' diff --git a/build/update_kopia_image.sh b/build/update_kopia_image.sh new file mode 100644 index 0000000000..4fadb12303 --- /dev/null +++ b/build/update_kopia_image.sh @@ -0,0 +1,36 @@ +#!/bin/bash + +# Copyright 2022 The Kanister Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +set -o errexit +set -o nounset + +IMAGE_REGISTRY="ghcr.io/kanisterio" + +readonly COMMIT_ID=${1:?"Commit id to build kopia image not specified"} +readonly KOPIA_REPO_ORG=${2-:"kopia"} +readonly IMAGE_TYPE=alpine +readonly IMAGE_BUILD_VERSION="${COMMIT_ID}" +readonly GH_PACKAGE_TARGET="${IMAGE_REGISTRY}/kopia" +readonly TAG="${IMAGE_TYPE}-${IMAGE_BUILD_VERSION}" + + +docker build \ + --tag "${GH_PACKAGE_TARGET}:${TAG}" \ + --build-arg "kopiaBuildCommit=${COMMIT_ID}" \ + --build-arg "kopiaRepoOrg=${KOPIA_REPO_ORG}" \ + --file ./docker/kopia-build/Dockerfile . + +docker push ${GH_PACKAGE_TARGET}:$TAG diff --git a/docker/kopia-build/Dockerfile b/docker/kopia-build/Dockerfile new file mode 100644 index 0000000000..859c472cbe --- /dev/null +++ b/docker/kopia-build/Dockerfile @@ -0,0 +1,45 @@ +FROM golang:1.19.1-alpine3.16 AS builder + +ARG kopiaBuildCommit +ARG kopiaRepoOrg + +RUN apk add git + +WORKDIR / + +RUN git clone https://github.com/${kopiaRepoOrg}/kopia.git + +ENV GITHUB_REPOSITORY=https://github.com/${kopiaRepoOrg}/kopia + +WORKDIR /kopia + +# Build kopia binary from specific commit +RUN git checkout ${kopiaBuildCommit} +# Refers to goreleaser/goreleaser:v1.11.2 +COPY --from=docker.io/goreleaser/goreleaser@sha256:b13418f20019fffb29797aff3d03f5e9ca84cea93634f4169a7ed603a95ab198 \ + /usr/bin/goreleaser /usr/bin/goreleaser +RUN goreleaser build --output=. --rm-dist --single-target + +RUN adduser -D kopia && addgroup kopia kopia +USER kopia:kopia + +COPY --chown=kopia . /kopia + +FROM alpine:3.16 + +WORKDIR /kopia + +# Add CA certs +RUN apk add --no-cache --verbose ca-certificates && \ + rm -rf /var/cache/apk/* && \ + adduser -D kopia && addgroup kopia kopia && \ + chown kopia /kopia + +USER kopia:kopia + +ENTRYPOINT [ "/kopia/kopia" ] + +LABEL imageVersion="${imageVersion}" +LABEL kopiaBuildCommit="${kopiaBuildCommit}" + +COPY --from=builder --chown=kopia:kopia /kopia/kopia /kopia/kopia From b238f541b3683c8354db06d6e3f57d6e11056eb9 Mon Sep 17 00:00:00 2001 From: Ankit Jain Date: Wed, 7 Sep 2022 14:24:05 +0530 Subject: [PATCH 08/15] Kopia upgrade custom commit (#1567) * Replace kopia version with custom commit * Update virtualfs implementation as per changes upstream * Update dependency again after resolving conflicts Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- go.mod | 21 ++-- go.sum | 225 +++++++---------------------------- pkg/kopia/snapshot/stream.go | 2 +- pkg/kopia/utils.go | 8 +- pkg/virtualfs/dir_entry.go | 2 + pkg/virtualfs/directory.go | 34 ++++-- 6 files changed, 82 insertions(+), 210 deletions(-) diff --git a/go.mod b/go.mod index 44d26507a9..10c7a5dc44 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,7 @@ go 1.17 replace ( github.com/googleapis/gnostic => github.com/googleapis/gnostic v0.4.1 github.com/graymeta/stow => github.com/kastenhq/stow v0.2.6-kasten.1.0.20220726203146-8a90401257d4 - github.com/kopia/kopia => github.com/kastenhq/kopia v0.0.0-20220727034500-33ea94bd7728 + github.com/kopia/kopia => github.com/kastenhq/kopia v0.0.0-20220725040357-122ff606ff45 github.com/rook/operator-kit => github.com/kastenhq/operator-kit v0.0.0-20180316185208-859e831cc18d gopkg.in/check.v1 => github.com/kastenhq/check v0.0.0-20180626002341-0264cfcea734 ) @@ -47,8 +47,8 @@ require ( github.com/spf13/cobra v1.5.0 github.com/vmware/govmomi v0.28.0 go.uber.org/zap v1.21.0 - golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb - google.golang.org/api v0.85.0 + golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2 + google.golang.org/api v0.86.0 gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637 @@ -64,10 +64,10 @@ require ( ) require ( - cloud.google.com/go v0.102.0 // indirect + cloud.google.com/go v0.102.1 // indirect cloud.google.com/go/compute v1.7.0 // indirect cloud.google.com/go/iam v0.3.0 // indirect - cloud.google.com/go/storage v1.22.1 // indirect + cloud.google.com/go/storage v1.23.0 // indirect github.com/Azure/azure-sdk-for-go/sdk/azcore v0.22.0 // indirect github.com/Azure/azure-sdk-for-go/sdk/internal v0.9.1 // indirect github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0 // indirect @@ -92,6 +92,7 @@ require ( github.com/dgrijalva/jwt-go v3.2.0+incompatible // indirect github.com/dimchansky/utfbom v1.1.1 // indirect github.com/dustin/go-humanize v1.0.0 // indirect + github.com/edsrzf/mmap-go v1.1.0 // indirect github.com/elazarl/goproxy v0.0.0-20190711103511-473e67f1d7d2 // indirect github.com/emicklei/go-restful v2.9.5+incompatible // indirect github.com/evanphx/json-patch v4.12.0+incompatible // indirect @@ -105,7 +106,7 @@ require ( github.com/go-openapi/jsonreference v0.19.5 // indirect github.com/go-openapi/swag v0.19.14 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang-jwt/jwt/v4 v4.4.1 // indirect + github.com/golang-jwt/jwt/v4 v4.4.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.2 // indirect github.com/google/btree v1.0.1 // indirect @@ -132,7 +133,7 @@ require ( github.com/mailru/easyjson v0.7.7 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect github.com/minio/md5-simd v1.1.2 // indirect - github.com/minio/minio-go/v7 v7.0.27 // indirect + github.com/minio/minio-go/v7 v7.0.31 // indirect github.com/minio/sha256-simd v1.0.0 // indirect github.com/mitchellh/copystructure v1.0.0 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect @@ -163,11 +164,13 @@ require ( github.com/zeebo/blake3 v0.2.3 // indirect go.mongodb.org/mongo-driver v1.10.1 // indirect go.opencensus.io v0.23.0 // indirect + go.opentelemetry.io/otel v0.20.0 // indirect + go.opentelemetry.io/otel/metric v0.20.0 // indirect + go.opentelemetry.io/otel/trace v0.20.0 // indirect go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5 // indirect go.uber.org/atomic v1.9.0 // indirect go.uber.org/multierr v1.8.0 // indirect golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa // indirect - golang.org/x/exp v0.0.0-20220328175248-053ad81199eb // indirect golang.org/x/net v0.0.0-20220725212005-46097bf591d3 // indirect golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f // indirect golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f // indirect @@ -177,7 +180,7 @@ require ( golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f // indirect gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect google.golang.org/appengine v1.6.7 // indirect - google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad // indirect + google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f // indirect google.golang.org/grpc v1.47.0 // indirect google.golang.org/protobuf v1.28.1 // indirect gopkg.in/inf.v0 v0.9.1 // indirect diff --git a/go.sum b/go.sum index dd7a7469ec..53834234f9 100644 --- a/go.sum +++ b/go.sum @@ -27,10 +27,10 @@ cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+Y cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4= cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc= cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA= -cloud.google.com/go v0.100.1/go.mod h1:fs4QogzfH5n2pBXBP9vRiU+eCny7lD2vmFZy79Iuw1U= cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w99A= -cloud.google.com/go v0.102.0 h1:DAq3r8y4mDgyB/ZPJ9v/5VJNqjgJAxTn6ZYLlUywOu8= cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= +cloud.google.com/go v0.102.1 h1:vpK6iQWv/2uUeFJth4/cBHsQAGjn1iIE6AAlxipRaA0= +cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= @@ -38,7 +38,6 @@ cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUM cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= cloud.google.com/go/compute v0.1.0/go.mod h1:GAesmwr110a34z04OlxYkATPBEfVhkymfTBXtfbBFow= -cloud.google.com/go/compute v1.2.0/go.mod h1:xlogom/6gr8RJGBe7nT2eGsQYAFUbbv8dbC29qE3Xmw= cloud.google.com/go/compute v1.3.0/go.mod h1:cCZiE1NHEtai4wiufUhW8I8S1JKkAnhnQJWM7YD99wM= cloud.google.com/go/compute v1.5.0/go.mod h1:9SMHyhJlzhlkJqrPAc839t2BZFTSk6Jdj6mkzQJeu0M= cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz/FMzPu0s= @@ -48,7 +47,6 @@ cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQH cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk= -cloud.google.com/go/iam v0.1.1/go.mod h1:CKqrcnI/suGpybEHxZ7BMehL0oA4LpdyJdUlTl9jVMw= cloud.google.com/go/iam v0.3.0 h1:exkAomrVUuzx9kWFI1wm3KI0uoDeUFPB4kKGzx6x+Gc= cloud.google.com/go/iam v0.3.0/go.mod h1:XzJPvDayI+9zsASAFO68Hk07u3z+f+JrT2xXNdp4bnY= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= @@ -60,11 +58,10 @@ cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0Zeo cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= -cloud.google.com/go/storage v1.21.0/go.mod h1:XmRlxkgPjlBONznT2dDUU/5XlpU2OjMnKuqnZI01LAA= -cloud.google.com/go/storage v1.22.1 h1:F6IlQJZrZM++apn9V5/VfS3gbTUYg98PS3EMQAzqtfg= cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= +cloud.google.com/go/storage v1.23.0 h1:wWRIaDURQA8xxHguFCshYepGlrWIrbBnAmc7wfg07qY= +cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= -dmitri.shuralyov.com/gpu/mtl v0.0.0-20201218220906-28db891af037/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= github.com/Azure/azure-pipeline-go v0.2.3 h1:7U9HBg1JFK3jHl5qmo4CTZKFTVgMwdFHMVtCdfBE21U= github.com/Azure/azure-pipeline-go v0.2.3/go.mod h1:x841ezTBIMG6O3lAcl8ATHnsOPVl2bqk7S3ta6S6u4k= github.com/Azure/azure-sdk-for-go v66.0.0+incompatible h1:bmmC38SlE8/E81nNADlgmVGurPWMHDX2YNXVQMrBpEE= @@ -77,8 +74,8 @@ github.com/Azure/azure-sdk-for-go/sdk/internal v0.9.1 h1:sLZ/Y+P/5RRtsXWylBjB5lk github.com/Azure/azure-sdk-for-go/sdk/internal v0.9.1/go.mod h1:KLF4gFr6DcKFZwSuH8w8yEK6DpFl3LP5rhdvAb7Yz5I= github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0 h1:Px2UA+2RvSSvv+RvJNuUB6n7rs5Wsel4dXLe90Um2n4= github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0/go.mod h1:tPaiy8S5bQ+S5sOiDlINkp7+Ef339+Nz5L5XO+cnOHo= -github.com/Azure/azure-storage-blob-go v0.14.0 h1:1BCg74AmVdYwO3dlKwtFU1V0wU2PZdREkXvAmZJRUlM= -github.com/Azure/azure-storage-blob-go v0.14.0/go.mod h1:SMqIBi+SuiQH32bvyjngEewEeXoPfKMgWlBDaYf6fck= +github.com/Azure/azure-storage-blob-go v0.15.0 h1:rXtgp8tN1p29GvpGgfJetavIG0V7OgcSXPpwp3tx6qk= +github.com/Azure/azure-storage-blob-go v0.15.0/go.mod h1:vbjsVbX0dlxnRc4FFMPsS9BsJWPcne7GB7onqlPvz58= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 h1:UQHMgLO+TxOElx5B5HZ4hJQsoJ/PvUvKRhJHDQXO8P8= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs= @@ -131,7 +128,6 @@ github.com/IBM-Cloud/ibm-cloud-cli-sdk v0.3.0 h1:gVDpgO5vjgBdr+dSCvHf13WCC2vLsfQ github.com/IBM-Cloud/ibm-cloud-cli-sdk v0.3.0/go.mod h1:RiUvKuHKTBmBApDMUQzBL14pQUGKcx/IioKQPIcRQjs= github.com/IBM/ibmcloud-storage-volume-lib v1.0.2-beta02.0.20190828145158-1da4543a60af h1:1L8wyNvXB1hzvgb8qfJXX/Y9DhFcUGHGhvdw9c30/lY= github.com/IBM/ibmcloud-storage-volume-lib v1.0.2-beta02.0.20190828145158-1da4543a60af/go.mod h1:xFXCpJFg3Nj3HDgP79Uq/t+DTVFH/9lKxia5e6t49pg= -github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= github.com/MakeNowJust/heredoc v0.0.0-20170808103936-bb23615498cd h1:sjQovDkwrZp8u+gxLtPgKGjk5hCxuy2hrRejBTA9xFU= github.com/MakeNowJust/heredoc v0.0.0-20170808103936-bb23615498cd/go.mod h1:64YHyfSL2R96J44Nlwm39UHepQbyR5q10x7iYa1ks2E= github.com/Masterminds/goutils v1.1.0 h1:zukEsf/1JZwCMgHiK3GZftabmxiCw4apj3a28RPBiVg= @@ -149,12 +145,8 @@ github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbt github.com/PuerkitoBio/urlesc v0.0.0-20160726150825-5bd2802263f2/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 h1:d+Bc7a5rLufV/sSk/8dngufqelfh6jnri85riMAaF/M= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= -github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= -github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= -github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= github.com/a8m/tree v0.0.0-20210115125333-10a5fd5b637d/go.mod h1:FSdwKX97koS5efgm8WevNf7XS3PqtyFkKDDXrz778cg= -github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= -github.com/alecthomas/kingpin v0.0.0-20200323085623-b6657d9477a6/go.mod h1:b6br6/pDFSfMkBgC96TbpOji05q5pa+v5rIlS0Y6XtI= +github.com/alecthomas/kingpin v1.3.8-0.20220615105907-eae6867f4166/go.mod h1:OaxaNlTGWmknTg9pwAYYTkaU/cXZYeLGizE8aey/CXU= 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= @@ -164,24 +156,18 @@ github.com/alecthomas/units v0.0.0-20210927113745-59d0afb8317a/go.mod h1:OMCwj8V github.com/alessio/shellescape v1.4.1/go.mod h1:PZAiSCk0LJaZkiCSkPv8qIobYglO3FPpyFjDCtHLS30= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/antlr/antlr4/runtime/Go/antlr v0.0.0-20210826220005-b48c857c3a0e/go.mod h1:F7bn7fEU90QkQ3tnmaTx3LTKLEDqnwWODIYppRQ5hnY= -github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= -github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= -github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a/go.mod h1:DAHtR1m6lCRdSC2Tm3DSWRPvIPr6xNKyeHdqDQSQT+A= github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/asaskevich/govalidator v0.0.0-20200907205600-7a23bdc65eef h1:46PFijGLmAjMPwCCCo7Jf0W6f9slllCkkv7vyc1yOSg= github.com/asaskevich/govalidator v0.0.0-20200907205600-7a23bdc65eef/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= -github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQwij/eHl5CU= github.com/aws/aws-sdk-go v1.23.4/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= -github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= -github.com/aws/aws-sdk-go v1.43.26/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo= +github.com/aws/aws-sdk-go v1.44.51/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo= github.com/aws/aws-sdk-go v1.44.78 h1:B/V28YXFLmxjMQqJeyCt7NDRIJdep0sJixIAeee2BF0= github.com/aws/aws-sdk-go v1.44.78/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo= -github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= github.com/benbjohnson/clock v1.0.3/go.mod h1:bGMdMPoPVvcYyt1gHDf4J2KE153Yf9BuiUKYMaxlTDM= github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8= github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= @@ -193,8 +179,6 @@ github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kB github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84= github.com/bketelsen/crypt v0.0.4/go.mod h1:aI6NrJ0pMGgvZKL1iVgXLnfIFJtfV+bKCoqOes/6LfM= github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= -github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= -github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/certifi/gocertifi v0.0.0-20191021191039-0944d244cd40/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= github.com/certifi/gocertifi v0.0.0-20200922220541-2c3bb06c6054/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= @@ -209,13 +193,12 @@ github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927 h1:SKI1/fuSdodxmNNyV github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927/go.mod h1:h/aW8ynjgkuj+NQRlZcDbAbM1ORAbXjXX77sX7T289U= github.com/chmduquesne/rollinghash v4.0.0+incompatible h1:hnREQO+DXjqIw3rUTzWN7/+Dpw+N5Um8zpKV0JOEgbo= github.com/chmduquesne/rollinghash v4.0.0+incompatible/go.mod h1:Uc2I36RRfTAf7Dge82bi3RU0OQUmXT9iweIcPqvr8A0= -github.com/chromedp/cdproto v0.0.0-20220321060548-7bc2623472b3/go.mod h1:5Y4sD/eXpwrChIuxhSr/G20n9CdbCmoerOHnuAf0Zr0= -github.com/chromedp/chromedp v0.8.0/go.mod h1:odCVV9o9i7HUKwHMFz9Y7T6s4Kbcz4GOyPlwKWopI9Q= +github.com/chromedp/cdproto v0.0.0-20220515234810-83d799542a04/go.mod h1:5Y4sD/eXpwrChIuxhSr/G20n9CdbCmoerOHnuAf0Zr0= +github.com/chromedp/chromedp v0.8.2/go.mod h1:vpbCNtfYeOUo2q5reuwX6ZmPpbHRf5PZfAqNR2ObB+g= github.com/chromedp/sysutil v1.0.0/go.mod h1:kgWmDdq8fTzXYcKIBqIYvRRTnYb9aNS9moAV0xufSww= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= -github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -226,26 +209,19 @@ github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWH github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= github.com/cockroachdb/datadriven v0.0.0-20200714090401-bf6692d28da5/go.mod h1:h6jFvWxBdQXxjopDMZyH2UVceIRfR84bdzbkoKrsWNo= github.com/cockroachdb/errors v1.2.4/go.mod h1:rQD95gz6FARkaKkQXUksEje/d9a6wBJoCr5oaCLELYA= github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= -github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= github.com/coreos/go-oidc v2.1.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= -github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= -github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= -github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/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/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= @@ -269,21 +245,17 @@ github.com/docker/spdystream v0.0.0-20160310174837-449fdfce4d96/go.mod h1:Qh8CwZ github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= github.com/dougm/pretty v0.0.0-20171025230240-2ee9d7453c02 h1:tR3jsKPiO/mb6ntzk/dJlHZtm37CPfVp1C9KIo534+4= github.com/dougm/pretty v0.0.0-20171025230240-2ee9d7453c02/go.mod h1:7NQ3kWOx2cZOSjtcveTa5nqupVr2s6/83sG+rTlI7uA= -github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustinkirkland/golang-petname v0.0.0-20191129215211-8e5a1ed0cff0/go.mod h1:V+Qd57rJe8gd4eiGzZyg4h54VLHmYVVw54iMnlAMrF8= -github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs= -github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU= -github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I= -github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M= +github.com/edsrzf/mmap-go v1.1.0 h1:6EUwBLQ/Mcr1EYLE4Tn1VdW1A4ckqCQWZBw8Hr0kjpQ= +github.com/edsrzf/mmap-go v1.1.0/go.mod h1:19H/e8pUPLicwkyNgOykDXkJ9F0MHE+Z52B8EIth78Q= github.com/elazarl/goproxy v0.0.0-20180725130230-947c36da3153/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc= github.com/elazarl/goproxy v0.0.0-20190711103511-473e67f1d7d2 h1:aZtFdDNWY/yH86JPR2WX/PN63635VsE/f/nXNPAbYxY= github.com/elazarl/goproxy v0.0.0-20190711103511-473e67f1d7d2/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc= github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= github.com/emicklei/go-restful v2.9.5+incompatible h1:spTtZBk5DYEvbxMVutUuTyh1Ao2r4iyvLdACqsl/Ljk= github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= -github.com/envoyproxy/go-control-plane v0.6.9/go.mod h1:SBwIajubJHhxtWwsL9s8ss4safvEdbitLhGGK48rN6g= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= @@ -311,8 +283,6 @@ github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSw github.com/foomo/htpasswd v0.0.0-20200116085101-e3a90e78da9c/go.mod h1:SHawtolbB0ZOFoRWgDwakX5WpwuIWAK88bUXVZqK0Ss= github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= -github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4= -github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2rbfLwlschooIH4+wKKDR4Pdxhh+TRoA20= github.com/frankban/quicktest v1.13.1 h1:xVm/f9seEhZFL9+n5kv5XLrGwy6elc4V9v/XFY2vmd8= github.com/frankban/quicktest v1.13.1/go.mod h1:NeW+ay9A/U67EYXNFA1nPE8e/tnQv/09mUdL/ijj8og= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= @@ -333,7 +303,6 @@ github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2 github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgOZ7o= github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-kit/log v0.2.0/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= @@ -342,7 +311,6 @@ github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas= github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= -github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= github.com/go-logr/logr v1.2.0 h1:QK40JKJyMdUDz+h+xvCsru/bJhvG0UxvePV0ufL/AcE= github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/zapr v1.2.0 h1:n4JnPI1T3Qq1SFEi/F8rwLrZERp2bso19PJZDB9dayk= @@ -368,7 +336,6 @@ github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= github.com/go-openapi/swag v0.19.14 h1:gm3vOOXfiuw5i9p5N9xJvfjvuofpyvLA9Wr6QfK5Fng= github.com/go-openapi/swag v0.19.14/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= -github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE= github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= @@ -381,17 +348,15 @@ github.com/godbus/dbus/v5 v5.0.6/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5x github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v4.2.0+incompatible h1:yyYWMnhkhrKwwr8gAOcOCYxOOscHgDS9yZgBrnJfGa0= github.com/gofrs/uuid v4.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= -github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= github.com/golang-jwt/jwt/v4 v4.2.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= -github.com/golang-jwt/jwt/v4 v4.4.1 h1:pC5DB52sCeK48Wlb9oPcdhnjkz1TKt1D/P7WKJ0kUcQ= -github.com/golang-jwt/jwt/v4 v4.4.1/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= +github.com/golang-jwt/jwt/v4 v4.4.2 h1:rcc4lwaZgFMCZ5jxF9ABolDcIHdBytAFgqFPbSJQAYs= +github.com/golang-jwt/jwt/v4 v4.4.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -430,7 +395,6 @@ github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaS github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= -github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golangplus/testing v0.0.0-20180327235837-af21d9c3145e/go.mod h1:0AA//k/eakGydO4jKRoRL2j92ZKSzTgj9tclaCrvXHk= @@ -487,7 +451,6 @@ github.com/google/readahead v0.0.0-20161222183148-eaceba169032/go.mod h1:qYysrqQ github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 h1:El6M4kTTCOh6aBiKaUGG7oYTSPP8MxqL4YI3kZKwcP4= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= -github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= @@ -509,26 +472,18 @@ github.com/googleapis/go-type-adapters v1.0.0 h1:9XdMn+d/G57qq1s8dNc5IesGCXHf6V2 github.com/googleapis/go-type-adapters v1.0.0/go.mod h1:zHW75FOG2aur7gAO2B+MLby+cLsWGBF62rFAi7WjWO4= github.com/gophercloud/gophercloud v0.1.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEoIEcSTewFxm1c5g8= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= -github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= -github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= -github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= -github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7 h1:pdN6V1QBWetyv/0+wjACpqVH+eVULgEjkurDLq3goeM= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= -github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= -github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hanwen/go-fuse/v2 v2.1.1-0.20220112183258-f57e95bda82d/go.mod h1:B1nGE/6RBFyBRC1RRnf23UpwCdyJ31eukw34oAKukAc= github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q= -github.com/hashicorp/consul/api v1.3.0/go.mod h1:MmDNSzIMUjNpY/mQ398R4bk2FnqQLoPndWW5VkKPlCE= github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= -github.com/hashicorp/consul/sdk v0.3.0/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= @@ -539,7 +494,6 @@ github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerX github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go-version v1.5.0 h1:O293SZ2Eg+AAYijkVK3jR786Am1bhDEh2GHT0tIVE5E= github.com/hashicorp/go-version v1.5.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90= @@ -555,7 +509,6 @@ github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/J github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huandu/xstrings v1.2.0 h1:yPeWdRnmynF7p+lLYz0H2tthW9lqhMJrQV/U7yy4wX0= github.com/huandu/xstrings v1.2.0/go.mod h1:DvyZB1rfVYsBIigL8HwpZgxHwXozlTgGqn63UyNX5k4= -github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmKTg= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= @@ -563,7 +516,6 @@ github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= github.com/jarcoal/httpmock v1.0.4 h1:jp+dy/+nonJE4g4xbVtl9QdrUNbn6/3hDT5R4nDIZnA= github.com/jarcoal/httpmock v1.0.4/go.mod h1:ATjnClrvW/3tijVmpL/va5Z3aAyGvqU3gCT8nX0Txik= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= @@ -579,7 +531,6 @@ github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFF github.com/jpillora/backoff v1.0.0 h1:uvFg412JmmHBHw7iwprIxkPMI+sGQ4kzOWsMeHnm2EA= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.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/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= @@ -592,8 +543,8 @@ github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7V github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/kastenhq/check v0.0.0-20180626002341-0264cfcea734 h1:qulsCaCv+O2y9/sQ9nd5KChnAgFOWakTHQ9ZADjs6DQ= github.com/kastenhq/check v0.0.0-20180626002341-0264cfcea734/go.mod h1:rdqSnvOJuKCPFW/h2rVLuXOAkRnHHdp9PZcKx4HCoDM= -github.com/kastenhq/kopia v0.0.0-20220727034500-33ea94bd7728 h1:m1Z5duuOde6EG1UAREyLXDuCzeb2ge7fV7uoy5YI5ck= -github.com/kastenhq/kopia v0.0.0-20220727034500-33ea94bd7728/go.mod h1:oArsqs1knI99UVDkDgNxg43t0kJj7k9KUUdXpBJgmQ8= +github.com/kastenhq/kopia v0.0.0-20220725040357-122ff606ff45 h1:nTYNY7bTTj9tnJ5KcNkBErcp4uUygwIXeVaLeCGbpq0= +github.com/kastenhq/kopia v0.0.0-20220725040357-122ff606ff45/go.mod h1:8XNihoIMqOn/ov6TS/543Ham5/PSD1yol/SadYJS9dc= github.com/kastenhq/stow v0.2.6-kasten.1.0.20220726203146-8a90401257d4 h1:MuAfIUYqmW0bIxyltt4EIAgKSV3GxvEwZzlqBqGLQko= github.com/kastenhq/stow v0.2.6-kasten.1.0.20220726203146-8a90401257d4/go.mod h1:6+N3Bn9Whpb+bnRFQ2A2kAyAUiYvYM0+N5bArNd4K8s= github.com/kelseyhightower/envconfig v1.4.0 h1:Im6hONhd3pLkfDFsbRgu68RDNkGF1r3dvMUtDTo2cv8= @@ -604,6 +555,7 @@ github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.13.5/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= +github.com/klauspost/compress v1.15.7/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= github.com/klauspost/compress v1.15.9 h1:wKRjX6JRtDdrE9qwa4b/Cip7ACOshUI4smpCQanqjSY= github.com/klauspost/compress v1.15.9/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= github.com/klauspost/cpuid v1.2.3/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= @@ -618,7 +570,7 @@ github.com/klauspost/pgzip v1.2.5 h1:qnWYvvKqedOF2ulHpMG72XQol4ILEJ8k2wwRl/Km8oE github.com/klauspost/pgzip v1.2.5/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs= 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/kopia/htmluibuild v0.0.0-20220326183613-bbc499ed4dad/go.mod h1:eWer4rx9P8lJo2eKc+Q7AZ1dE1x1hJNdkbDFPzMu1Hw= +github.com/kopia/htmluibuild v0.0.0-20220707030846-0a2bb1459cbd/go.mod h1:eWer4rx9P8lJo2eKc+Q7AZ1dE1x1hJNdkbDFPzMu1Hw= github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= @@ -639,12 +591,9 @@ github.com/lib/pq v1.10.6 h1:jbk+ZieJ0D7EVGJYpL9QTz7/YW6UHbmdnZWYyK5cdBs= github.com/lib/pq v1.10.6/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de h1:9TO3cAIGXtEhnIaL+V+BEER86oLrvS+kWobKpbJuye0= github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de/go.mod h1:zAbeS9B/r2mtpb6U+EI2rYA5OAXxsYw6wTamcNW+zcE= -github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= -github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= github.com/lithammer/dedent v1.1.0/go.mod h1:jrXYCQtgg0nJiN+StA2KgR7w6CiQNv9Fd/Z9BP0jIOc= github.com/luci/go-render v0.0.0-20160219211803-9a04cc21af0f h1:WVPqVsbUsrzAebTEgWRAZMdDOfkFx06iyhbIoyMgtkE= github.com/luci/go-render v0.0.0-20160219211803-9a04cc21af0f/go.mod h1:aS446i8akEg0DAtNKTVYpNpLPMc0SzsZ0RtGhjl0uFM= -github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ= github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= github.com/mailru/easyjson v0.0.0-20160728113105-d5b7844b561a/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= @@ -660,10 +609,8 @@ github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb github.com/mattn/go-ieproxy v0.0.1 h1:qiyop7gCflfhwCzGyeT0gro3sF9AIg9HU98JORTkqfI= github.com/mattn/go-ieproxy v0.0.1/go.mod h1:pYabZ6IHcRpFh7vIaLfK7rdcWgFEb3SFJ6/gNWuh88E= github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= -github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.7/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= 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= @@ -672,8 +619,8 @@ github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3N github.com/minio/md5-simd v1.1.0/go.mod h1:XpBqgZULrMYD3R+M28PcmP0CkI7PEMzB3U77ZrKZ0Gw= github.com/minio/md5-simd v1.1.2 h1:Gdi1DZK69+ZVMoNHRXJyNcxrMA4dSxoYHZSQbirFg34= github.com/minio/md5-simd v1.1.2/go.mod h1:MzdKDxYpY2BT9XQFocsiZf/NKVtR7nkE4RoEpN+20RM= -github.com/minio/minio-go/v7 v7.0.27 h1:yJCvm78B+2+ll1PqO9eSD1as6Ibw3IYnnD8PyBEB2zo= -github.com/minio/minio-go/v7 v7.0.27/go.mod h1:x81+AX5gHSfCSqw7jxRKHvxUXMlE5uKX0Vb75Xk5yYg= +github.com/minio/minio-go/v7 v7.0.31 h1:zsJ3qPDeU3bC5UMVi9HJ4ED0lyEzrNd3iQguglZS5FE= +github.com/minio/minio-go/v7 v7.0.31/go.mod h1:/sjRKkKIA75CKh1iu8E3qBy7ktBmCCDGII0zbXGwbUk= github.com/minio/sha256-simd v0.1.1/go.mod h1:B5e1o+1/KgNmWrSQK08Y6Z1Vb5pwIktudl0J58iy0KM= github.com/minio/sha256-simd v1.0.0 h1:v1ta+49hkWZyvaKwrQB8elexRqm6Y0aMLjCNsrYxo6g= github.com/minio/sha256-simd v1.0.0/go.mod h1:OuYzVNI5vcoYIAmbIvHPl3N3jUzVedXbKy5RFepssQM= @@ -719,27 +666,16 @@ github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRW github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= github.com/natefinch/atomic v1.0.1 h1:ZPYKxkqQOx3KZ+RsbnP/YsgvxWQPGxjC0oBt2AhwV0A= github.com/natefinch/atomic v1.0.1/go.mod h1:N/D/ELrljoqDyT3rZrsUmtsuzvHkeB/wWjHV22AZRbM= -github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= -github.com/nats-io/jwt v0.3.2/go.mod h1:/euKqTS1ZD+zzjYrY7pseZrTtWQSjujC7xjPc8wL6eU= -github.com/nats-io/nats-server/v2 v2.1.2/go.mod h1:Afk+wRZqkMQs/p45uXdrVLuab3gwv3Z8C4HTBu8GD/k= -github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzEE/Zbp4w= -github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= -github.com/nats-io/nkeys v0.1.3/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= -github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= github.com/ncw/swift v1.0.49/go.mod h1:23YIA4yWVnGwv2dQlN4bB7egfYX6YLn0Yo/S6zZO/ZM= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= -github.com/oklog/oklog v0.3.2/go.mod h1:FCV+B7mhrz4o+ueLpx+KqkyXRGMWOYEvfiXtdGtbWGs= -github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= github.com/oklog/ulid v1.3.1 h1:EGfNDEx6MqHz8B3uNV6QAib1UR2Lm97sHi3ocA6ESJ4= 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/olekukonko/tablewriter v0.0.4/go.mod h1:zq6QwlOf5SlnkVbMSr5EoBv3636FWnp+qbPhuoO21uA= 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.7.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/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= @@ -748,14 +684,12 @@ github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU= github.com/onsi/ginkgo/v2 v2.0.0/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= -github.com/onsi/gomega v1.4.3/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/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= github.com/onsi/gomega v1.18.1 h1:M1GfJqGRrBrrGGsbxzV5dqM2U2ApXefZCQpkukxYRLE= github.com/onsi/gomega v1.18.1/go.mod h1:0q+aL8jAiMXy9hbwj2mr5GziHiwhAIQpFmmtT5hitRs= -github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/openshift/api v0.0.0-20200521101457-60c476765272/go.mod h1:TkhafijfTiRi1Q3120/ZSE4oIWKQ4DGRh3byPywv4Mw= github.com/openshift/api v0.0.0-20200526144822-34f54f12813a h1:riE/kCXnb051RWT/z+DytxKEZ3+JromVDl79rXAKyFY= @@ -763,36 +697,23 @@ github.com/openshift/api v0.0.0-20200526144822-34f54f12813a/go.mod h1:l6TGeqJ92D github.com/openshift/build-machinery-go v0.0.0-20200424080330-082bf86082cc/go.mod h1:1CkcsT3aVebzRBzVTSbiKSkJMsC/CASqxesfqEMfJEc= github.com/openshift/client-go v0.0.0-20200521150516-05eb9880269c h1:l7CmbzzkyWl4Y6qHmy6m4FvbH4iLnIXGrXqOfE5IFNA= github.com/openshift/client-go v0.0.0-20200521150516-05eb9880269c/go.mod h1:kCMeo6IE4o4qvnepM9lgHQ4j/ZFfvY/N/2G/jpJdwm4= -github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492/go.mod h1:Ngi6UdF0k5OKD5t5wlmGhe/EDKPoUM3BXZSSfIuJbis= -github.com/opentracing/basictracer-go v1.0.0/go.mod h1:QfBfYuafItcjQuMwinw9GhYKwFXS9KnPs5lxoYwgW74= -github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= -github.com/openzipkin-contrib/zipkin-go-opentracing v0.4.5/go.mod h1:/wsWhb9smxSfWAKL3wpBW7V8scJMt8N8gnaMCS9E/cA= -github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw= -github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= -github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/orisano/pixelmatch v0.0.0-20210112091706-4fa4c7ba91d5/go.mod h1:nZgzbfBr3hhjoZnS66nKrHmduYNpc34ny7RK4z5/HM0= -github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIwwtUjcrb0b5/5kLM= 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= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= -github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= github.com/peterbourgon/diskv v2.0.1+incompatible h1:UBdAOUP5p4RWqPBg048CAvpKN+vxiaj6gdUUzhl4XmI= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= -github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc= -github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pierrec/lz4 v2.6.1+incompatible h1:9UY3+iC23yxF0UfGaYrGplQ+79Rg+h/q9FV9ix19jjM= github.com/pierrec/lz4 v2.6.1+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pkg/profile v1.2.1/go.mod h1:hJw3o1OdXxsrSjjVksARp5W95eeEaEfptyVZyv6JUPA= github.com/pkg/profile v1.6.0/go.mod h1:qBsxPvzyUincmltOk6iyRVxHYg4adc0OFOv72ZdLa18= github.com/pkg/sftp v1.10.0/go.mod h1:NxmoDg/QLVWluQDUYG7XBZTLUpKeFa8e3aMf1BfjyHk= github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI= -github.com/pkg/sftp v1.13.4/go.mod h1:LzqnAvaD5TWeNBsZpfKxSYn1MbjWwOsCIAFFJbpIsK8= +github.com/pkg/sftp v1.13.5/go.mod h1:wHDZ0IZX6JcBYRK1TH9bcVq8G7TLpVHYIGJRFnmPfxg= github.com/pmezard/go-difflib v0.0.0-20151028094244-d8ed2627bdf0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= @@ -801,37 +722,31 @@ github.com/pquerna/cachecontrol v0.0.0-20171018203845-0dec1b30a021/go.mod h1:prY github.com/pquerna/ffjson v0.0.0-20190813045741-dac163c6c0a9/go.mod h1:YARuvh7BUWHNhzDq2OM5tzR2RiCcN2D7sapiKyCel/M= github.com/pquerna/ffjson v0.0.0-20190930134022-aa0246cd15f7/go.mod h1:YARuvh7BUWHNhzDq2OM5tzR2RiCcN2D7sapiKyCel/M= 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 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.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= +github.com/prometheus/client_golang v1.12.2/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= github.com/prometheus/client_golang v1.13.0 h1:b71QUfeo5M8gq2+evJdTPfZhYMAU0uKPkyPJ7TPsloU= github.com/prometheus/client_golang v1.13.0/go.mod h1:vTeo+zgvILHsnnj/39Ou/1fPN5nJFOEMgftOUOmlvYQ= 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.1.0/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.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt26CguLLsqA= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= +github.com/prometheus/common v0.35.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= github.com/prometheus/common v0.37.0 h1:ccBbHCgIiT9uSoFY0vX8H3zsNR5eLt17/RQLUvn8pXE= github.com/prometheus/common v0.37.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= 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.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= @@ -839,7 +754,6 @@ github.com/prometheus/procfs v0.8.0 h1:ODq8ZFEaYeCaZOJlZZdJA2AbQR98dSHSM1KW/You5 github.com/prometheus/procfs v0.8.0/go.mod h1:z7EfXMXOkbkqb9IINtpCn86r/to3BnA0uaxHdg830/4= github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= github.com/rasky/go-xdr v0.0.0-20170217172119-4930550ba2e2/go.mod h1:Nfe4efndBz4TibWycNE+lqyJZiMX4ycx+QKV8Ta0f/o= -github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/renier/xmlrpc v0.0.0-20170708154548-ce4a1a486c03 h1:Wdi9nwnhFNAlseAOekn6B5G/+GMtks9UKbvRU/CMM/o= github.com/renier/xmlrpc v0.0.0-20170708154548-ce4a1a486c03/go.mod h1:gRAiPF5C5Nd0eyyRdqIu9qTiFSoZzpTq727b5B8fkkU= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= @@ -848,16 +762,15 @@ github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFR github.com/rogpeppe/go-internal v1.6.1 h1:/FiVV8dS/e+YqF2JvO3yXRFbBLTIuSDkuC7aBOAvL+k= github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ= +github.com/rs/xid v1.3.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/xid v1.4.0 h1:qd7wPTDkN6KQx2VmMBLrpHkiyQwgFXRnkOLacUiaSNY= github.com/rs/xid v1.4.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= -github.com/rs/zerolog v1.21.0/go.mod h1:ZPhntP/xmq1nnND05hhpAh2QMhSsA4UN3MGZ6O2J3hM= github.com/russross/blackfriday v1.5.2 h1:HyvC0ARfnZBqnXwABFeSZHpKvJHJJfPz81GNueLj0oo= 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/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= -github.com/sanity-io/litter v1.5.4/go.mod h1:9gzJgR2i4ZpjZHsKvUXIRQVk7P+yM3e+jAF7bU2UI5U= +github.com/sanity-io/litter v1.5.5/go.mod h1:9gzJgR2i4ZpjZHsKvUXIRQVk7P+yM3e+jAF7bU2UI5U= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= @@ -876,14 +789,12 @@ github.com/softlayer/softlayer-go v0.0.0-20190615201252-ba6e7f295217 h1:MFHQI+AY github.com/softlayer/softlayer-go v0.0.0-20190615201252-ba6e7f295217/go.mod h1:Cw4GTlQccdRGSEf6KiMju767x0NEHE0YIVPJSaXjlsw= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= -github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I= github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= github.com/spf13/cobra v1.1.3/go.mod h1:pGADOWyqRD/YMrPZigI/zbliZ2wVD/23d+is3pSWzOo= github.com/spf13/cobra v1.2.1/go.mod h1:ExllRjgxM/piMAM+3tAZvg8fsklGAf3tPfi+i8t68Nk= github.com/spf13/cobra v1.4.0/go.mod h1:Wo4iy3BUC+X2Fybo0PDqwJIv3dNRiZLHQymsfxlB84g= @@ -892,16 +803,12 @@ github.com/spf13/cobra v1.5.0/go.mod h1:dWXEIy2H428czQCjInthrTRUg7yKbok+2Qi/yBIJ github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo= github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/spf13/viper v1.8.1/go.mod h1:o0Pch8wJ9BVSWGQMbra6iw0oQ5oktSIBaujf1rJH9Ns= github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= -github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= -github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= -github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= 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/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= @@ -922,17 +829,15 @@ github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69 github.com/tg123/go-htpasswd v1.2.0/go.mod h1:h7IzlfpvIWnVJhNZ0nQ9HaFxHb7pn5uFJYLlEUJa2sM= github.com/tidwall/pretty v1.0.0 h1:HsD+QiTn7sK6flMKIvNmpqz1qrpP3Ps6jOKIKMooyg4= 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-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tmc/grpc-websocket-proxy v0.0.0-20201229170055-e5319fda7802/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= -github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/vmware/govmomi v0.28.0 h1:VgeQ/Rvz79U9G8QIKLdgpsN9AndHJL+5iMJLgYIrBGI= github.com/vmware/govmomi v0.28.0/go.mod h1:F7adsVewLNHsW/IIm7ziFURaXDaHEwcc+ym4r3INMdY= github.com/vmware/vmw-guestinfo v0.0.0-20170707015358-25eff159a728/go.mod h1:x9oS4Wk2s2u4tS29nEaDLdzvuHdB19CvSGJjPgkZJNk= github.com/xdg-go/pbkdf2 v1.0.0/go.mod h1:jrpuAogTd400dnrH08LKmI/xc1MbPOebTwRqcT5RDeI= github.com/xdg-go/scram v1.1.1/go.mod h1:RaEWvsqvNKKvBPvcKeFjrG2cJqOkHTiyTpzz23ni57g= github.com/xdg-go/stringprep v1.0.3/go.mod h1:W3f5j4i+9rC0kuIEJL0ky1VpHXQU3ocBgklLGvcBnW8= +github.com/xhit/go-str2duration v1.2.0/go.mod h1:3cPSlfZlUHVlneIVfePFWcJZsuwf+P1v2SRTV4cUmp4= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca h1:1CFlNzQhALwjS9mBAUkycX616GzgsuYUOCHA5+HSlXI= github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= @@ -951,9 +856,7 @@ github.com/zeebo/blake3 v0.2.3/go.mod h1:mjJjZpnsyIVtVgTOSpJ9vmRE4wgDeyt2HU3qXvv github.com/zeebo/pcg v1.0.1 h1:lyqfGeWiv4ahac6ttHs+I5hwtH/+1mrhlCtVNQM2kHo= github.com/zeebo/pcg v1.0.1/go.mod h1:09F0S9iiKrwn9rlI5yjLkmrug154/YRW6KnnXVDM/l4= 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/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4= -go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg= go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= go.etcd.io/etcd/api/v3 v3.5.1/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g= @@ -967,8 +870,6 @@ go.etcd.io/etcd/server/v3 v3.5.0/go.mod h1:3Ah5ruV+M+7RZr0+Y/5mNLwC+eQlni+mQmOVd go.mongodb.org/mongo-driver v1.10.0/go.mod h1:wsihk0Kdgv8Kqu1Anit4sfK+22vSFbUrAVEYRhCXrA8= go.mongodb.org/mongo-driver v1.10.1 h1:NujsPveKwHaWuKUer/ceo9DzEe7HIj1SlJ6uvXZG0S4= go.mongodb.org/mongo-driver v1.10.1/go.mod h1:z4XpeoU6w+9Vht+jAFyLgVrD+jGSQQe0+CBWFHNiHt8= -go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= -go.opencensus.io v0.20.2/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= @@ -980,21 +881,22 @@ go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opentelemetry.io/contrib v0.20.0/go.mod h1:G/EtFaa6qaN7+LxqfIAT3GiZa7Wv5DTBUzl5H4LY0Kc= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.20.0/go.mod h1:oVGt1LRbBOBq1A5BQLlUg9UaU/54aiHw8cgjV3aWZ/E= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.20.0/go.mod h1:2AboqHi0CiIZU0qwhtUfCYD1GeUzvvIXWNkhDt7ZMG4= +go.opentelemetry.io/otel v0.20.0 h1:eaP0Fqu7SXHwvjiqDq83zImeehOHX8doTvU9AwXON8g= go.opentelemetry.io/otel v0.20.0/go.mod h1:Y3ugLH2oa81t5QO+Lty+zXf8zC9L26ax4Nzoxm/dooo= go.opentelemetry.io/otel/exporters/otlp v0.20.0/go.mod h1:YIieizyaN77rtLJra0buKiNBOm9XQfkPEKBeuhoMwAM= +go.opentelemetry.io/otel/metric v0.20.0 h1:4kzhXFP+btKm4jwxpjIqjs41A7MakRFUS86bqLHTIw8= go.opentelemetry.io/otel/metric v0.20.0/go.mod h1:598I5tYlH1vzBjn+BTuhzTCSb/9debfNp6R3s7Pr1eU= +go.opentelemetry.io/otel/oteltest v0.20.0 h1:HiITxCawalo5vQzdHfKeZurV8x7ljcqAgiWzF6Vaeaw= go.opentelemetry.io/otel/oteltest v0.20.0/go.mod h1:L7bgKf9ZB7qCwT9Up7i9/pn0PWIa9FqQ2IQ8LoxiGnw= go.opentelemetry.io/otel/sdk v0.20.0/go.mod h1:g/IcepuwNsoiX5Byy2nNV0ySUF1em498m7hBWC279Yc= go.opentelemetry.io/otel/sdk/export/metric v0.20.0/go.mod h1:h7RBNMsDJ5pmI1zExLi+bJK+Dr8NQCh0qGhm1KDnNlE= go.opentelemetry.io/otel/sdk/metric v0.20.0/go.mod h1:knxiS8Xd4E/N+ZqKmUPf3gTTZ4/0TjTXukfxjzSTpHE= +go.opentelemetry.io/otel/trace v0.20.0 h1:1DL6EXUdcg95gukhuRRvLDO/4X5THh/5dIV52lqtnbw= go.opentelemetry.io/otel/trace v0.20.0/go.mod h1:6GjCW8zgDjwGHGa6GkyeB8+/5vjT16gUEi0Nf1iBdgw= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5 h1:+FNtrFTmVw0YZGpBGX56XDee331t6JAXeK2bcyhLOOc= go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5/go.mod h1:nmDLcffg48OtT/PSW0Hg7FvpRQsQh5OSqIylirxKC7o= -go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= -go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= -go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= go.uber.org/atomic v1.9.0 h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE= go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= @@ -1004,15 +906,10 @@ go.uber.org/goleak v1.1.11/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ go.uber.org/goleak v1.1.12 h1:gZAh5/EyT/HQwlpkCy6wTpqfH9H8Lz8zbm3dZh+OyzA= go.uber.org/goleak v1.1.12/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= -go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4= -go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU= go.uber.org/multierr v1.8.0 h1:dg6GjLku4EH+249NNmoIciG9N/jURbDG+pFlTkhzIC8= go.uber.org/multierr v1.8.0/go.mod h1:7EAYxJLBy9rStEaz58O2t4Uvip6FSURkq8/ppBp95ak= -go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= -go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= -go.uber.org/zap v1.16.0/go.mod h1:MA8QOfq0BHJwdXa996Y4dYkAqRKB8/1K1QMMZVaNZjQ= go.uber.org/zap v1.17.0/go.mod h1:MXVU+bhUf/A7Xi2HNOnopQOrmycQ5Ih87HtOu4q5SSo= go.uber.org/zap v1.19.0/go.mod h1:xg/QME4nWcxGxrpdeYfq7UvYrLh66cuVKdrbD1XF/NI= go.uber.org/zap v1.19.1/go.mod h1:j3DNczoxDZroyBnOT1L/Q79cfUMGZxlv/9dzN7SM1rI= @@ -1026,7 +923,6 @@ golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACk golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= @@ -1034,8 +930,8 @@ golang.org/x/crypto v0.0.0-20200115085410-6d4e4cb37c7d/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200220183623-bac4c82f6975/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201216223049-8b5274cf687f/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= -golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= @@ -1045,7 +941,6 @@ golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa/go.mod h1:IxCIyHEi3zRg3s0 golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= -golang.org/x/exp v0.0.0-20190731235908-ec7cb31e5a56/go.mod h1:JhuoJpWY28nO4Vef9tZUw9qufEGTyX1+7lmHxV5q5G4= golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= @@ -1053,9 +948,6 @@ golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u0 golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= -golang.org/x/exp v0.0.0-20210916165020-5cb4fee858ee/go.mod h1:a3o/VtDNHN+dCVLEpzjjUHOzR+Ln3DHX056ZPzoZGGA= -golang.org/x/exp v0.0.0-20220328175248-053ad81199eb h1:pC9Okm6BVmxEw76PUu0XUbOTQ92JX11hfvqTjAV3qxM= -golang.org/x/exp v0.0.0-20220328175248-053ad81199eb/go.mod h1:lgLbSvA5ygNOMpwM/9anMpWVlVJ7Z+cHWq/eFuinpGE= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -1072,20 +964,16 @@ golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPI golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= -golang.org/x/mobile v0.0.0-20201217150744-e6ae53a27f4f/go.mod h1:skQtrUTUwhdJvXM/2KKJzY8pDgNr9I/FOMqDVRPBUS4= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= -golang.org/x/mod v0.1.1-0.20191209134235-331c550502dd/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.5.1-0.20210830214625-1b1db11ec8f4/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= -golang.org/x/mod v0.6.0-dev.0.20211013180041-c96bc1413d57/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= golang.org/x/net v0.0.0-20170114055629-f2499483f923/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1096,7 +984,6 @@ golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190125091013-d26f9f9a57f3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= @@ -1107,7 +994,6 @@ golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -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-20191112182307-2180aed22343/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -1151,6 +1037,7 @@ golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220617184016-355a448f1bc9/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220725212005-46097bf591d3 h1:2yWTtPWWRcISTw3/o+s/Y4UOMnQL71DWyToOANFusCg= golang.org/x/net v0.0.0-20220725212005-46097bf591d3/go.mod h1:AaygXjzTFtRAg2ttMY5RMuhpJ3cNnI0XpyFJD1iQRSM= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= @@ -1173,8 +1060,9 @@ golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= -golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb h1:8tDJ3aechhddbdPAxpycgXHJRMLpk/Ab+aa4OgdN5/g= golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= +golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2 h1:+jnHzr9VPj32ykQVai5DNahi9+NSp7yYuCsl5eAQtL0= +golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1196,7 +1084,6 @@ golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/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-20181122145206-62eef0e2fa9b/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-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1208,7 +1095,6 @@ golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191002063906-3421d5a6bb1c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1218,7 +1104,6 @@ golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20191112214154-59a1497f0cea/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191220142924-d4481acd189f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1239,7 +1124,6 @@ golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200622214017-ed371f2e16b4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200828194041-157a740278f4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1257,7 +1141,6 @@ golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1279,7 +1162,6 @@ golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220502124256-b6088ccd6cba/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1287,6 +1169,7 @@ golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220610221304-9f5ed59c137d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220624220833-87e55d714810/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220704084225-05e143d24a9e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f h1:v4INt8xihDGvnrfjMDVXGxw9wrfxYyCjk0KbXjhR55s= @@ -1306,7 +1189,6 @@ golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/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/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -1315,7 +1197,6 @@ golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxb golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 h1:vVKdlvoWBphwdxWKrFZEuM0kGgGLxUOYcY4U/2Vjg44= golang.org/x/time v0.0.0-20220210224613-90d013bbcef8/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/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= golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= @@ -1337,8 +1218,6 @@ golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtn 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-20191112195655-aa38f8e97acc/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -1348,9 +1227,7 @@ golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtn golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200103221440-774c71fcf114/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200115044656-831fdb1e1868/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200117012304-6edc0a871e69/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= @@ -1385,7 +1262,6 @@ golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.8-0.20211029000441-d6a9af8af023/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= golang.org/x/tools v0.1.10-0.20220218145154-897bd77cd717/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= 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= @@ -1397,7 +1273,6 @@ golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f h1:uF6paiQQebLeSXkrTqHqz golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= gomodules.xyz/jsonpatch/v2 v2.2.0 h1:4pT439QV83L+G9FkcCriY6EkpcK6r6bK+A5FBUMI7qY= gomodules.xyz/jsonpatch/v2 v2.2.0/go.mod h1:WXp+iVDkoLQqPudfQ9GBlwB2eZ5DKOnjQZCYdOS8GPY= -google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= 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= @@ -1430,22 +1305,18 @@ google.golang.org/api v0.56.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqiv google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI= google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I= google.golang.org/api v0.63.0/go.mod h1:gs4ij2ffTRXwuzzgJl/56BdwJaA194ijkfn++9tDuPo= -google.golang.org/api v0.64.0/go.mod h1:931CdxA8Rm4t6zqTFGSsgwbAEZ2+GMYurbndwSimebM= -google.golang.org/api v0.66.0/go.mod h1:I1dmXYpX7HGwz/ejRxwQp2qj5bFAz93HiCU1C1oYd9M= google.golang.org/api v0.67.0/go.mod h1:ShHKP8E60yPsKNw/w8w+VYaj9H6buA5UqDp8dhbQZ6g= -google.golang.org/api v0.69.0/go.mod h1:boanBiw+h5c3s+tBPgEzLDRHfFLWV0qXxRHz3ws7C80= google.golang.org/api v0.70.0/go.mod h1:Bs4ZM2HGifEvXwd50TtW70ovgJffJYw2oRCOFU/SkfA= google.golang.org/api v0.71.0/go.mod h1:4PyU6e6JogV1f9eA4voyrTY2batOLdgZ5qZ5HOCc4j8= -google.golang.org/api v0.73.0/go.mod h1:lbd/q6BRFJbdpV6OUCXstVeiI5mL/d3/WifG7iNKnjI= google.golang.org/api v0.74.0/go.mod h1:ZpfMZOVRMywNyvJFeqL9HRWBgAuRfSjJFpe9QtRRyDs= google.golang.org/api v0.75.0/go.mod h1:pU9QmyHLnzlpar1Mjt4IbapUCy8J+6HD6GeELN69ljA= google.golang.org/api v0.78.0/go.mod h1:1Sg78yoMLOhlQTeF+ARBoytAcH1NNyyl390YMy6rKmw= google.golang.org/api v0.80.0/go.mod h1:xY3nI94gbvBrE0J6NHXhxOmW97HG7Khjkku6AFB3Hyg= google.golang.org/api v0.84.0/go.mod h1:NTsGnUFJMYROtiquksZHBWtHfeMC7iYthki7Eq3pa8o= -google.golang.org/api v0.85.0 h1:8rJoHuRxx+vCmZtAO/3k1dRLvYNVyTJtZ5oaFZvhgvc= google.golang.org/api v0.85.0/go.mod h1:AqZf8Ep9uZ2pyTvgL+x0D3Zt0eoT9b5E8fmzfu6FO2g= +google.golang.org/api v0.86.0 h1:ZAnyOHQFIuWso1BodVfSaRyffD74T9ERGFa3k1fNk/U= +google.golang.org/api v0.86.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= -google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= @@ -1458,7 +1329,6 @@ google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRn google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190530194941-fb225487d101/go.mod h1:z3L6/3dTEVtUr6QSP8miRzeRqwQOioJ9I66odjN4I7s= google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= @@ -1518,15 +1388,9 @@ google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ6 google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211221195035-429b39de9b1c/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/genproto v0.0.0-20211223182754-3ac035c7e7cb/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220107163113-42d7afdf6368/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/genproto v0.0.0-20220111164026-67b88f271998/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/genproto v0.0.0-20220114231437-d2e6a121cae0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220126215142-9970aeb2e350/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/genproto v0.0.0-20220201184016-50beb8ab5c44/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220207164111-0872dc986b00/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= -google.golang.org/genproto v0.0.0-20220211171837-173942840c17/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= -google.golang.org/genproto v0.0.0-20220216160803-4663080d8bc8/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= google.golang.org/genproto v0.0.0-20220218161850-94dd64e39d7c/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= google.golang.org/genproto v0.0.0-20220222213610-43724f9ea8cf/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= google.golang.org/genproto v0.0.0-20220304144024-325a89244dc8/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= @@ -1542,17 +1406,13 @@ google.golang.org/genproto v0.0.0-20220518221133-4f43b3371335/go.mod h1:RAyBrSAP google.golang.org/genproto v0.0.0-20220523171625-347a074981d8/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= google.golang.org/genproto v0.0.0-20220608133413-ed9918b62aac/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/genproto v0.0.0-20220616135557-88e70c0c3a90/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= -google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad h1:kqrS+lhvaMHCxul6sKQvKJ8nAAhlVItmZV822hYFH/U= google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= -google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= +google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f h1:hJ/Y5SqPXbarffmAsApliUlcvMU+wScNGfyop4bZm8o= +google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= -google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= 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.22.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= 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= @@ -1599,15 +1459,14 @@ google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqw google.golang.org/protobuf v1.28.1 h1:d0NfwRgPtno5B1Wa6L2DAG+KivqkdutMf1UhdNx175w= google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= -gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/ini.v1 v1.57.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/ini.v1 v1.62.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= +gopkg.in/ini.v1 v1.66.2/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/ini.v1 v1.66.6 h1:LATuAqN/shcYAOkv3wl2L4rkaKqkcgTBQjOyYDvcPKI= gopkg.in/ini.v1 v1.66.6/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/kothar/go-backblaze.v0 v0.0.0-20190520213052-702d4e7eb465/go.mod h1:zJ2QpyDCYo1KvLXlmdnFlQAyF/Qfth0fB8239Qg7BIE= @@ -1619,7 +1478,6 @@ gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkep gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637 h1:yiW+nvdHb9LVqSHQBXfZCieqV4fzYhNBql77zY0ykqs= gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637/go.mod h1:BHsqpu/nsuzkT5BpiH1EMZPLyqSMM8JbIavyFACoFNk= -gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -1639,7 +1497,6 @@ gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= gotest.tools/v3 v3.0.3 h1:4AuOwCGf4lLR9u3YOe2awrHygurzhO/HeQ6laiA6Sx0= gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= -honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= 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= @@ -1647,7 +1504,6 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh 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/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= k8s.io/api v0.18.3/go.mod h1:UOaMwERbqJMfeeeHc8XJKawj4P9TgDRnViIqqBeH2QA= k8s.io/api v0.19.0/go.mod h1:I1K45XlvTrDjmj5LoM5LuP/KYrhWbjUKT/SoPG0qTjw= k8s.io/api v0.24.2/go.mod h1:AHqbSkTm6YrQ0ObxjO3Pmp/ubFF/KuM7jU+3khoBsOg= @@ -1729,4 +1585,3 @@ sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o= sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc= sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8= -sourcegraph.com/sourcegraph/appdash v0.0.0-20190731080439-ebfcffb1b5c0/go.mod h1:hI742Nqp5OhwiqlzhgfbWU4mW4yO10fP+LoT9WOswdU= diff --git a/pkg/kopia/snapshot/stream.go b/pkg/kopia/snapshot/stream.go index ac19c998cb..057e61c915 100644 --- a/pkg/kopia/snapshot/stream.go +++ b/pkg/kopia/snapshot/stream.go @@ -92,7 +92,7 @@ func Write(ctx context.Context, source io.Reader, path, password string) (*Snaps // This creates a virtual directory tree rooted at a static directory // with path as `parentPath` and a kopia fs.StreamingFile as the single child entry - rootDir := virtualfs.NewStaticDirectory(sourceInfo.Path, fs.Entries{ + rootDir := virtualfs.NewStaticDirectory(sourceInfo.Path, []fs.Entry{ virtualfs.StreamingFileFromReader(filepath.Base(path), source), }) diff --git a/pkg/kopia/utils.go b/pkg/kopia/utils.go index dff4d2e73d..da3fcee1d2 100644 --- a/pkg/kopia/utils.go +++ b/pkg/kopia/utils.go @@ -149,22 +149,22 @@ func GetStreamingFileObjectIDFromSnapshot(ctx context.Context, rep repo.Reposito // Load the kopia snapshot with the given backupID m, err := snapshot.LoadSnapshot(ctx, rep, manifest.ID(backupID)) if err != nil { - return "", errors.Wrapf(err, "Failed to load kopia snapshot with ID: %v", backupID) + return object.ID{}, errors.Wrapf(err, "Failed to load kopia snapshot with ID: %v", backupID) } // root entry of the kopia snapshot is a static directory with filepath.Dir(path) as its path if m.RootEntry == nil { - return "", errors.New("No root entry found in kopia manifest") + return object.ID{}, errors.New("No root entry found in kopia manifest") } rootEntry, err := snapshotfs.SnapshotRoot(rep, m) if err != nil { - return "", errors.Wrapf(err, "Failed to get root entry from kopia snapshot with ID: %v", backupID) + return object.ID{}, errors.Wrapf(err, "Failed to get root entry from kopia snapshot with ID: %v", backupID) } // Get the nested entry belonging to the backed up streaming file and return its object ID e, err := snapshotfs.GetNestedEntry(ctx, rootEntry, []string{filepath.Base(path)}) if err != nil { - return "", errors.Wrapf(err, "Failed to get nested entry from kopia snapshot: %v", filepath.Base(path)) + return object.ID{}, errors.Wrapf(err, "Failed to get nested entry from kopia snapshot: %v", filepath.Base(path)) } return e.(object.HasObjectID).ObjectID(), nil diff --git a/pkg/virtualfs/dir_entry.go b/pkg/virtualfs/dir_entry.go index f041332ca3..b1f1933e5a 100644 --- a/pkg/virtualfs/dir_entry.go +++ b/pkg/virtualfs/dir_entry.go @@ -67,3 +67,5 @@ func (e dirEntry) Device() fs.DeviceInfo { func (e dirEntry) LocalFilesystemPath() string { return "" } + +func (e dirEntry) Close() {} diff --git a/pkg/virtualfs/directory.go b/pkg/virtualfs/directory.go index 6fe7dbd5d5..8073222bf3 100644 --- a/pkg/virtualfs/directory.go +++ b/pkg/virtualfs/directory.go @@ -29,7 +29,7 @@ import ( type Directory struct { dirEntry - children fs.Entries + children []fs.Entry } var _ (fs.Directory) = (*Directory)(nil) @@ -67,12 +67,7 @@ func (d *Directory) AddAllDirs(pathname string, permissions os.FileMode) (subdir // Child gets the named child of a directory func (d *Directory) Child(ctx context.Context, name string) (fs.Entry, error) { - return fs.ReadDirAndFindChild(ctx, d, name) -} - -// Readdir gets the contents of a directory -func (d *Directory) Readdir(ctx context.Context) (fs.Entries, error) { - return append(fs.Entries(nil), d.children...), nil + return fs.IterateEntriesAndFindChild(ctx, d, name) } // Remove removes directory dirEntry with the given name @@ -92,7 +87,7 @@ func (d *Directory) Remove(name string) { func (d *Directory) Subdir(name string) (*Directory, error) { curr := d - subdir := curr.children.FindByName(name) + subdir := fs.FindByName(curr.children, name) if subdir == nil { return nil, errors.New(fmt.Sprintf("'%s' not found in '%s'", name, curr.Name())) } @@ -114,13 +109,13 @@ func (d *Directory) addChild(e fs.Entry) error { return errors.New("Failed to add child entry: name cannot contain '/'") } - child := d.children.FindByName(e.Name()) + child := fs.FindByName(d.children, e.Name()) if child != nil { return errors.New("Failed to add child entry: already exists") } d.children = append(d.children, e) - d.children.Sort() + fs.Sort(d.children) return nil } @@ -133,7 +128,7 @@ func (d *Directory) resolveDirs(pathname string) (parent *Directory, missing []s p := d parts := strings.Split(path.Clean(pathname), "/") for i, n := range parts { - i2 := p.children.FindByName(n) + i2 := fs.FindByName(p.children, n) if i2 == nil { return p, parts[i:], nil } @@ -146,6 +141,23 @@ func (d *Directory) resolveDirs(pathname string) (parent *Directory, missing []s return p, nil, nil } +func (d *Directory) IterateEntries(ctx context.Context, cb func(context.Context, fs.Entry) error) error { + entries := append([]fs.Entry{}, d.children...) + for _, e := range entries { + if err := cb(ctx, e); err != nil { + return err + } + } + + return nil +} + +func (d *Directory) SupportsMultipleIterations() bool { + return true +} + +func (d *Directory) Close() {} + // AddFileWithStreamSource adds a virtual file with the specified name, permissions and source func AddFileWithStreamSource(d *Directory, filePath, sourceEndpoint string, dirPermissions, filePermissions os.FileMode) (*file, error) { dir, name := path.Split(filePath) From 26992a63476e7b1c805df768b8a1606e0bf19226 Mon Sep 17 00:00:00 2001 From: Ankit Jain Date: Wed, 7 Sep 2022 16:35:45 +0530 Subject: [PATCH 09/15] Update kanister-tools Dockerfile to use new kopia image alpine-317cc36 (#1624) Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- docker/tools/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/tools/Dockerfile b/docker/tools/Dockerfile index fe5a211760..7f21b3b4f2 100644 --- a/docker/tools/Dockerfile +++ b/docker/tools/Dockerfile @@ -9,8 +9,8 @@ LABEL name="kanister-tools" \ description="Kanister tools for application-specific data management" COPY --from=restic/restic:0.11.0 /usr/bin/restic /usr/local/bin/restic -# kastenhq/kopia alpine-sha-7664c8c image -COPY --from=ghcr.io/kastenhq/kopia@sha256:540e05631dc48428725dc938ce62d7e4c1e698ba1fc6956ad36dd349ad076a20 \ +# ghcr.io/kanisterio/kopia:alpine-317cc36 +COPY --from=ghcr.io/kanisterio/kopia@sha256:87648ef24ce47f1d74ef5fa70bff96080f686b849dd0d787e1699d4c05807c4b \ /kopia/kopia /usr/local/bin/kopia COPY LICENSE /licenses/LICENSE From 43fb2643682ca393a3aa4ca7f8dcc9bf308a2fee Mon Sep 17 00:00:00 2001 From: Shlok Chaudhari Date: Wed, 7 Sep 2022 19:11:20 +0530 Subject: [PATCH 10/15] [Kopia wrappers - B] Add command wrappers in the Kopia package (#1526) * Add kopia wrappers * Add logsafe module * Modify utils package * Add errors package * Add apis/config package * Refactor kopia wrapper module * Remove downstream user reference * Address reviewer comments * Separate constant files in Kopia package * Add command logsafe * Add utility functions * Created sub-packages for repository and snapshot wrapper methods * Add license info in constant files * Move helper functions out of the kopia.go file * Rename kopia.go to commands.go * Rename OpenRepository, DeleteSnapshot and reportSnapshotStatus methods * Convert constants and functions from local to global * Fix constant in pkg/kopia/snapshot/stream.go * Fix const description in pkg/kopia/utils.go * Added some more utils functions * Update maintenance info command and add maintenance utils * Add Client keyword in constants and rename kankopia import alias in pkg/stream/stream.go * Rename kopiaArgs to commonArgs * Resolve cyclic import statements * Rename cmd package to command * Resolve cyclic commit * Refactor separate log_output_utils.go * Fix command utility import * Remove nested loop * Change log level to Debug * [Kopia wrappers - C] Separate out kopia commands from a single file (#1552) * Separate out kopia commands from a single file * Combine wrapper functions * Fix policyChanges in PolicySetGlobal command wrapper * Move command wrapper arguments * Add CommandArgs struct to pass args to command wrappers * Convert local arguments to exportable arguments * Change log level to Debug * Remove unused const * Fix for make gomod in CI * Move RegEx as a const * Rename pkg/kopia/command/kopia.go to pkg/kopia/command/common.go * Rename log_output_utils.go to parse_command_output.go and Move output parsing functions from helpers.go to parse_command_output.go * Group 'kopia blob' commands in single file * Group 'kopia maintenance' commands in single file * Group 'kopia server' commands in single file * Move parent command functions closer in pkg/kopia/command/server.go * Group 'kopia snapshot' commands in single file * Group 'kopia snapshot' commands in single file * rename commandArgs in all commands * Simplify nil check in if statements * Fix golang issues * Fix golint issues * Add recent changes to snapshot create stats parsed from the 'kopia snapshot create' command * Fix go.mod issue in golint --- go.mod | 3 +- pkg/kopia/command/blob.go | 39 ++ pkg/kopia/command/common.go | 61 +++ pkg/kopia/command/const.go | 74 ++++ pkg/kopia/command/helpers.go | 37 ++ pkg/kopia/command/maintenance.go | 56 +++ pkg/kopia/command/parse_command_output.go | 374 ++++++++++++++++++ pkg/kopia/command/policy_set_global.go | 31 ++ pkg/kopia/command/restore.go | 29 ++ pkg/kopia/command/server.go | 138 +++++++ pkg/kopia/command/snapshot.go | 139 +++++++ pkg/kopia/const.go | 56 +++ pkg/kopia/errors.go | 26 ++ .../maintenance/get_maintenance_owner.go | 82 ++++ pkg/kopia/utils.go | 7 - 15 files changed, 1144 insertions(+), 8 deletions(-) create mode 100644 pkg/kopia/command/blob.go create mode 100644 pkg/kopia/command/common.go create mode 100644 pkg/kopia/command/const.go create mode 100644 pkg/kopia/command/helpers.go create mode 100644 pkg/kopia/command/maintenance.go create mode 100644 pkg/kopia/command/parse_command_output.go create mode 100644 pkg/kopia/command/policy_set_global.go create mode 100644 pkg/kopia/command/restore.go create mode 100644 pkg/kopia/command/server.go create mode 100644 pkg/kopia/command/snapshot.go create mode 100644 pkg/kopia/const.go create mode 100644 pkg/kopia/errors.go create mode 100644 pkg/kopia/maintenance/get_maintenance_owner.go diff --git a/go.mod b/go.mod index 10c7a5dc44..155a76c05f 100644 --- a/go.mod +++ b/go.mod @@ -63,6 +63,8 @@ require ( sigs.k8s.io/controller-runtime v0.12.3 ) +require github.com/dustin/go-humanize v1.0.0 + require ( cloud.google.com/go v0.102.1 // indirect cloud.google.com/go/compute v1.7.0 // indirect @@ -91,7 +93,6 @@ require ( github.com/davecgh/go-spew v1.1.1 // indirect github.com/dgrijalva/jwt-go v3.2.0+incompatible // indirect github.com/dimchansky/utfbom v1.1.1 // indirect - github.com/dustin/go-humanize v1.0.0 // indirect github.com/edsrzf/mmap-go v1.1.0 // indirect github.com/elazarl/goproxy v0.0.0-20190711103511-473e67f1d7d2 // indirect github.com/emicklei/go-restful v2.9.5+incompatible // indirect diff --git a/pkg/kopia/command/blob.go b/pkg/kopia/command/blob.go new file mode 100644 index 0000000000..1f76868473 --- /dev/null +++ b/pkg/kopia/command/blob.go @@ -0,0 +1,39 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +type BlobListCommandArgs struct { + *CommandArgs +} + +// BlobList returns the kopia command for listing blobs in the repository with their sizes +func BlobList(cmdArgs BlobListCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(blobSubCommand, listSubCommand) + + return stringSliceCommand(args) +} + +type BlobStatsCommandArgs struct { + *CommandArgs +} + +// BlobStats returns the kopia command to get the blob stats +func BlobStats(cmdArgs BlobStatsCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(blobSubCommand, statsSubCommand, rawFlag) + + return stringSliceCommand(args) +} diff --git a/pkg/kopia/command/common.go b/pkg/kopia/command/common.go new file mode 100644 index 0000000000..fc445efa87 --- /dev/null +++ b/pkg/kopia/command/common.go @@ -0,0 +1,61 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +import ( + "github.com/kanisterio/kanister/pkg/field" + "github.com/kanisterio/kanister/pkg/log" + "github.com/kanisterio/kanister/pkg/logsafe" +) + +type CommandArgs struct { + EncryptionKey string + ConfigFilePath string + LogDirectory string +} + +func bashCommand(args logsafe.Cmd) []string { + log.Debug().Print("Kopia Command", field.M{"Command": args.String()}) + return []string{"bash", "-o", "errexit", "-c", args.PlainText()} +} + +func stringSliceCommand(args logsafe.Cmd) []string { + log.Debug().Print("Kopia Command", field.M{"Command": args.String()}) + return args.StringSliceCMD() +} + +func commonArgs(password, configFilePath, logDirectory string, requireInfoLevel bool) logsafe.Cmd { + c := logsafe.NewLoggable(kopiaCommand) + if requireInfoLevel { + c = c.AppendLoggable(logLevelInfoFlag) + } else { + c = c.AppendLoggable(logLevelErrorFlag) + } + if configFilePath != "" { + c = c.AppendLoggableKV(configFileFlag, configFilePath) + } + if logDirectory != "" { + c = c.AppendLoggableKV(logDirectoryFlag, logDirectory) + } + if password != "" { + c = c.AppendRedactedKV(passwordFlag, password) + } + return c +} + +// ExecKopiaArgs returns the basic Argv for executing kopia with the given config file path. +func ExecKopiaArgs(configFilePath string) []string { + return commonArgs("", configFilePath, "", false).StringSliceCMD() +} diff --git a/pkg/kopia/command/const.go b/pkg/kopia/command/const.go new file mode 100644 index 0000000000..6eb1b4eab3 --- /dev/null +++ b/pkg/kopia/command/const.go @@ -0,0 +1,74 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +const ( + blobSubCommand = "blob" + createSubCommand = "create" + deleteSubCommand = "delete" + expireSubCommand = "expire" + gcSubCommand = "gc" + infoSubCommand = "info" + kopiaCommand = "kopia" + listSubCommand = "list" + maintenanceSubCommand = "maintenance" + manifestSubCommand = "manifest" + policySubCommand = "policy" + restoreSubCommand = "restore" + runSubCommand = "run" + setSubCommand = "set" + snapshotSubCommand = "snapshot" + statsSubCommand = "stats" + + allFlag = "--all" + configFileFlag = "--config-file" + deleteFlag = "--delete" + deltaFlag = "--delta" + filterFlag = "--filter" + globalFlag = "--global" + jsonFlag = "--json" + logDirectoryFlag = "--log-dir" + logLevelErrorFlag = "--log-level=error" + logLevelInfoFlag = "--log-level=info" + noGrpcFlag = "--no-grpc" + parallelFlag = "--parallel" + passwordFlag = "--password" + progressUpdateIntervalFlag = "--progress-update-interval" + rawFlag = "--raw" + showIdenticalFlag = "--show-identical" + unsafeIgnoreSourceFlag = "--unsafe-ignore-source" + ownerFlag = "--owner" + sparseFlag = "--sparse" + + // Server specific + addSubCommand = "add" + refreshSubCommand = "refresh" + serverSubCommand = "server" + startSubCommand = "start" + statusSubCommand = "status" + userSubCommand = "user" + addressFlag = "--address" + redirectToDevNull = "> /dev/null 2>&1" + runInBackground = "&" + serverControlPasswordFlag = "--server-control-password" + serverControlUsernameFlag = "--server-control-username" + serverPasswordFlag = "--server-password" + serverUsernameFlag = "--server-username" + serverCertFingerprint = "--server-cert-fingerprint" + tlsCertFilePath = "--tls-cert-file" + tlsGenerateCertFlag = "--tls-generate-cert" + tlsKeyFilePath = "--tls-key-file" + userPasswordFlag = "--user-password" +) diff --git a/pkg/kopia/command/helpers.go b/pkg/kopia/command/helpers.go new file mode 100644 index 0000000000..d55713c681 --- /dev/null +++ b/pkg/kopia/command/helpers.go @@ -0,0 +1,37 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +import ( + "github.com/kanisterio/kanister/pkg/kopia" + "github.com/kanisterio/kanister/pkg/utils" +) + +type policyChanges map[string]string + +// GetCacheSizeSettingsForSnapshot returns the feature setting cache size values to be used +// for initializing repositories that will be performing general command workloads that benefit from +// cacheing metadata only. +func GetCacheSizeSettingsForSnapshot() (contentCacheMB, metadataCacheMB int) { + return utils.GetEnvAsIntOrDefault(kopia.DataStoreGeneralContentCacheSizeMBVarName, kopia.DefaultDataStoreGeneralContentCacheSizeMB), + utils.GetEnvAsIntOrDefault(kopia.DataStoreGeneralMetadataCacheSizeMBVarName, kopia.DefaultDataStoreGeneralMetadataCacheSizeMB) +} + +// GetCacheSizeSettingsForRestore returns the feature setting cache size values to be used +// for initializing repositories that will be performing restore workloads +func GetCacheSizeSettingsForRestore() (contentCacheMB, metadataCacheMB int) { + return utils.GetEnvAsIntOrDefault(kopia.DataStoreRestoreContentCacheSizeMBVarName, kopia.DefaultDataStoreRestoreContentCacheSizeMB), + utils.GetEnvAsIntOrDefault(kopia.DataStoreRestoreMetadataCacheSizeMBVarName, kopia.DefaultDataStoreRestoreMetadataCacheSizeMB) +} diff --git a/pkg/kopia/command/maintenance.go b/pkg/kopia/command/maintenance.go new file mode 100644 index 0000000000..c5bd4b8b99 --- /dev/null +++ b/pkg/kopia/command/maintenance.go @@ -0,0 +1,56 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +type MaintenanceInfoCommandArgs struct { + *CommandArgs + GetJsonOutput bool +} + +// MaintenanceInfo returns the kopia command to get maintenance info +func MaintenanceInfo(cmdArgs MaintenanceInfoCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(maintenanceSubCommand, infoSubCommand) + if cmdArgs.GetJsonOutput { + args = args.AppendLoggable(jsonFlag) + } + + return stringSliceCommand(args) +} + +type MaintenanceSetOwnerCommandArgs struct { + *CommandArgs + CustomOwner string +} + +// MaintenanceSetOwner returns the kopia command for setting custom maintenance owner +func MaintenanceSetOwner(cmdArgs MaintenanceSetOwnerCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(maintenanceSubCommand, setSubCommand) + args = args.AppendLoggableKV(ownerFlag, cmdArgs.CustomOwner) + return stringSliceCommand(args) +} + +type MaintenanceRunCommandArgs struct { + *CommandArgs +} + +// MaintenanceRunCommand returns the kopia command to run manual maintenance +func MaintenanceRunCommand(cmdArgs MaintenanceRunCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(maintenanceSubCommand, runSubCommand) + + return stringSliceCommand(args) +} diff --git a/pkg/kopia/command/parse_command_output.go b/pkg/kopia/command/parse_command_output.go new file mode 100644 index 0000000000..73d86e92b1 --- /dev/null +++ b/pkg/kopia/command/parse_command_output.go @@ -0,0 +1,374 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +import ( + "bufio" + "encoding/json" + "fmt" + "regexp" + "strconv" + "strings" + + "github.com/dustin/go-humanize" + "github.com/kopia/kopia/repo/manifest" + "github.com/kopia/kopia/snapshot" + "github.com/pkg/errors" + + "github.com/kanisterio/kanister/pkg/field" + "github.com/kanisterio/kanister/pkg/log" +) + +const ( + pathKey = "path" + typeKey = "type" + snapshotValue = "snapshot" + + snapshotCreateOutputRegEx = `(?P[|/\-\\\*]).+[^\d](?P\d+) hashed \((?P[^\)]+)\), (?P\d+) cached \((?P[^\)]+)\), uploaded (?P[^\)]+), (?:estimating...|estimated (?P[^\)]+) \((?P[^\)]+)\%\).+)` + extractSnapshotIDRegEx = `Created snapshot with root ([^\s]+) and ID ([^\s]+).*$` + repoTotalSizeFromBlobStatsRegEx = `Total: (\d+)$` + repoCountFromBlobStatsRegEx = `Count: (\d+)$` +) + +// SnapshotIDsFromSnapshot extracts root ID of a snapshot from the logs +func SnapshotIDsFromSnapshot(output string) (snapID, rootID string, err error) { + if output == "" { + return snapID, rootID, errors.New("Received empty output") + } + + logs := regexp.MustCompile("[\r\n]").Split(output, -1) + pattern := regexp.MustCompile(extractSnapshotIDRegEx) + for _, l := range logs { + // Log should contain "Created snapshot with root ABC and ID XYZ..." + match := pattern.FindAllStringSubmatch(l, 1) + if len(match) > 0 && len(match[0]) > 2 { + snapID = match[0][2] + rootID = match[0][1] + return + } + } + return snapID, rootID, errors.New("Failed to find Root ID from output") +} + +// LatestSnapshotInfoFromManifestList returns snapshot ID and backup path of the latest snapshot from `manifests list` output +func LatestSnapshotInfoFromManifestList(output string) (string, string, error) { + manifestList := []manifest.EntryMetadata{} + snapID := "" + backupPath := "" + + err := json.Unmarshal([]byte(output), &manifestList) + if err != nil { + return snapID, backupPath, errors.Wrap(err, "Failed to unmarshal manifest list") + } + for _, manifest := range manifestList { + for key, value := range manifest.Labels { + if key == pathKey { + backupPath = value + } + if key == typeKey && value == snapshotValue { + snapID = string(manifest.ID) + } + } + } + if snapID == "" { + return "", "", errors.New("Failed to get latest snapshot ID from manifest list") + } + if backupPath == "" { + return "", "", errors.New("Failed to get latest snapshot backup path from manifest list") + } + return snapID, backupPath, nil +} + +// SnapshotInfoFromSnapshotCreateOutput returns snapshot ID and root ID from snapshot create output +func SnapshotInfoFromSnapshotCreateOutput(output string) (string, string, error) { + snapID := "" + rootID := "" + scanner := bufio.NewScanner(strings.NewReader(output)) + for scanner.Scan() { + snapManifest := &snapshot.Manifest{} + err := json.Unmarshal([]byte(scanner.Text()), snapManifest) + if err != nil { + continue + } + if snapManifest == nil { + continue + } + snapID = string(snapManifest.ID) + if snapManifest.RootEntry != nil { + rootID = snapManifest.RootEntry.ObjectID.String() + } + } + if snapID == "" { + return "", "", errors.New(fmt.Sprintf("Failed to get snapshot ID from create snapshot output %s", output)) + } + if rootID == "" { + return "", "", errors.New(fmt.Sprintf("Failed to get root ID from create snapshot output %s", output)) + } + return snapID, rootID, nil +} + +// SnapSizeStatsFromSnapListAll returns a list of snapshot logical sizes assuming the input string +// is formatted as the output of a kopia snapshot list --all command. +func SnapSizeStatsFromSnapListAll(output string) (totalSizeB int64, numSnapshots int, err error) { + if output == "" { + return 0, 0, errors.New("Received empty output") + } + + snapList, err := parseSnapshotManifestList(output) + if err != nil { + return 0, 0, errors.Wrap(err, "Parsing snapshot list output as snapshot manifest list") + } + + totalSizeB = sumSnapshotSizes(snapList) + + return totalSizeB, len(snapList), nil +} + +func sumSnapshotSizes(snapList []*snapshot.Manifest) (sum int64) { + noSizeDataCount := 0 + for _, snapInfo := range snapList { + if snapInfo.RootEntry == nil || + snapInfo.RootEntry.DirSummary == nil { + noSizeDataCount++ + + continue + } + + sum += snapInfo.RootEntry.DirSummary.TotalFileSize + } + + if noSizeDataCount > 0 { + log.Error().Print("Found snapshot manifests without size data", field.M{"count": noSizeDataCount}) + } + + return sum +} + +func parseSnapshotManifestList(output string) ([]*snapshot.Manifest, error) { + snapInfoList := []*snapshot.Manifest{} + + if err := json.Unmarshal([]byte(output), &snapInfoList); err != nil { + return nil, errors.Wrap(err, "Failed to unmarshal snapshot manifest list") + } + + return snapInfoList, nil +} + +// SnapshotCreateInfo is a container for data that can be parsed from the output of +// `kopia snapshot create`. +type SnapshotCreateInfo struct { + SnapshotID string + RootID string + Stats *SnapshotCreateStats +} + +// ParseSnapshotCreateOutput parses the output of a snapshot create command into +// a new SnapshotCreateInfo struct and returns its pointer. The Stats field may be nil +// if the stats were unable to be parsed. The root ID and snapshot ID are fetched from +// structured stdout and stats are parsed from stderr output. +func ParseSnapshotCreateOutput(snapCreateStdoutOutput, snapCreateStderrOutput string) (*SnapshotCreateInfo, error) { + snapID, rootID, err := SnapshotInfoFromSnapshotCreateOutput(snapCreateStdoutOutput) + if err != nil { + return nil, err + } + + return &SnapshotCreateInfo{ + SnapshotID: snapID, + RootID: rootID, + Stats: SnapshotStatsFromSnapshotCreate(snapCreateStderrOutput, true), + }, nil +} + +// SnapshotCreateStats is a container for stats parsed from the output of a `kopia +// snapshot create` command. +type SnapshotCreateStats struct { + FilesHashed int64 + SizeHashedB int64 + FilesCached int64 + SizeCachedB int64 + SizeUploadedB int64 + SizeEstimatedB int64 + ProgressPercent int64 +} + +var kopiaProgressPattern = regexp.MustCompile(snapshotCreateOutputRegEx) //nolint:lll + +// SnapshotStatsFromSnapshotCreate parses the output of a kopia snapshot +// create execution for a log of the stats for that execution. +func SnapshotStatsFromSnapshotCreate(snapCreateStderrOutput string, matchOnlyFinished bool) (stats *SnapshotCreateStats) { + if snapCreateStderrOutput == "" { + return nil + } + logs := regexp.MustCompile("[\r\n]").Split(snapCreateStderrOutput, -1) + + // Match a pattern starting with "*" (signifying upload finished), and containing + // the repeated pattern "<\d+> (),", + // where is "hashed", "cached", and "uploaded". + // Example input: + // * 0 hashing, 1 hashed (2 B), 3 cached (40 KB), uploaded 6.7 GB, estimated 1092.3 MB (100.0%) 0s left + // Expected output: + // SnapshotCreateStats{ + // filesHashed: 1, + // sizeHashedB: 2, + // filesCached: 3, + // sizeCachedB: 40000, + // sizeUploadedB: 6700000000, + // sizeEstimatedB: 1092000000, + // progressPercent: 100, + // }, nil + + for _, l := range logs { + lineStats := parseKopiaProgressLine(l, matchOnlyFinished) + if lineStats != nil { + stats = lineStats + } + } + + return stats +} + +func parseKopiaProgressLine(line string, matchOnlyFinished bool) (stats *SnapshotCreateStats) { + match := kopiaProgressPattern.FindStringSubmatch(line) + if len(match) < 9 { + return nil + } + + groups := make(map[string]string) + for i, name := range kopiaProgressPattern.SubexpNames() { + if i != 0 && name != "" { + groups[name] = match[i] + } + } + + isFinalResult := groups["spinner"] == "*" + if matchOnlyFinished && !isFinalResult { + return nil + } + + numHashed, err := strconv.Atoi(groups["numHashed"]) + if err != nil { + log.WithError(err).Print("Skipping entry due to inability to parse number of hashed files", field.M{"numHashed": groups["numHashed"]}) + return nil + } + + numCached, err := strconv.Atoi(groups["numCached"]) + if err != nil { + log.WithError(err).Print("Skipping entry due to inability to parse number of cached files", field.M{"numCached": groups["numCached"]}) + return nil + } + + hashedSizeBytes, err := humanize.ParseBytes(groups["hashedSize"]) + if err != nil { + log.WithError(err).Print("Skipping entry due to inability to parse hashed size string", field.M{"hashedSize": groups["hashedSize"]}) + return nil + } + + cachedSizeBytes, err := humanize.ParseBytes(groups["cachedSize"]) + if err != nil { + log.WithError(err).Print("Skipping entry due to inability to parse cached size string", field.M{"cachedSize": groups["cachedSize"]}) + return nil + } + + uploadedSizeBytes, err := humanize.ParseBytes(groups["uploadedSize"]) + if err != nil { + log.WithError(err).Print("Skipping entry due to inability to parse uploaded size string", field.M{"uploadedSize": groups["uploadedSize"]}) + return nil + } + + var estimatedSizeBytes uint64 + var progressPercent float64 + stillEstimating := len(groups["estimatedSize"]) == 0 && len(groups["estimatedProgress"]) == 0 + + if !stillEstimating { // Estimation completed + estimatedSizeBytes, err = humanize.ParseBytes(groups["estimatedSize"]) + if err != nil { + log.WithError(err).Print("Skipping entry due to inability to parse estimated size string", field.M{"estimatedSize": groups["estimatedSize"]}) + return nil + } + + progressPercent, err = strconv.ParseFloat(groups["estimatedProgress"], 64) + if err != nil { + log.WithError(err).Print("Skipping entry due to inability to parse progress percent string", field.M{"estimatedProgress": groups["estimatedProgress"]}) + return nil + } + } else if isFinalResult { // It may happen that kopia will complete its job before estimation will be done + progressPercent = 100 + } + + return &SnapshotCreateStats{ + FilesHashed: int64(numHashed), + SizeHashedB: int64(hashedSizeBytes), + FilesCached: int64(numCached), + SizeCachedB: int64(cachedSizeBytes), + SizeUploadedB: int64(uploadedSizeBytes), + SizeEstimatedB: int64(estimatedSizeBytes), + ProgressPercent: int64(progressPercent), + } +} + +// RepoSizeStatsFromBlobStatsRaw takes a string as input, interprets it as a kopia blob stats +// output in an expected format (Contains the line "Total: "), and returns the integer +// size in bytes or an error if parsing is unsuccessful. +func RepoSizeStatsFromBlobStatsRaw(blobStats string) (phySizeTotal int64, blobCount int, err error) { + if blobStats == "" { + return phySizeTotal, blobCount, errors.New("received empty blob stats string") + } + + sizePattern := regexp.MustCompile(repoTotalSizeFromBlobStatsRegEx) + countPattern := regexp.MustCompile(repoCountFromBlobStatsRegEx) + + var countStr, sizeStr string + + for _, l := range strings.Split(blobStats, "\n") { + if countStr == "" { + countMatch := countPattern.FindStringSubmatch(l) + if len(countMatch) >= 2 { + countStr = countMatch[1] + } + } + + if sizeStr == "" { + sizeMatch := sizePattern.FindStringSubmatch(l) + if len(sizeMatch) >= 2 { + sizeStr = sizeMatch[1] + } + } + + if !(countStr == "" || sizeStr == "") { + // Both strings have been matched + break + } + } + + if countStr == "" { + return phySizeTotal, blobCount, errors.New("could not find count field in the blob stats") + } + + if sizeStr == "" { + return phySizeTotal, blobCount, errors.New("could not find size field in the blob stats") + } + + countVal, err := strconv.Atoi(countStr) + if err != nil { + return phySizeTotal, blobCount, errors.Wrap(err, fmt.Sprintf("unable to convert parsed count value %s", countStr)) + } + + sizeValBytes, err := strconv.Atoi(sizeStr) + if err != nil { + return phySizeTotal, blobCount, errors.Wrap(err, fmt.Sprintf("unable to convert parsed size value %s", countStr)) + } + + return int64(sizeValBytes), countVal, nil +} diff --git a/pkg/kopia/command/policy_set_global.go b/pkg/kopia/command/policy_set_global.go new file mode 100644 index 0000000000..880d432aa8 --- /dev/null +++ b/pkg/kopia/command/policy_set_global.go @@ -0,0 +1,31 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +type PolicySetGlobalCommandArgs struct { + *CommandArgs + Modifications policyChanges +} + +// PolicySetGlobal returns the kopia command for modifying the global policy +func PolicySetGlobal(cmdArgs PolicySetGlobalCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(policySubCommand, setSubCommand, globalFlag) + for field, val := range cmdArgs.Modifications { + args = args.AppendLoggableKV(field, val) + } + + return stringSliceCommand(args) +} diff --git a/pkg/kopia/command/restore.go b/pkg/kopia/command/restore.go new file mode 100644 index 0000000000..5171e47162 --- /dev/null +++ b/pkg/kopia/command/restore.go @@ -0,0 +1,29 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +type RestoreCommandArgs struct { + *CommandArgs + RootID string + TargetPath string +} + +// Restore returns the kopia command for restoring root of a snapshot with given root ID +func Restore(cmdArgs RestoreCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(restoreSubCommand, cmdArgs.RootID, cmdArgs.TargetPath) + + return stringSliceCommand(args) +} diff --git a/pkg/kopia/command/server.go b/pkg/kopia/command/server.go new file mode 100644 index 0000000000..c19b52f474 --- /dev/null +++ b/pkg/kopia/command/server.go @@ -0,0 +1,138 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +type ServerStartCommandArgs struct { + *CommandArgs + ServerAddress string + TLSCertFile string + TLSKeyFile string + ServerUsername string + ServerPassword string + AutoGenerateCert bool + Background bool +} + +// ServerStart returns the kopia command for starting the Kopia API Server +func ServerStart(cmdArgs ServerStartCommandArgs) []string { + args := commonArgs("", cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + + if cmdArgs.AutoGenerateCert { + args = args.AppendLoggable(serverSubCommand, startSubCommand, tlsGenerateCertFlag) + } else { + args = args.AppendLoggable(serverSubCommand, startSubCommand) + } + args = args.AppendLoggableKV(addressFlag, cmdArgs.ServerAddress) + args = args.AppendLoggableKV(tlsCertFilePath, cmdArgs.TLSCertFile) + args = args.AppendLoggableKV(tlsKeyFilePath, cmdArgs.TLSKeyFile) + args = args.AppendLoggableKV(serverUsernameFlag, cmdArgs.ServerUsername) + args = args.AppendRedactedKV(serverPasswordFlag, cmdArgs.ServerPassword) + + args = args.AppendLoggableKV(serverControlUsernameFlag, cmdArgs.ServerUsername) + args = args.AppendRedactedKV(serverControlPasswordFlag, cmdArgs.ServerPassword) + + // TODO: Remove when GRPC support is added + args = args.AppendLoggable(noGrpcFlag) + + if cmdArgs.Background { + // To start the server and run in the background + args = args.AppendLoggable(redirectToDevNull, runInBackground) + } + + return bashCommand(args) +} + +type ServerRefreshCommandArgs struct { + *CommandArgs + ServerAddress string + ServerUsername string + ServerPassword string + Fingerprint string +} + +// ServerRefresh returns the kopia command for refreshing the Kopia API Server +// This helps allow new users to be able to connect to the Server instead of waiting for auto-refresh +func ServerRefresh(cmdArgs ServerRefreshCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(serverSubCommand, refreshSubCommand) + args = args.AppendRedactedKV(serverCertFingerprint, cmdArgs.Fingerprint) + args = args.AppendLoggableKV(addressFlag, cmdArgs.ServerAddress) + args = args.AppendLoggableKV(serverUsernameFlag, cmdArgs.ServerUsername) + args = args.AppendRedactedKV(serverPasswordFlag, cmdArgs.ServerPassword) + + return stringSliceCommand(args) +} + +type ServerStatusCommandArgs struct { + *CommandArgs + ServerAddress string + ServerUsername string + ServerPassword string + Fingerprint string +} + +// ServerStatus returns the kopia command for checking status of the Kopia API Server +func ServerStatus(cmdArgs ServerStatusCommandArgs) []string { + args := commonArgs("", cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(serverSubCommand, statusSubCommand) + args = args.AppendLoggableKV(addressFlag, cmdArgs.ServerAddress) + args = args.AppendRedactedKV(serverCertFingerprint, cmdArgs.Fingerprint) + args = args.AppendLoggableKV(serverUsernameFlag, cmdArgs.ServerUsername) + args = args.AppendRedactedKV(serverPasswordFlag, cmdArgs.ServerPassword) + + return stringSliceCommand(args) +} + +type ServerListUserCommmandArgs struct { + *CommandArgs +} + +// ServerListUser returns the kopia command to list users from the Kopia API Server +func ServerListUser(cmdArgs ServerListUserCommmandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(serverSubCommand, userSubCommand, listSubCommand, jsonFlag) + + return stringSliceCommand(args) +} + +type ServerSetUserCommandArgs struct { + *CommandArgs + NewUsername string + UserPassword string +} + +// ServerSetUser returns the kopia command setting password for existing user for the Kopia API Server +func ServerSetUser(cmdArgs ServerSetUserCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(serverSubCommand, userSubCommand, setSubCommand, cmdArgs.NewUsername) + args = args.AppendRedactedKV(userPasswordFlag, cmdArgs.UserPassword) + + return stringSliceCommand(args) +} + +type ServerAddUserCommandArgs struct { + *CommandArgs + NewUsername string + UserPassword string +} + +// ServerAddUser returns the kopia command adding a new user to the Kopia API Server +func ServerAddUser(cmdArgs ServerAddUserCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(serverSubCommand, userSubCommand, addSubCommand, cmdArgs.NewUsername) + args = args.AppendRedactedKV(userPasswordFlag, cmdArgs.UserPassword) + + return stringSliceCommand(args) +} diff --git a/pkg/kopia/command/snapshot.go b/pkg/kopia/command/snapshot.go new file mode 100644 index 0000000000..8d31c93599 --- /dev/null +++ b/pkg/kopia/command/snapshot.go @@ -0,0 +1,139 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package command + +import ( + "strconv" + + "github.com/kanisterio/kanister/pkg/kopia" + "github.com/kanisterio/kanister/pkg/utils" +) + +const ( + // kube.Exec might timeout after 4h if there is no output from the command + // Setting it to 1h instead of 1000000h so that kopia logs progress once every hour + longUpdateInterval = "1h" + + requireLogLevelInfo = true +) + +type SnapshotCreateCommandArgs struct { + *CommandArgs + PathToBackup string +} + +// SnapshotCreate returns the kopia command for creation of a snapshot +// TODO: Have better mechanism to apply global flags +func SnapshotCreate(cmdArgs SnapshotCreateCommandArgs) []string { + parallelismStr := strconv.Itoa(utils.GetEnvAsIntOrDefault(kopia.DataStoreParallelUploadVarName, kopia.DefaultDataStoreParallelUpload)) + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, requireLogLevelInfo) + args = args.AppendLoggable(snapshotSubCommand, createSubCommand, cmdArgs.PathToBackup, jsonFlag) + args = args.AppendLoggableKV(parallelFlag, parallelismStr) + args = args.AppendLoggableKV(progressUpdateIntervalFlag, longUpdateInterval) + + return stringSliceCommand(args) +} + +type SnapshotRestoreCommandArgs struct { + *CommandArgs + SnapID string + TargetPath string + SparseRestore bool +} + +// SnapshotRestore returns kopia command restoring snapshots with given snap ID +func SnapshotRestore(cmdArgs SnapshotRestoreCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(snapshotSubCommand, restoreSubCommand, cmdArgs.SnapID, cmdArgs.TargetPath) + if cmdArgs.SparseRestore { + args = args.AppendLoggable(sparseFlag) + } + + return stringSliceCommand(args) +} + +type SnapshotDeleteCommandArgs struct { + *CommandArgs + SnapID string +} + +// SnapshotDelete returns the kopia command for deleting a snapshot with given snapshot ID +func SnapshotDelete(cmdArgs SnapshotDeleteCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(snapshotSubCommand, deleteSubCommand, cmdArgs.SnapID, unsafeIgnoreSourceFlag) + + return stringSliceCommand(args) +} + +type SnapshotExpireCommandArgs struct { + *CommandArgs + RootID string + MustDelete bool +} + +// SnapshotExpire returns the kopia command for removing snapshots with given root ID +func SnapshotExpire(cmdArgs SnapshotExpireCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(snapshotSubCommand, expireSubCommand, cmdArgs.RootID) + if cmdArgs.MustDelete { + args = args.AppendLoggable(deleteFlag) + } + + return stringSliceCommand(args) +} + +type SnapshotGCCommandArgs struct { + *CommandArgs +} + +// SnapshotGC returns the kopia command for issuing kopia snapshot gc +func SnapshotGC(cmdArgs SnapshotGCCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(snapshotSubCommand, gcSubCommand, deleteFlag) + + return stringSliceCommand(args) +} + +type SnapListAllCommandArgs struct { + *CommandArgs +} + +// SnapListAll returns the kopia command for listing all snapshots in the repository with their sizes +func SnapListAll(cmdArgs SnapListAllCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable( + snapshotSubCommand, + listSubCommand, + allFlag, + deltaFlag, + showIdenticalFlag, + jsonFlag, + ) + + return stringSliceCommand(args) +} + +type SnapListAllWithSnapIDsCommandArgs struct { + *CommandArgs +} + +// SnapListAllWithSnapIDs returns the kopia command for listing all snapshots in the repository with snapshotIDs +func SnapListAllWithSnapIDs(cmdArgs SnapListAllWithSnapIDsCommandArgs) []string { + args := commonArgs(cmdArgs.EncryptionKey, cmdArgs.ConfigFilePath, cmdArgs.LogDirectory, false) + args = args.AppendLoggable(manifestSubCommand, listSubCommand, jsonFlag) + args = args.AppendLoggableKV(filterFlag, kopia.ManifestTypeSnapshotFilter) + + return stringSliceCommand(args) +} diff --git a/pkg/kopia/const.go b/pkg/kopia/const.go new file mode 100644 index 0000000000..1d7c3adb57 --- /dev/null +++ b/pkg/kopia/const.go @@ -0,0 +1,56 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package kopia + +const ( + // DefaultClientConfigFilePath is the file which contains kopia repo config + DefaultClientConfigFilePath = "/tmp/kopia-repository.config" + + // DefaultClientCacheDirectory is the directory where kopia content cache is created + DefaultClientCacheDirectory = "/tmp/kopia-cache" + + // DefaultDataStoreGeneralContentCacheSizeMB is the default content cache size for general command workloads + DefaultDataStoreGeneralContentCacheSizeMB = 0 + // DataStoreGeneralContentCacheSizeMBVarName is the name of the environment variable that controls + // kopia content cache size for general command workloads + DataStoreGeneralContentCacheSizeMBVarName = "DATA_STORE_GENERAL_CONTENT_CACHE_SIZE_MB" + + // DefaultDataStoreGeneralMetadataCacheSizeMB is the default metadata cache size for general command workloads + DefaultDataStoreGeneralMetadataCacheSizeMB = 500 + // DataStoreGeneralMetadataCacheSizeMBVarName is the name of the environment variable that controls + // kopia metadata cache size for general command workloads + DataStoreGeneralMetadataCacheSizeMBVarName = "DATA_STORE_GENERAL_METADATA_CACHE_SIZE_MB" + + // DefaultDataStoreRestoreContentCacheSizeMB is the default content cache size for restore workloads + DefaultDataStoreRestoreContentCacheSizeMB = 500 + // DataStoreRestoreContentCacheSizeMBVarName is the name of the environment variable that controls + // kopia content cache size for restore workloads + DataStoreRestoreContentCacheSizeMBVarName = "DATA_STORE_RESTORE_CONTENT_CACHE_SIZE_MB" + + // DefaultDataStoreRestoreMetadataCacheSizeMB is the default metadata cache size for restore workloads + DefaultDataStoreRestoreMetadataCacheSizeMB = 500 + // DataStoreRestoreMetadataCacheSizeMBVarName is the name of the environment variable that controls + // kopia metadata cache size for restore workloads + DataStoreRestoreMetadataCacheSizeMBVarName = "DATA_STORE_RESTORE_METADATA_CACHE_SIZE_MB" + + // DefaultDataStoreParallelUpload is the default value for data store parallelism + DefaultDataStoreParallelUpload = 8 + + // DataStoreParallelUploadVarName is the name of the environment variable that controls + // kopia parallelism during snapshot create commands + DataStoreParallelUploadVarName = "DATA_STORE_PARALLEL_UPLOAD" + + ManifestTypeSnapshotFilter = "type:snapshot" +) diff --git a/pkg/kopia/errors.go b/pkg/kopia/errors.go new file mode 100644 index 0000000000..ce3f499afc --- /dev/null +++ b/pkg/kopia/errors.go @@ -0,0 +1,26 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package kopia + +import ( + "errors" +) + +var ( + ErrInvalidPassword = errors.New("invalid repository password") + ErrOutOfMemory = errors.New("kanister-tools container ran out of memory") + ErrAccessDenied = errors.New("Access Denied") + ErrRepoNotFound = errors.New("repository not found") +) diff --git a/pkg/kopia/maintenance/get_maintenance_owner.go b/pkg/kopia/maintenance/get_maintenance_owner.go new file mode 100644 index 0000000000..9671b8502c --- /dev/null +++ b/pkg/kopia/maintenance/get_maintenance_owner.go @@ -0,0 +1,82 @@ +// Copyright 2022 The Kanister Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package maintenance + +import ( + "strings" + + "github.com/kopia/kopia/repo/manifest" + "github.com/pkg/errors" + "k8s.io/client-go/kubernetes" + + "github.com/kanisterio/kanister/pkg/format" + "github.com/kanisterio/kanister/pkg/kopia/command" + "github.com/kanisterio/kanister/pkg/kube" +) + +// KopiaUserProfile is a duplicate of struct for Kopia user profiles since Profile struct is in internal/user package and could not be imported +type KopiaUserProfile struct { + ManifestID manifest.ID `json:"-"` + + Username string `json:"username"` + PasswordHashVersion int `json:"passwordHashVersion"` + PasswordHash []byte `json:"passwordHash"` +} + +// GetMaintenanceOwnerForConnectedRepository executes maintenance info command, parses output +// and returns maintenance owner +func GetMaintenanceOwnerForConnectedRepository( + cli kubernetes.Interface, + namespace, + pod, + container, + encryptionKey, + configFilePath, + logDirectory string, +) (string, error) { + args := command.MaintenanceInfoCommandArgs{ + CommandArgs: &command.CommandArgs{ + EncryptionKey: encryptionKey, + ConfigFilePath: configFilePath, + LogDirectory: logDirectory, + }, + GetJsonOutput: false, + } + cmd := command.MaintenanceInfo(args) + stdout, stderr, err := kube.Exec(cli, namespace, pod, container, cmd, nil) + format.Log(pod, container, stdout) + format.Log(pod, container, stderr) + if err != nil { + return "", err + } + parsedOwner := parseOutput(stdout) + if parsedOwner == "" { + return "", errors.New("Failed parsing maintenance info output to get owner") + } + return parsedOwner, nil +} + +func parseOutput(output string) string { + lines := strings.Split(output, "\n") + for _, line := range lines { + if strings.Contains(line, "Owner") { + arr := strings.Split(line, ":") + if len(arr) == 2 { + return strings.TrimSpace(arr[1]) + } + } + } + return "" +} diff --git a/pkg/kopia/utils.go b/pkg/kopia/utils.go index da3fcee1d2..c9c9a769e7 100644 --- a/pkg/kopia/utils.go +++ b/pkg/kopia/utils.go @@ -35,12 +35,6 @@ import ( ) const ( - // DefaultClientConfigFilePath is the file which contains kopia repo config - DefaultClientConfigFilePath = "/tmp/kopia-repository.config" - - // DefaultClientCacheDirectory is the directory where kopia content cache is created - DefaultClientCacheDirectory = "/tmp/kopia-cache" - // defaultDataStoreGeneralContentCacheSizeMB is the default content cache size for general command workloads defaultDataStoreGeneralContentCacheSizeMB = 0 @@ -58,7 +52,6 @@ const ( // use when describing repo ObjectStorePathOption = "objectStorePath" - // Kopia profile option keys // DataStoreGeneralContentCacheSizeMBKey is the key to pass content cache size for general command workloads DataStoreGeneralContentCacheSizeMBKey = "dataStoreGeneralContentCacheSize" // DataStoreGeneralMetadataCacheSizeMBKey is the key to pass metadata cache size for general command workloads From 122d3d2427f676501d512aeb39fcc16bbf885d44 Mon Sep 17 00:00:00 2001 From: Rajat Gupta <37516416+r4rajat@users.noreply.github.com> Date: Wed, 7 Sep 2022 20:24:02 +0530 Subject: [PATCH 11/15] Add Blueprint and integration test app for CockroachDB (#1585) * Added Blueprint for CockroachDB Signed-off-by: Rajat Gupta * Add newline at end of file Signed-off-by: Rajat Gupta * Add sample secure client manifest Signed-off-by: Rajat Gupta * Use KubeTask instead of KubeExec - Use KubeTask instead of KubeExec to spin a secure client pod on demand and run commands for backup and restore actions - Use ghcr.io/kanisterio/kanister-tools:0.81.0 image instead of ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 for delete action Signed-off-by: Rajat Gupta * Update README.md - Update README.md with updated commands - Fix typos Signed-off-by: Rajat Gupta * Update client-secure.yaml Signed-off-by: Rajat Gupta * Add Integration Test for Cockroachdb Signed-off-by: Rajat Gupta * Fix Typos Signed-off-by: Rajat Gupta * Remove sleep from Blueprint - Remove sleep time - Reduced Backup To duration from System Time - 10s to System Time - 1s Signed-off-by: Rajat Gupta * Fix Lint Issues Signed-off-by: Rajat Gupta * Soft Link CockroachDB Blueprint Signed-off-by: Rajat Gupta * Remove AS OF SYSTEM TIME Clause from Backup Query Signed-off-by: Rajat Gupta * Add --wait flag - Add --wait flag in helm chart installation implementation Signed-off-by: Rajat Gupta * Add --wait flag - Add --wait flag in helm chart installation implementation Signed-off-by: Rajat Gupta * Chnage Absolute Path to Relative in Symlink Co-authored-by: Akanksha kumari * Update Error Message Co-authored-by: Akanksha kumari * Update README.md - Update Restore and Installation section for better understanding * Update pkg/app/cockroachdb.go - Remove redundant comments - Remove unnecessary code - Sorted Imports * Add Error Message - Add Error Message in case either of ca.crt, tls.key or tls.crt is missing from cluster credentials Signed-off-by: Rajat Gupta * Added Blueprint for CockroachDB Signed-off-by: Rajat Gupta * Add newline at end of file Signed-off-by: Rajat Gupta * Add sample secure client manifest Signed-off-by: Rajat Gupta * Use KubeTask instead of KubeExec - Use KubeTask instead of KubeExec to spin a secure client pod on demand and run commands for backup and restore actions - Use ghcr.io/kanisterio/kanister-tools:0.81.0 image instead of ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 for delete action Signed-off-by: Rajat Gupta * Update README.md - Update README.md with updated commands - Fix typos Signed-off-by: Rajat Gupta * Update client-secure.yaml Signed-off-by: Rajat Gupta * Add Integration Test for Cockroachdb Signed-off-by: Rajat Gupta * Fix Typos Signed-off-by: Rajat Gupta * Remove sleep from Blueprint - Remove sleep time - Reduced Backup To duration from System Time - 10s to System Time - 1s Signed-off-by: Rajat Gupta * Fix Lint Issues Signed-off-by: Rajat Gupta * Soft Link CockroachDB Blueprint Signed-off-by: Rajat Gupta * Remove AS OF SYSTEM TIME Clause from Backup Query Signed-off-by: Rajat Gupta * Chnage Absolute Path to Relative in Symlink Co-authored-by: Akanksha kumari * Update Error Message Co-authored-by: Akanksha kumari * Update README.md - Update Restore and Installation section for better understanding * Update pkg/app/cockroachdb.go - Remove redundant comments - Remove unnecessary code - Sorted Imports * Add Error Message - Add Error Message in case either of ca.crt, tls.key or tls.crt is missing from cluster credentials Signed-off-by: Rajat Gupta * Update Install Method with wait as false * Add CockroachDB in Integration Tests * Remove else while reading cluster credentials * Update README.md - Update description of installation of client-secure pod * Add comments in IsReady Method for additional steps Signed-off-by: Rajat Gupta * Update Comments in IsReady Method Signed-off-by: Rajat Gupta * Update Comments in IsReady Method Signed-off-by: Rajat Gupta * Update Comments in IsReady Method Signed-off-by: Rajat Gupta * Update Comments in IsReady Method Signed-off-by: Rajat Gupta * Update Comments Signed-off-by: Rajat Gupta * Update README.md Signed-off-by: Rajat Gupta * Update integration-test.sh Signed-off-by: Rajat Gupta Signed-off-by: Rajat Gupta Signed-off-by: Rajat Gupta Co-authored-by: Akanksha kumari --- build/integration-test.sh | 2 +- examples/cockroachdb/README.md | 269 +++++++++++++++ examples/cockroachdb/client-secure.yaml | 45 +++ .../cockroachdb/cockroachdb-blueprint.yaml | 164 +++++++++ pkg/app/cockroachdb.go | 315 ++++++++++++++++++ .../blueprints/cockroachdb-blueprint.yaml | 1 + pkg/helm/client.go | 4 + pkg/testing/integration_register.go | 15 + 8 files changed, 814 insertions(+), 1 deletion(-) create mode 100755 examples/cockroachdb/README.md create mode 100644 examples/cockroachdb/client-secure.yaml create mode 100644 examples/cockroachdb/cockroachdb-blueprint.yaml create mode 100644 pkg/app/cockroachdb.go create mode 120000 pkg/blueprint/blueprints/cockroachdb-blueprint.yaml diff --git a/build/integration-test.sh b/build/integration-test.sh index e717318d83..72b367f471 100755 --- a/build/integration-test.sh +++ b/build/integration-test.sh @@ -25,7 +25,7 @@ TEST_TIMEOUT="30m" # Set default options TEST_OPTIONS="-tags=integration -timeout ${TEST_TIMEOUT} -check.suitep ${DOP}" # Regex to match apps to run in short mode -SHORT_APPS="^PostgreSQL$|^MySQL$|Elasticsearch|^MongoDB$|Maria|^MSSQL$" +SHORT_APPS="^PostgreSQL$|^MySQL$|Elasticsearch|^MongoDB$|Maria|^MSSQL$|^CockroachDB$" # OCAPPS has all the apps that are to be tested against openshift cluster OC_APPS3_11="MysqlDBDepConfig$|MongoDBDepConfig$|PostgreSQLDepConfig$" OC_APPS4_4="MysqlDBDepConfig4_4|MongoDBDepConfig4_4|PostgreSQLDepConfig4_4" diff --git a/examples/cockroachdb/README.md b/examples/cockroachdb/README.md new file mode 100755 index 0000000000..76dad58151 --- /dev/null +++ b/examples/cockroachdb/README.md @@ -0,0 +1,269 @@ +# CockroachDB + +[CockroachDB](https://www.cockroachlabs.com/) is one of the database servers based on SQL. + +## Introduction + +This chart bootstraps a three node CockroachDB deployment on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. + +## Prerequisites + +- Kubernetes 1.16+ with Beta APIs enabled +- PV provisioner support in the underlying infrastructure +- Kanister controller version 0.80.0 installed in your cluster, let's assume in Namespace `kanister` +- Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) + +## Installing the Chart + +The commands mentioned below could be run to install the CockroachDB database using the `cockroachdb` chart with the release name `cockroachdb-release`: + +```bash +# Add cockroachdb in your local chart repository +$ helm repo add cockroachdb https://charts.cockroachdb.com/ + +# Update your local chart repository +$ helm repo update + +# Install the cockroachdb in cockroachdb namespace +$ helm install cockroachdb-release --namespace cockroachdb --create-namespace cockroachdb/cockroachdb + +# In order to interact with the CockroachDB Cluster, install the secure cockroachdb client +# Download latest secure client manifest +$ curl -O https://raw.githubusercontent.com/cockroachdb/helm-charts/master/examples/client-secure.yaml + +# Edit Fields in client-secure.yaml. A sample manifest file is being included for reference. +# Value of spec.serviceAccountName should be same as your release name +spec.serviceAccountName: cockroachdb-release +# Find the latest tag of image cockroachdb/cockroach from https://github.com/cockroachdb/helm-charts/blob/master/cockroachdb/values.yaml +spec.image: cockroachdb/cockroach: +# Value of spec.volumes[0].project.sources[0].secret.name should be -client-secret +spec.volumes[0].project.sources[0].secret.name: cockroachdb-release-client-secret + +$ kubectl create -f ./client-secure.yaml -n cockroachdb +``` + +> **Tip**: List all releases using `helm list --all-namespaces`, using Helm Version 3. + +## Integrating with Kanister + +If you have deployed CockroachDB application with name other than `cockroachdb-release` and namespace other than `cockroachdb`, you need to modify the commands (backup, restore and delete) used below to use the correct release name and namespace. +### Create Profile +Create Profile if not created already, and set the values accordingly + +```bash +$ kanctl create profile s3compliant --access-key \ + --secret-key \ + --bucket --region \ + --namespace kanister +``` + +You can read more about the Profile custom Kanister resource [here](https://docs.kanister.io/architecture.html?highlight=profile#profiles). + +**NOTE:** + +The above command will configure a location where artifacts resulting from Kanister +data operations such as backup should go. This is stored as a `profiles.cr.kanister.io` +*CustomResource (CR)* which is then referenced in Kanister ActionSets. Every ActionSet +requires a Profile reference to complete the action. This CR (`profiles.cr.kanister.io`) +can be shared between Kanister-enabled application instances. + +### Create Blueprint + +Create Blueprint in the same namespace as the Kanister controller + +```bash +$ kubectl create -f ./cockroachdb-blueprint.yaml -n kanister +``` + +Once CockroachDB is running, you can populate it with some data. Let's add a table called "accounts" to a bank database: + +```bash +# Connect to Secure Client Shell by running a shell inside cockroachdb-client-secure pod +$ kubectl exec -it -n cockroachdb cockroachdb-client-secure -- ./cockroach sql --certs-dir=./cockroach-certs --host=cockroachdb-release-public + +# From inside the shell, use the CLI to insert some data into the bank database +# Create "bank" db +> CREATE DATABASE bank; + +# Create "accounts" table +> CREATE TABLE bank.accounts (id INT PRIMARY KEY, balance DECIMAL); + +# Insert row to the table +> INSERT INTO bank.accounts VALUES (1, 1000.50); +> INSERT INTO bank.accounts VALUES (2, 2000.70); + +# View data in "accounts" table +> SELECT * FROM bank.accounts; + + id | balance ++----+---------+ + 1 | 1000.50 + 2 | 2000.70 +(2 rows) + +``` + +## Protect the Application + +You can now take a backup of the CockroachDB data using an ActionSet defining backup for this application. Create an ActionSet in the same namespace as the controller. + +```bash +# Find profile name +$ kubectl get profile -n kanister +NAME AGE +s3-profile-drnw9 2m + +# Find client secret name +$ kubectl get secrets -n cockroachdb +NAME TYPE DATA AGE +cockroachdb-release-ca-secret Opaque 2 6h38m +cockroachdb-release-client-secret kubernetes.io/tls 3 6h38m <<--- +cockroachdb-release-node-secret kubernetes.io/tls 3 6h38m +sh.helm.release.v1.cockroachdb-release.v1 helm.sh/release.v1 1 6h38m + +# Create Actionset +# Please make sure the value of blueprint matches with the name of blueprint that we have created already +$ kanctl create actionset --action backup --namespace kanister --blueprint cockroachdb-blueprint --statefulset cockroachdb/cockroachdb-release --profile kanister/s3-profile-drnw9 --secrets cockroachSecret=cockroachdb/cockroachdb-release-client-secret +actionset backup-rslmb created + +$ kubectl --namespace kanister get actionsets.cr.kanister.io +NAME AGE +backup-rslmb 1m + +# View the status of the actionset +# Please make sure the name of the actionset here matches with name of the name of actionset that we have created already +$ kubectl --namespace kanister describe actionset backup-rslmb +``` + +### Disaster strikes! + +Let's say someone accidentally deleted the test database using the following command: +```bash +# Connect to Secure Client Shell by running a shell inside cockroachdb-client-secure pod +$ kubectl exec -it -n cockroachdb cockroachdb-client-secure -- ./cockroach sql --certs-dir=./cockroach-certs --host=cockroachdb-release-public + +# Drop the test database +> SHOW DATABASES; + database_name | owner | primary_region | regions | survival_goal +----------------+-------+----------------+---------+---------------- + bank | root | NULL | {} | NULL + defaultdb | root | NULL | {} | NULL + postgres | root | NULL | {} | NULL + system | node | NULL | {} | NULL +(4 rows) + +> DROP DATABASE bank CASCADE; +Query OK, 1 row affected (0.03 sec) + +> SHOW DATABASES; + database_name | owner | primary_region | regions | survival_goal +----------------+-------+----------------+---------+---------------- + defaultdb | root | NULL | {} | NULL + postgres | root | NULL | {} | NULL + system | node | NULL | {} | NULL +(3 rows) + +``` + +### Restore the Application + +To restore the missing data, you should use the backup that you created before. An easy way to do this is to leverage `kanctl`, a command-line tool that helps create ActionSets that depend on other ActionSets: +> **Note** : CockroachDB uses [Garbage Collection](https://www.cockroachlabs.com/docs/stable/architecture/storage-layer.html#garbage-collection), So in order to perform Full Cluster Restore on same cluster, one must wait out the Default Garbage Collection Run After Time i.e. 90,000 Seconds or 25 Hours. +> On the other hand the following step is Not Required if snapshot is being restored on a new DB cluster. +> In Order to reduce the Garbage Collection time, run the following command, wait for a minute and let cockroachdb to automatic garbage collection. And then use kanctl to create restore action. +```bash +$ ALTER RANGE default CONFIGURE ZONE USING gc.ttlseconds = 60; +``` +```bash +# Make sure to use correct backup actionset name here +$ kanctl --namespace kanister create actionset --action restore --from "backup-rslmb" +actionset restore-backup-62vxm-2hdsz created + +# View the status of the ActionSet +# Make sure to use correct restore actionset name here +$ kubectl --namespace kanister describe actionset restore-backup-62vxm-2hdsz +``` + +Once the ActionSet status is set to "complete", you can see that the data has been successfully restored to CockroachDB + +```bash +> SHOW DATABASES; + database_name | owner | primary_region | regions | survival_goal +----------------+-------+----------------+---------+---------------- + bank | root | NULL | {} | NULL + defaultdb | root | NULL | {} | NULL + postgres | root | NULL | {} | NULL + system | node | NULL | {} | NULL +(4 rows) + +> USE bank; + +Database changed +> SHOW TABLES; ++----------------+ +| Tables | ++----------------+ +| accounts | ++----------------+ +1 row in set (0.00 sec) + +> SELECT * FROM bank.accounts; + id | balance ++----+---------+ + 1 | 1000.50 + 2 | 2000.70 +``` + +### Delete the Artifacts + +The artifacts created by the backup action can be cleaned up using the following command: + +```bash +$ kanctl --namespace kanister create actionset --action delete --from backup-rslmb --namespacetargets kanister +actionset delete-backup-glptq-cq6bw created + +# View the status of the ActionSet +$ kubectl --namespace kanister describe actionset delete-backup-glptq-cq6bw +``` + + +## Troubleshooting + +If you run into any issues with the above commands, you can check the logs of the controller using: + +```bash +$ kubectl --namespace kanister logs -l app=kanister-operator +``` + +you can also check events of the actionset + +```bash +$ kubectl describe actionset restore-backup-62vxm-2hdsz -n kanister +``` + + +## Cleanup + +### Uninstalling the Chart + +To uninstall/delete the `cockroachdb-release` deployment: + +```bash +# Helm Version 3 +$ helm delete cockroachdb-release -n cockroachdb +``` + +The command removes all the Kubernetes components associated with the chart and deletes the release. + +### Delete CRs +Remove Blueprint and Profile CR + +```bash +$ kubectl delete blueprints.cr.kanister.io cockroachdb-blueprint -n kanister + +$ kubectl get profiles.cr.kanister.io -n kanister +NAME AGE +s3-profile-drnw9 122m + +$ kubectl delete profiles.cr.kanister.io s3-profile-drnw9 -n kanister +``` diff --git a/examples/cockroachdb/client-secure.yaml b/examples/cockroachdb/client-secure.yaml new file mode 100644 index 0000000000..f24c9e3678 --- /dev/null +++ b/examples/cockroachdb/client-secure.yaml @@ -0,0 +1,45 @@ +# Copyright 2021 The Cockroach Authors +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +apiVersion: v1 +kind: Pod +metadata: + name: cockroachdb-client-secure +spec: + serviceAccountName: cockroachdb-release # Change to {release} + containers: + - name: cockroachdb-client-secure + image: cockroachdb/cockroach:v22.1.5 # Change to cockroachdb/cockroach:{version} + imagePullPolicy: IfNotPresent + volumeMounts: + - name: client-certs + mountPath: /cockroach/cockroach-certs/ + command: + - sleep + - "2147483648" # 2^31 + terminationGracePeriodSeconds: 0 + volumes: + - name: client-certs + projected: + sources: + - secret: + name: cockroachdb-release-client-secret # Change to {release}-client-secret + items: + - key: ca.crt + path: ca.crt + - key: tls.crt + path: client.root.crt + - key: tls.key + path: client.root.key + defaultMode: 256 diff --git a/examples/cockroachdb/cockroachdb-blueprint.yaml b/examples/cockroachdb/cockroachdb-blueprint.yaml new file mode 100644 index 0000000000..16d8884b00 --- /dev/null +++ b/examples/cockroachdb/cockroachdb-blueprint.yaml @@ -0,0 +1,164 @@ +apiVersion: cr.kanister.io/v1alpha1 +kind: Blueprint +metadata: + name: cockroachdb-blueprint +actions: + backup: + secretNames: + - cockroachSecret + outputArtifacts: + cockroachDBCloudDump: + keyValue: + s3path: '/cockroachdb-backups/{{ .StatefulSet.Namespace }}/{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}/{{ toDate "2006-01-02T15:04:05.999999999Z07:00" .Time | date "2006-01-02T15-04-05" }}' + phases: + - func: KubeTask + name: backupToS3 + args: + namespace: "{{ .StatefulSet.Namespace }}" + image: "cockroachdb/cockroach" + podOverride: + containers: + - name: container + volumeMounts: + - mountPath: /cockroach/cockroach-certs/ + name: client-certs + volumes: + - name: client-certs + projected: + sources: + - secret: + name: '{{ .Secrets.cockroachSecret.Name }}' + items: + - key: ca.crt + path: ca.crt + - key: tls.crt + path: client.root.crt + - key: tls.key + path: client.root.key + defaultMode: 256 + + command: + - bash + - -o + - errexit + - -o + - xtrace + - -o + - pipefail + - -c + - | + host='{{ .StatefulSet.Name }}'-public + aws_access_key_id='{{ toJson .Profile.Credential.KeyPair.ID | toString }}' + aws_access_key_id=`echo $aws_access_key_id | tr -d \"` + aws_access_key_secret='{{ toJson .Profile.Credential.KeyPair.Secret | toString }}' + aws_access_key_secret=`echo $aws_access_key_secret | tr -d \"` + bucket='{{ toJson .Profile.Location.Bucket | toString }}' + bucket=`echo $bucket | tr -d \"` + aws_endpoint='{{ toJson .Profile.Location.Endpoint | toString }}' + aws_endpoint=`echo $aws_endpoint | tr -d \"` + aws_region='{{ toJson .Profile.Location.Region | toString }}' + aws_region=`echo $aws_region | tr -d \"` + s3path='s3://'${bucket}'/cockroachdb-backups/{{ .StatefulSet.Namespace }}/{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}/{{ toDate "2006-01-02T15:04:05.999999999Z07:00" .Time | date "2006-01-02T15-04-05" }}' + if [ -z "$aws_region" ] + then + if [ -z "$aws_endpoint" ] + then + cmd="BACKUP INTO '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}' AS OF SYSTEM TIME '-10s';" + else + cmd="BACKUP INTO '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}&AWS_ENDPOINT=${aws_endpoint}' AS OF SYSTEM TIME '-10s';" + fi + else + if [ -z "$aws_endpoint" ] + then + cmd="BACKUP INTO '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}&AWS_REGION=${aws_region}' AS OF SYSTEM TIME '-10s';" + else + cmd="BACKUP INTO '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}&AWS_ENDPOINT=${aws_endpoint}&AWS_REGION=${aws_region}';" + fi + fi + cockroach sql --certs-dir=/cockroach/cockroach-certs --host="${host}" -e "${cmd}" + + restore: + inputArtifactNames: + - cockroachDBCloudDump + phases: + - func: KubeTask + name: restoreFromS3 + args: + namespace: "{{ .StatefulSet.Namespace }}" + image: "cockroachdb/cockroach" + podOverride: + containers: + - name: container + volumeMounts: + - mountPath: /cockroach/cockroach-certs/ + name: client-certs + volumes: + - name: client-certs + projected: + sources: + - secret: + name: '{{ .Secrets.cockroachSecret.Name }}' + items: + - key: ca.crt + path: ca.crt + - key: tls.crt + path: client.root.crt + - key: tls.key + path: client.root.key + defaultMode: 256 + command: + - bash + - -o + - errexit + - -o + - pipefail + - -c + - | + host='{{ .StatefulSet.Name }}'-public + aws_access_key_id='{{ toJson .Profile.Credential.KeyPair.ID | toString }}' + aws_access_key_id=`echo $aws_access_key_id | tr -d \"` + aws_access_key_secret='{{ toJson .Profile.Credential.KeyPair.Secret | toString }}' + aws_access_key_secret=`echo $aws_access_key_secret | tr -d \"` + bucket='{{ toJson .Profile.Location.Bucket | toString }}' + bucket=`echo $bucket | tr -d \"` + aws_endpoint='{{ toJson .Profile.Location.Endpoint | toString }}' + aws_endpoint=`echo $aws_endpoint | tr -d \"` + aws_region='{{ toJson .Profile.Location.Region | toString }}' + aws_region=`echo $aws_region | tr -d \"` + s3path='s3://'${bucket}'{{ .ArtifactsIn.cockroachDBCloudDump.KeyValue.s3path }}' + if [ -z "$aws_region" ] + then + if [ -z "$aws_endpoint" ] + then + cmd="RESTORE FROM LATEST IN '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}';" + else + cmd="RESTORE FROM LATEST IN '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}&AWS_ENDPOINT=${aws_endpoint}';" + fi + else + if [ -z "$aws_endpoint" ] + then + cmd="RESTORE FROM LATEST IN '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}&AWS_REGION=${aws_region}';" + else + cmd="RESTORE FROM LATEST IN '${s3path}?AWS_ACCESS_KEY_ID=${aws_access_key_id}&AWS_SECRET_ACCESS_KEY=${aws_access_key_secret}&AWS_ENDPOINT=${aws_endpoint}&AWS_REGION=${aws_region}';" + fi + fi + cockroach sql --certs-dir=/cockroach/cockroach-certs --host="${host}" -e "${cmd}" + + delete: + inputArtifactNames: + - cockroachDBCloudDump + phases: + - func: KubeTask + name: deleteFromS3Store + args: + image: ghcr.io/kanisterio/kanister-tools:0.81.0 + namespace: "{{ .Namespace.Name }}" + command: + - bash + - -o + - errexit + - -o + - pipefail + - -c + - | + kando location delete --profile '{{ toJson .Profile }}' --path '{{ .ArtifactsIn.cockroachDBCloudDump.KeyValue.s3path }}' diff --git a/pkg/app/cockroachdb.go b/pkg/app/cockroachdb.go new file mode 100644 index 0000000000..a07ff5927d --- /dev/null +++ b/pkg/app/cockroachdb.go @@ -0,0 +1,315 @@ +package app + +import ( + "context" + "fmt" + "strconv" + "strings" + "time" + + "github.com/pkg/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/kubernetes" + + crv1alpha1 "github.com/kanisterio/kanister/pkg/apis/cr/v1alpha1" + "github.com/kanisterio/kanister/pkg/field" + "github.com/kanisterio/kanister/pkg/helm" + "github.com/kanisterio/kanister/pkg/kube" + "github.com/kanisterio/kanister/pkg/log" + "github.com/kanisterio/kanister/pkg/poll" +) + +const cReadyTimeout = 10 * time.Minute + +type CockroachDB struct { + name string + namespace string + cacrt string + tlscrt string + tlskey string + cli kubernetes.Interface + chart helm.ChartInfo +} + +// NewCockroachDB Last tested working version "22.1.5" +func NewCockroachDB(name string) App { + return &CockroachDB{ + name: name, + chart: helm.ChartInfo{ + Release: appendRandString(name), + RepoName: helm.CockroachDBRepoName, + RepoURL: helm.CockroachDBRepoURL, + Chart: "cockroachdb", + Values: map[string]string{ + "image.tag": "v22.1.5", + "image.pullPolicy": "IfNotPresent", + }, + }, + } +} + +func (c *CockroachDB) Init(context.Context) error { + cfg, err := kube.LoadConfig() + if err != nil { + return err + } + c.cli, err = kubernetes.NewForConfig(cfg) + return err +} + +func (c *CockroachDB) Install(ctx context.Context, namespace string) error { + log.Info().Print("Installing cockroachdb cluster helm chart.", field.M{"app": c.name}) + c.namespace = namespace + + cli, err := helm.NewCliClient() + if err != nil { + return errors.Wrap(err, "failed to create helm client") + } + + if err = cli.AddRepo(ctx, c.chart.RepoName, c.chart.RepoURL); err != nil { + return errors.Wrapf(err, "Failed to install helm repo. app=%s repo=%s", c.name, c.chart.RepoName) + } + + err = cli.Install(ctx, fmt.Sprintf("%s/%s", c.chart.RepoName, c.chart.Chart), c.chart.Version, c.chart.Release, c.namespace, c.chart.Values, false) + return errors.Wrapf(err, "Failed to install helm chart. app=%s chart=%s release=%s", c.name, c.chart.Chart, c.chart.Release) +} + +func (c *CockroachDB) IsReady(ctx context.Context) (bool, error) { + log.Info().Print("Waiting for cockroachdb cluster to be ready.", field.M{"app": c.name, "namespace": c.namespace, "release": c.chart.Release}) + ctx, cancel := context.WithTimeout(ctx, cReadyTimeout) + defer cancel() + err := kube.WaitOnStatefulSetReady(ctx, c.cli, c.namespace, c.chart.Release) + if err != nil { + log.WithError(err).Print("Error Occurred --> ", field.M{"error": err.Error()}) + return false, err + } + log.Info().Print("Application instance is ready.", field.M{"app": c.name}) + + // Get the secret that gets installed with Cockroach DB installation + // and read the client certs from that secret. + // These client certs are then stored in a directory in client pod so + // that we can use them later to communicate with cockroach DB + // cluster, and executing queries like Creating Database and Table, + // Inserting Data, Setting up Garbage Collection Time, + // Delete Database etc + secret, err := c.cli.CoreV1().Secrets(c.namespace).Get(ctx, fmt.Sprintf("%s-client-secret", c.chart.Release), metav1.GetOptions{}) + if err != nil { + return false, err + } + + if _, exist := secret.Data["ca.crt"]; !exist { + return false, errors.Errorf("Error: ca.crt not found in the cluster credential %s-client-secret", c.chart.Release) + } + c.cacrt = string(secret.Data["ca.crt"]) + + if _, exist := secret.Data["tls.crt"]; !exist { + return false, errors.Errorf("Error: tls.crt not found in the cluster credential %s-client-secret", c.chart.Release) + } + c.tlscrt = string(secret.Data["tls.crt"]) + + if _, exist := secret.Data["tls.key"]; !exist { + return false, errors.Errorf("Error: tls.key not found in the cluster credential %s-client-secret", c.chart.Release) + } + c.tlskey = string(secret.Data["tls.key"]) + + createCrtDirCmd := "mkdir -p /cockroach/cockroach-client-certs" + createCrtDir := []string{"sh", "-c", createCrtDirCmd} + _, stderr, err := c.execCommand(ctx, createCrtDir) + if err != nil { + return false, errors.Wrapf(err, "Error while Creating Cert Directory %s", stderr) + } + + createCaCrtCmd := fmt.Sprintf("echo '%s' >> /cockroach/cockroach-client-certs/ca.crt", c.cacrt) + createCaCrt := []string{"sh", "-c", createCaCrtCmd} + _, stderr, err = c.execCommand(ctx, createCaCrt) + if err != nil { + return false, errors.Wrapf(err, "Error while Creating ca.crt %s", stderr) + } + + createTlsCrtCmd := fmt.Sprintf("echo '%s'>> /cockroach/cockroach-client-certs/client.root.crt", c.tlscrt) + createTlsCrt := []string{"sh", "-c", createTlsCrtCmd} + _, stderr, err = c.execCommand(ctx, createTlsCrt) + if err != nil { + return false, errors.Wrapf(err, "Error while Creating tls.crt %s", stderr) + } + + createTlsKeyCmd := fmt.Sprintf("echo '%s' >> /cockroach/cockroach-client-certs/client.root.key", c.tlskey) + createTlsKey := []string{"sh", "-c", createTlsKeyCmd} + _, stderr, err = c.execCommand(ctx, createTlsKey) + if err != nil { + return false, errors.Wrapf(err, "Error while Creating tls.key %s", stderr) + } + + changeFilePermCmd := "cd /cockroach/cockroach-client-certs/ && chmod 0600 *" + changeFilePerm := []string{"sh", "-c", changeFilePermCmd} + _, stderr, err = c.execCommand(ctx, changeFilePerm) + if err != nil { + return false, errors.Wrapf(err, "Error while changing certificate file permissions %s", stderr) + } + + changeDefaultGCTimeCmd := "./cockroach sql --certs-dir=/cockroach/cockroach-client-certs -e 'ALTER RANGE default CONFIGURE ZONE USING gc.ttlseconds = 10;'" + changeDefaultGCTime := []string{"sh", "-c", changeDefaultGCTimeCmd} + _, stderr, err = c.execCommand(ctx, changeDefaultGCTime) + if err != nil { + return false, errors.Wrapf(err, "Error while setting up Garbage Collection time %s", stderr) + } + + return err == nil, err +} + +func (c *CockroachDB) Object() crv1alpha1.ObjectReference { + return crv1alpha1.ObjectReference{ + Kind: "statefulset", + Name: c.chart.Release, + Namespace: c.namespace, + } +} + +func (c *CockroachDB) Uninstall(ctx context.Context) error { + cli, err := helm.NewCliClient() + if err != nil { + return errors.Wrap(err, "failed to create helm client") + } + err = cli.Uninstall(ctx, c.chart.Release, c.namespace) + if err != nil { + log.WithError(err).Print("Failed to uninstall app, you will have to uninstall it manually.", field.M{"app": c.name}) + return err + } + log.Print("Uninstalled application.", field.M{"app": c.name}) + + return nil +} + +func (c *CockroachDB) GetClusterScopedResources(context.Context) []crv1alpha1.ObjectReference { + return nil +} + +func (c *CockroachDB) Ping(ctx context.Context) error { + log.Print("Pinging the cockroachdb database.", field.M{"app": c.name}) + + loginCmd := fmt.Sprintf("./cockroach sql --certs-dir=/cockroach/cockroach-client-certs --host=%s-public", c.chart.Release) + login := []string{"sh", "-c", loginCmd} + _, stderr, err := c.execCommand(ctx, login) + if err != nil { + return errors.Wrapf(err, "Error while pinging database %s", stderr) + } + + log.Print("Ping to the application was success.", field.M{"app": c.name}) + return nil +} + +// Initialize is used to initialize the database or create schema +func (c *CockroachDB) Initialize(ctx context.Context) error { + createDatabaseCMD := "./cockroach sql --certs-dir=/cockroach/cockroach-client-certs -e 'CREATE DATABASE bank; CREATE TABLE bank.accounts (id INT, balance DECIMAL);'" + createDatabase := []string{"sh", "-c", createDatabaseCMD} + _, stderr, err := c.execCommand(ctx, createDatabase) + if err != nil { + return errors.Wrapf(err, "Error while initializing: %s", stderr) + } + return nil +} + +func (c *CockroachDB) Insert(ctx context.Context) error { + log.Print("Inserting some records in cockroachdb instance.", field.M{"app": c.name}) + + insertRecordCMD := "./cockroach sql --certs-dir=/cockroach/cockroach-client-certs -e 'INSERT INTO bank.accounts VALUES (1, 1000.50);'" + insertRecord := []string{"sh", "-c", insertRecordCMD} + _, stderr, err := c.execCommand(ctx, insertRecord) + if err != nil { + return errors.Wrapf(err, "Error while inserting the data into database: %s", stderr) + } + + log.Print("Successfully inserted records in the application.", field.M{"app": c.name}) + return nil +} + +func (c *CockroachDB) Count(ctx context.Context) (int, error) { + log.Print("Counting the records from the cockroachdb instance.", field.M{"app": c.name}) + + selectRowsCMD := "./cockroach sql --certs-dir=/cockroach/cockroach-client-certs -e 'SELECT COUNT(*) FROM bank.accounts;'" + selectRows := []string{"sh", "-c", selectRowsCMD} + stdout, stderr, err := c.execCommand(ctx, selectRows) + if err != nil { + return 0, errors.Wrapf(err, "Error while counting the data of the database: %s", stderr) + } + // output returned from above query is "count\n3" + // get the returned count and convert it to int, to return + rowsReturned, err := strconv.Atoi(strings.Split(stdout, "\n")[1]) + if err != nil { + return 0, errors.Wrapf(err, "Error while converting row count to int.") + } + log.Print("Count that we received from application is.", field.M{"app": c.name, "count": rowsReturned}) + return rowsReturned, nil +} + +func (c *CockroachDB) Reset(ctx context.Context) error { + timeoutCtx, waitCancel := context.WithTimeout(ctx, cReadyTimeout) + defer waitCancel() + err := poll.Wait(timeoutCtx, func(ctx context.Context) (bool, error) { + err := c.Ping(ctx) + return err == nil, nil + }) + + if err != nil { + return errors.Wrapf(err, "Error waiting for application %s to be ready to reset it", c.name) + } + + log.Print("Resetting the cockroachdb instance.", field.M{"app": "cockroachdb"}) + + // delete all the data from the table + deleteFromTableCMD := "./cockroach sql --certs-dir=/cockroach/cockroach-client-certs -e 'DROP DATABASE IF EXISTS bank;'" + deleteFromTable := []string{"sh", "-c", deleteFromTableCMD} + _, stderr, err := c.execCommand(ctx, deleteFromTable) + if err != nil { + return errors.Wrapf(err, "Error while dropping the table: %s", stderr) + } + // Even though the table is deleted from the database, it's present in the + // descriptor table. We will have to wait for it to be deleted from there as + // well (using garbage collection), so that we can restore the snapshot in + // the same DB cluster. + err = poll.Wait(timeoutCtx, func(ctx context.Context) (bool, error) { + err = c.waitForGC(ctx) + return err == nil, nil + }) + log.Print("Reset of the application was successful.", field.M{"app": c.name}) + + return nil +} + +func (c *CockroachDB) ConfigMaps() map[string]crv1alpha1.ObjectReference { + return nil +} + +func (c *CockroachDB) Secrets() map[string]crv1alpha1.ObjectReference { + return map[string]crv1alpha1.ObjectReference{ + "cockroachSecret": { + Kind: "Secret", + Name: c.chart.Release + "-client-secret", + Namespace: c.namespace, + }, + } +} + +func (c *CockroachDB) execCommand(ctx context.Context, command []string) (string, string, error) { + podName, containerName, err := kube.GetPodContainerFromStatefulSet(ctx, c.cli, c.namespace, c.chart.Release) + if err != nil || podName == "" { + return "", "", errors.Wrapf(err, "Error getting pod and container name %s.", c.name) + } + return kube.Exec(c.cli, c.namespace, podName, containerName, command, nil) +} + +func (c *CockroachDB) waitForGC(ctx context.Context) error { + log.Info().Print("Getting Data from descriptor table", field.M{"app": c.name}) + getDescriptorCMD := "./cockroach sql --certs-dir=/cockroach/cockroach-client-certs -e 'SELECT * FROM system.descriptor;'" + getDescriptor := []string{"sh", "-c", getDescriptorCMD} + stdout, stderr, err := c.execCommand(ctx, getDescriptor) + if err != nil { + return errors.Wrapf(err, "Error while getiing descriptor table data: %s", stderr) + } + bankInDescriptor := strings.Contains(stdout, "bank") || strings.Contains(stdout, "account") + log.Info().Print("bankInDescriptor: ", field.M{"value": bankInDescriptor}) + if bankInDescriptor { + return errors.New("Bank Database exists. Waiting for garbage collector to run and remove the database") + } + return nil +} diff --git a/pkg/blueprint/blueprints/cockroachdb-blueprint.yaml b/pkg/blueprint/blueprints/cockroachdb-blueprint.yaml new file mode 120000 index 0000000000..4bc64cb58b --- /dev/null +++ b/pkg/blueprint/blueprints/cockroachdb-blueprint.yaml @@ -0,0 +1 @@ +../../../examples/cockroachdb/cockroachdb-blueprint.yaml \ No newline at end of file diff --git a/pkg/helm/client.go b/pkg/helm/client.go index 159827cf77..f44cf9b280 100644 --- a/pkg/helm/client.go +++ b/pkg/helm/client.go @@ -47,6 +47,10 @@ const ( KafkaOperatorRepoName = "strimzi" KafkaOperatorRepoURL = "https://strimzi.io/charts" + // Add cockroachdb chart + CockroachDBRepoName = "cockroachdb" + CockroachDBRepoURL = "https://charts.cockroachdb.com/" + // HelmVersion to differentiate between helm2 and helm3 commands V2 HelmVersion = "helmv2" V3 HelmVersion = "helmv3" diff --git a/pkg/testing/integration_register.go b/pkg/testing/integration_register.go index 9363ade87e..24bc7536ae 100644 --- a/pkg/testing/integration_register.go +++ b/pkg/testing/integration_register.go @@ -70,6 +70,21 @@ var _ = Suite(&MySQL{ }, }) +// cockroachdb app +type CockroachDB struct { + IntegrationSuite +} + +var _ = Suite(&CockroachDB{ + IntegrationSuite{ + name: "cockroachdb", + namespace: "cockroachdb-test", + app: app.NewCockroachDB("cockroachdb"), + bp: app.NewBlueprint("cockroachdb", "", false), + profile: newSecretProfile(), + }, +}) + // time-log app for csi volumesnapshot type TimeLogCSI struct { IntegrationSuite From a72c089e9650be62d9b4357a644bd53ce7b423dd Mon Sep 17 00:00:00 2001 From: Ivan Sim <1330522+ihcsim@users.noreply.github.com> Date: Wed, 7 Sep 2022 15:23:43 -0700 Subject: [PATCH 12/15] Add new flag to override actionset name (#1625) Signed-off-by: Ivan Sim Signed-off-by: Ivan Sim --- pkg/kanctl/actionset.go | 89 +++++++++++++++++++++++++----------- pkg/kanctl/actionset_test.go | 29 ++++++++++++ 2 files changed, 91 insertions(+), 27 deletions(-) diff --git a/pkg/kanctl/actionset.go b/pkg/kanctl/actionset.go index 8c8e52f072..bb9d410ed0 100644 --- a/pkg/kanctl/actionset.go +++ b/pkg/kanctl/actionset.go @@ -38,6 +38,7 @@ import ( const ( actionFlagName = "action" + actionSetFlagName = "action-set" blueprintFlagName = "blueprint" configMapsFlagName = "config-maps" deploymentFlagName = "deployment" @@ -55,17 +56,22 @@ const ( objectsFlagName = "objects" ) +var ( + errMissingFieldActionName = fmt.Errorf("missing action name. use the --action flag to specify the action name") +) + type PerformParams struct { - Namespace string - ActionName string - ParentName string - Blueprint string - DryRun bool - Objects []crv1alpha1.ObjectReference - Options map[string]string - Profile *crv1alpha1.ObjectReference - Secrets map[string]crv1alpha1.ObjectReference - ConfigMaps map[string]crv1alpha1.ObjectReference + Namespace string + ActionName string + ActionSetName string + ParentName string + Blueprint string + DryRun bool + Objects []crv1alpha1.ObjectReference + Options map[string]string + Profile *crv1alpha1.ObjectReference + Secrets map[string]crv1alpha1.ObjectReference + ConfigMaps map[string]crv1alpha1.ObjectReference } func newActionSetCmd() *cobra.Command { @@ -80,6 +86,7 @@ func newActionSetCmd() *cobra.Command { cmd.Flags().StringP(sourceFlagName, "f", "", "specify name of the action set") cmd.Flags().StringP(actionFlagName, "a", "", "action for the action set (required if creating a new action set)") + cmd.Flags().StringP(actionSetFlagName, "A", "", "name of the new actionset (optional. if not specified, kanctl will generate one based on the action name") cmd.Flags().StringP(blueprintFlagName, "b", "", "blueprint for the action set (required if creating a new action set)") cmd.Flags().StringSliceP(configMapsFlagName, "c", []string{}, "config maps for the action set, comma separated ref=namespace/name pairs (eg: --config-maps ref1=namespace1/name1,ref2=namespace2/name2)") cmd.Flags().StringSliceP(deploymentFlagName, "d", []string{}, "deployment for the action set, comma separated namespace/name pairs (eg: --deployment namespace1/name1,namespace2/name2)") @@ -162,7 +169,12 @@ func newActionSet(params *PerformParams) (*crv1alpha1.ActionSet, error) { Options: params.Options, }) } - name := fmt.Sprintf("%s-", params.ActionName) + + name, err := generateActionSetName(params) + if err != nil { + return nil, err + } + return &crv1alpha1.ActionSet{ ObjectMeta: metav1.ObjectMeta{ GenerateName: name, @@ -217,14 +229,15 @@ func ChildActionSet(parent *crv1alpha1.ActionSet, params *PerformParams) (*crv1a actions = append(actions, as) } } + + name, err := generateActionSetName(params) + if err != nil { + return nil, err + } + return &crv1alpha1.ActionSet{ ObjectMeta: metav1.ObjectMeta{ - GenerateName: func() string { - if params.ActionName != "" { - return fmt.Sprintf("%s-%s-", params.ActionName, parent.GetName()) - } - return fmt.Sprintf("%s-", parent.GetName()) - }(), + GenerateName: name, }, Spec: &crv1alpha1.ActionSetSpec{ Actions: actions, @@ -262,6 +275,7 @@ func extractPerformParams(cmd *cobra.Command, args []string, cli kubernetes.Inte return nil, err } actionName, _ := cmd.Flags().GetString(actionFlagName) + actionSetName, _ := cmd.Flags().GetString(actionSetFlagName) parentName, _ := cmd.Flags().GetString(sourceFlagName) blueprint, _ := cmd.Flags().GetString(blueprintFlagName) dryRun, _ := cmd.Flags().GetBool(dryRunFlag) @@ -286,16 +300,17 @@ func extractPerformParams(cmd *cobra.Command, args []string, cli kubernetes.Inte return nil, err } return &PerformParams{ - Namespace: ns, - ActionName: actionName, - ParentName: parentName, - Blueprint: blueprint, - DryRun: dryRun, - Objects: objects, - Options: options, - Secrets: secrets, - ConfigMaps: cms, - Profile: profile, + Namespace: ns, + ActionName: actionName, + ActionSetName: actionSetName, + ParentName: parentName, + Blueprint: blueprint, + DryRun: dryRun, + Objects: objects, + Options: options, + Secrets: secrets, + ConfigMaps: cms, + Profile: profile, }, nil } @@ -692,3 +707,23 @@ func max(x, y int) int { } return y } + +func generateActionSetName(p *PerformParams) (string, error) { + if p.ActionSetName != "" { + return fmt.Sprintf("%s-", p.ActionSetName), nil + } + + if p.ActionName != "" { + if p.ParentName != "" { + return fmt.Sprintf("%s-%s-", p.ActionName, p.ParentName), nil + } + + return fmt.Sprintf("%s-", p.ActionName), nil + } + + if p.ParentName != "" { + return fmt.Sprintf("%s-", p.ParentName), nil + } + + return "", errMissingFieldActionName +} diff --git a/pkg/kanctl/actionset_test.go b/pkg/kanctl/actionset_test.go index d6123049a1..12557d9d49 100644 --- a/pkg/kanctl/actionset_test.go +++ b/pkg/kanctl/actionset_test.go @@ -76,3 +76,32 @@ func (k *KanctlTestSuite) TestParseGenericObjectReference(c *C) { c.Assert(a, DeepEquals, tc.expected) } } + +func (k *KanctlTestSuite) TestGenerateActionSetName(c *C) { + var testCases = []struct { + actionName string + actionSetName string + parentName string + expected string + expectedErr error + }{ + {actionName: "", actionSetName: "", parentName: "", expected: "", expectedErr: errMissingFieldActionName}, + {actionName: "my-action", actionSetName: "", parentName: "", expected: "my-action-"}, + {actionName: "my-action", actionSetName: "", parentName: "parent", expected: "my-action-parent-"}, + {actionName: "", actionSetName: "", parentName: "parent", expected: "parent-"}, + {actionName: "my-action", actionSetName: "my-override", parentName: "parent", expected: "my-override-"}, + {actionName: "", actionSetName: "my-override", parentName: "", expected: "my-override-"}, + } + + for _, tc := range testCases { + params := &PerformParams{ + ActionName: tc.actionName, + ActionSetName: tc.actionSetName, + ParentName: tc.parentName, + } + + actual, err := generateActionSetName(params) + c.Assert(err, DeepEquals, tc.expectedErr) + c.Assert(actual, DeepEquals, tc.expected) + } +} From 362c03478ec983fa0731c544adbc3075814e3b94 Mon Sep 17 00:00:00 2001 From: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> Date: Wed, 7 Sep 2022 17:24:44 -0700 Subject: [PATCH 13/15] Remove CockroachDB test (#1628) --- build/integration-test.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/integration-test.sh b/build/integration-test.sh index 72b367f471..e717318d83 100755 --- a/build/integration-test.sh +++ b/build/integration-test.sh @@ -25,7 +25,7 @@ TEST_TIMEOUT="30m" # Set default options TEST_OPTIONS="-tags=integration -timeout ${TEST_TIMEOUT} -check.suitep ${DOP}" # Regex to match apps to run in short mode -SHORT_APPS="^PostgreSQL$|^MySQL$|Elasticsearch|^MongoDB$|Maria|^MSSQL$|^CockroachDB$" +SHORT_APPS="^PostgreSQL$|^MySQL$|Elasticsearch|^MongoDB$|Maria|^MSSQL$" # OCAPPS has all the apps that are to be tested against openshift cluster OC_APPS3_11="MysqlDBDepConfig$|MongoDBDepConfig$|PostgreSQLDepConfig$" OC_APPS4_4="MysqlDBDepConfig4_4|MongoDBDepConfig4_4|PostgreSQLDepConfig4_4" From 4a0614a81704029f831a2870bb5c56716ace7ab6 Mon Sep 17 00:00:00 2001 From: Infra Bot <63741182+infraq@users.noreply.github.com> Date: Wed, 7 Sep 2022 17:59:49 -0700 Subject: [PATCH 14/15] Kanister docs update to version 0.82.0 (#1626) Co-authored-by: Kasten Production Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> --- examples/aws-rds/postgresql/README.md | 2 +- .../postgresql/rds-postgres-blueprint.yaml | 6 +++--- .../postgresql/rds-postgres-dump-blueprint.yaml | 2 +- examples/cassandra/README.md | 4 ++-- examples/cassandra/cassandra-blueprint.yaml | 2 +- examples/cockroachdb/cockroachdb-blueprint.yaml | 2 +- .../blueprint-v2/couchbase-blueprint.yaml | 6 +++--- examples/couchbase/couchbase-blueprint.yaml | 6 +++--- examples/csi-snapshot/README.md | 2 +- examples/elasticsearch/README.md | 2 +- .../blueprint-v2/elasticsearch-blueprint.yaml | 4 ++-- .../elasticsearch/elasticsearch-blueprint.yaml | 6 +++--- .../k8s/etcd-incluster-blueprint.yaml | 8 ++++---- .../etcd-incluster-ocp-blueprint.yaml | 10 +++++----- .../ocp/etcd-incluster-ocp-blueprint.yaml | 8 ++++---- examples/foundationdb/README.md | 2 +- .../blueprint-v2/foundationdb-blueprint.yaml | 2 +- examples/k8ssandra/README.md | 2 +- examples/kafka/adobe-s3-connector/README.md | 2 +- examples/maria/blueprint-v2/maria-blueprint.yaml | 6 +++--- examples/maria/maria-blueprint.yaml | 6 +++--- examples/mongodb-deploymentconfig/README.md | 2 +- .../blueprint-v2/mongo-dep-config-blueprint.yaml | 6 +++--- .../mongo-dep-config-blueprint.yaml | 6 +++--- examples/mongodb-restic/README.md | 4 ++-- examples/mongodb-restic/mongodb-blueprint.yaml | 2 +- examples/mongodb/README.md | 2 +- .../mongodb/blueprint-v2/mongo-blueprint.yaml | 6 +++--- examples/mongodb/mongo-blueprint.yaml | 6 +++--- examples/mssql/README.md | 2 +- examples/mssql/blueprint-v2/mssql-blueprint.yaml | 6 +++--- examples/mssql/mssql-blueprint.yaml | 6 +++--- examples/mysql-deploymentconfig/README.md | 2 +- .../blueprint-v2/mysql-dep-config-blueprint.yaml | 6 +++--- .../mysql-dep-config-blueprint.yaml | 6 +++--- examples/mysql/README.md | 2 +- examples/mysql/blueprint-v2/mysql-blueprint.yaml | 6 +++--- examples/mysql/mysql-blueprint.yaml | 6 +++--- examples/postgresql-deploymentconfig/README.md | 2 +- .../postgres-dep-config-blueprint.yaml | 6 +++--- .../postgres-dep-config-blueprint.yaml | 6 +++--- examples/postgresql-ha/hook-blueprint/README.md | 2 +- examples/postgresql-wale/README.md | 6 +++--- .../postgresql-wale/postgresql-blueprint.yaml | 4 ++-- examples/postgresql/README.md | 4 ++-- .../blueprint-v2/postgres-blueprint.yaml | 6 +++--- examples/postgresql/postgres-blueprint.yaml | 6 +++--- .../postgresql/v10.16.2/postgres-blueprint.yaml | 6 +++--- examples/time-log/blueprint.yaml | 2 +- examples/time-log/time-logger-deployment.yaml | 2 +- helm/kanister-operator/Chart.yaml | 2 +- helm/kanister-operator/values.yaml | 2 +- helm/profile/Chart.yaml | 2 +- pkg/app/csi-snapshot.go | 2 +- pkg/function/data_test.go | 6 +++--- pkg/function/export_rds_snapshot_location.go | 2 +- pkg/function/kube_exec_test.go | 10 +++++----- pkg/function/kube_task_test.go | 4 ++-- pkg/function/utils.go | 2 +- pkg/kube/pod_test.go | 16 ++++++++-------- pkg/testing/e2e_test.go | 2 +- scripts/get.sh | 2 +- 62 files changed, 135 insertions(+), 135 deletions(-) diff --git a/examples/aws-rds/postgresql/README.md b/examples/aws-rds/postgresql/README.md index ded6c67be0..1236288bab 100755 --- a/examples/aws-rds/postgresql/README.md +++ b/examples/aws-rds/postgresql/README.md @@ -9,7 +9,7 @@ This example is to demonstrate how Kanister can be integrated with AWS RDS insta ## Prerequisites - Kubernetes 1.10+ -- Kanister controller version 0.81.0 installed in your cluster +- Kanister controller version 0.82.0 installed in your cluster - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Create RDS instance on AWS diff --git a/examples/aws-rds/postgresql/rds-postgres-blueprint.yaml b/examples/aws-rds/postgresql/rds-postgres-blueprint.yaml index 4fc7e5ae31..9f31cc001a 100644 --- a/examples/aws-rds/postgresql/rds-postgres-blueprint.yaml +++ b/examples/aws-rds/postgresql/rds-postgres-blueprint.yaml @@ -13,7 +13,7 @@ actions: - func: KubeTask name: backupSnapshots args: - image: "ghcr.io/kanisterio/postgres-kanister-tools:0.81.0" + image: "ghcr.io/kanisterio/postgres-kanister-tools:0.82.0" namespace: "{{ .Object.metadata.namespace }}" command: - bash @@ -49,7 +49,7 @@ actions: - func: KubeTask name: restoreSnapshots args: - image: "ghcr.io/kanisterio/postgres-kanister-tools:0.81.0" + image: "ghcr.io/kanisterio/postgres-kanister-tools:0.82.0" namespace: "{{ .Object.metadata.namespace }}" command: - bash @@ -86,7 +86,7 @@ actions: - func: KubeTask name: restoreSnapshots args: - image: "ghcr.io/kanisterio/postgres-kanister-tools:0.81.0" + image: "ghcr.io/kanisterio/postgres-kanister-tools:0.82.0" namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/aws-rds/postgresql/rds-postgres-dump-blueprint.yaml b/examples/aws-rds/postgresql/rds-postgres-dump-blueprint.yaml index bd9ad3411a..3cc8ce019a 100644 --- a/examples/aws-rds/postgresql/rds-postgres-dump-blueprint.yaml +++ b/examples/aws-rds/postgresql/rds-postgres-dump-blueprint.yaml @@ -64,7 +64,7 @@ actions: name: deleteBackup args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 command: - bash - -o diff --git a/examples/cassandra/README.md b/examples/cassandra/README.md index 52464d17d3..0bba354331 100644 --- a/examples/cassandra/README.md +++ b/examples/cassandra/README.md @@ -7,7 +7,7 @@ As the official documentation of [Cassandra](http://cassandra.apache.org/) says, * Kubernetes 1.9+ * Kubernetes beta APIs enabled only if `podDisruptionBudget` is enabled * PV support on the underlying infrastructure -* Kanister controller version 0.81.0 installed in your cluster, let's say in namespace `` +* Kanister controller version 0.82.0 installed in your cluster, let's say in namespace `` * Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) To install kanister and related tools you can follow [this](https://docs.kanister.io/install.html#install) link. @@ -29,7 +29,7 @@ $ helm repo add bitnami https://charts.bitnami.com/bitnami $ helm repo update # remove app-namespace with the namespace you want to deploy the Cassandra app in $ kubectl create ns -$ helm install cassandra bitnami/cassandra --namespace --set image.repository=kanisterio/cassandra --set image.tag=0.81.0 --set cluster.replicaCount=2 --set image.registry=ghcr.io --set image.pullPolicy=Always +$ helm install cassandra bitnami/cassandra --namespace --set image.repository=kanisterio/cassandra --set image.tag=0.82.0 --set cluster.replicaCount=2 --set image.registry=ghcr.io --set image.pullPolicy=Always ``` diff --git a/examples/cassandra/cassandra-blueprint.yaml b/examples/cassandra/cassandra-blueprint.yaml index a082fbec2a..6d050e37aa 100644 --- a/examples/cassandra/cassandra-blueprint.yaml +++ b/examples/cassandra/cassandra-blueprint.yaml @@ -102,7 +102,7 @@ actions: name: restoreFromObjectStore args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 backupArtifactPrefix: "{{ .ArtifactsIn.params.KeyValue.backupPrefixLocation }}" pods: "{{ range .StatefulSet.Pods }} {{.}}{{end}}" restorePath: "{{ .ArtifactsIn.params.KeyValue.restorePathPrefix }}" diff --git a/examples/cockroachdb/cockroachdb-blueprint.yaml b/examples/cockroachdb/cockroachdb-blueprint.yaml index 16d8884b00..8f938613d4 100644 --- a/examples/cockroachdb/cockroachdb-blueprint.yaml +++ b/examples/cockroachdb/cockroachdb-blueprint.yaml @@ -151,7 +151,7 @@ actions: - func: KubeTask name: deleteFromS3Store args: - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/couchbase/blueprint-v2/couchbase-blueprint.yaml b/examples/couchbase/blueprint-v2/couchbase-blueprint.yaml index 6e61547f91..d9968f132a 100644 --- a/examples/couchbase/blueprint-v2/couchbase-blueprint.yaml +++ b/examples/couchbase/blueprint-v2/couchbase-blueprint.yaml @@ -21,7 +21,7 @@ actions: namespace: "{{ .Object.metadata.namespace }}" args: namespace: "{{ .Object.metadata.namespace }}" - image: ghcr.io/kanisterio/couchbase-tools:0.81.0 + image: ghcr.io/kanisterio/couchbase-tools:0.82.0 command: - bash - -o @@ -58,7 +58,7 @@ actions: namespace: "{{ .Object.metadata.namespace }}" args: namespace: "{{ .Object.metadata.namespace }}" - image: ghcr.io/kanisterio/couchbase-tools:0.81.0 + image: ghcr.io/kanisterio/couchbase-tools:0.82.0 command: - bash - -o @@ -89,7 +89,7 @@ actions: name: deleteBackup args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/couchbase-tools:0.81.0 + image: ghcr.io/kanisterio/couchbase-tools:0.82.0 command: - bash - -o diff --git a/examples/couchbase/couchbase-blueprint.yaml b/examples/couchbase/couchbase-blueprint.yaml index 08c434f65d..b1567c42af 100644 --- a/examples/couchbase/couchbase-blueprint.yaml +++ b/examples/couchbase/couchbase-blueprint.yaml @@ -19,7 +19,7 @@ actions: namespace: "{{ .Object.metadata.namespace }}" args: namespace: "{{ .Object.metadata.namespace }}" - image: ghcr.io/kanisterio/couchbase-tools:0.81.0 + image: ghcr.io/kanisterio/couchbase-tools:0.82.0 command: - bash - -o @@ -53,7 +53,7 @@ actions: namespace: "{{ .Object.metadata.namespace }}" args: namespace: "{{ .Object.metadata.namespace }}" - image: ghcr.io/kanisterio/couchbase-tools:0.81.0 + image: ghcr.io/kanisterio/couchbase-tools:0.82.0 command: - bash - -o @@ -79,7 +79,7 @@ actions: name: deleteBackup args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 command: - bash - -o diff --git a/examples/csi-snapshot/README.md b/examples/csi-snapshot/README.md index d74fa39b92..1d036f43fe 100644 --- a/examples/csi-snapshot/README.md +++ b/examples/csi-snapshot/README.md @@ -8,7 +8,7 @@ This example demonstrates Kanister's ability to protect an application called Ti - Helm 3 installed - Kubernetes 1.16+ with Beta APIs enabled -- Kanister controller version 0.81.0 installed in the cluster, let's assume in namespace `kanister` +- Kanister controller version 0.82.0 installed in the cluster, let's assume in namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) - VolumeSnapshot CRDs, Snapshot Controller & a CSI Driver diff --git a/examples/elasticsearch/README.md b/examples/elasticsearch/README.md index 88692de526..a081358cb3 100644 --- a/examples/elasticsearch/README.md +++ b/examples/elasticsearch/README.md @@ -13,7 +13,7 @@ If you want to avoid doing that upgrade to Elasticsearch 5.6 first before moving * Kubernetes 1.9+ with Beta APIs enabled. * PV support on the underlying infrastructure. -* Kanister version 0.81.0 with `profiles.cr.kanister.io` CRD installed +* Kanister version 0.82.0 with `profiles.cr.kanister.io` CRD installed ## StatefulSets Details * https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/ diff --git a/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml b/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml index 58f7466fdc..56c80ff89e 100644 --- a/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml +++ b/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml @@ -15,7 +15,7 @@ actions: name: backupToStore args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.81.0" + image: "ghcr.io/kanisterio/es-sidecar:0.82.0" command: - bash - -o @@ -39,7 +39,7 @@ actions: name: restoreFromStore args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.81.0" + image: "ghcr.io/kanisterio/es-sidecar:0.82.0" command: - bash - -o diff --git a/examples/elasticsearch/elasticsearch-blueprint.yaml b/examples/elasticsearch/elasticsearch-blueprint.yaml index 445eec245a..327904f692 100644 --- a/examples/elasticsearch/elasticsearch-blueprint.yaml +++ b/examples/elasticsearch/elasticsearch-blueprint.yaml @@ -13,7 +13,7 @@ actions: name: backupToObjectStore args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.81.0" + image: "ghcr.io/kanisterio/es-sidecar:0.82.0" command: - bash - -o @@ -36,7 +36,7 @@ actions: name: restoreFromObjectStore args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.81.0" + image: "ghcr.io/kanisterio/es-sidecar:0.82.0" command: - bash - -o @@ -55,7 +55,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/es-sidecar:0.81.0" + image: "ghcr.io/kanisterio/es-sidecar:0.82.0" command: - bash - -o diff --git a/examples/etcd/etcd-in-cluster/k8s/etcd-incluster-blueprint.yaml b/examples/etcd/etcd-in-cluster/k8s/etcd-incluster-blueprint.yaml index abbe23d636..afa1422d16 100644 --- a/examples/etcd/etcd-in-cluster/k8s/etcd-incluster-blueprint.yaml +++ b/examples/etcd/etcd-in-cluster/k8s/etcd-incluster-blueprint.yaml @@ -12,7 +12,7 @@ actions: - func: KubeTask name: takeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -37,7 +37,7 @@ actions: - func: KubeTask name: uploadSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -55,7 +55,7 @@ actions: - func: KubeTask name: removeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -74,7 +74,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/kanister-tools:0.81.0" + image: "ghcr.io/kanisterio/kanister-tools:0.82.0" command: - bash - -o diff --git a/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml index 09caff0289..6e582c303e 100644 --- a/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml +++ b/examples/etcd/etcd-in-cluster/ocp/blueprint-v2/etcd-incluster-ocp-blueprint.yaml @@ -11,7 +11,7 @@ actions: - func: KubeTask name: takeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -34,7 +34,7 @@ actions: - func: KubeTask name: uploadSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -50,7 +50,7 @@ actions: - func: KubeTask name: removeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -73,7 +73,7 @@ actions: - func: PrepareData name: copyFromObjectStore args: - image: "ghcr.io/kanisterio/kanister-tools:0.81.0" + image: "ghcr.io/kanisterio/kanister-tools:0.82.0" namespace: "{{ .Object.metadata.namespace }}" podOverride: nodeSelector: @@ -108,7 +108,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Object.metadata.namespace }}" - image: "ghcr.io/kanisterio/kanister-tools:0.81.0" + image: "ghcr.io/kanisterio/kanister-tools:0.82.0" command: - bash - -o diff --git a/examples/etcd/etcd-in-cluster/ocp/etcd-incluster-ocp-blueprint.yaml b/examples/etcd/etcd-in-cluster/ocp/etcd-incluster-ocp-blueprint.yaml index 998f4bfd9d..f33481dae6 100644 --- a/examples/etcd/etcd-in-cluster/ocp/etcd-incluster-ocp-blueprint.yaml +++ b/examples/etcd/etcd-in-cluster/ocp/etcd-incluster-ocp-blueprint.yaml @@ -12,7 +12,7 @@ actions: - func: KubeTask name: takeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -35,7 +35,7 @@ actions: - func: KubeTask name: uploadSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -53,7 +53,7 @@ actions: - func: KubeTask name: removeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.81.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.82.0 command: - sh - -o @@ -72,7 +72,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/kanister-tools:0.81.0" + image: "ghcr.io/kanisterio/kanister-tools:0.82.0" command: - bash - -o diff --git a/examples/foundationdb/README.md b/examples/foundationdb/README.md index 2801f0c2b1..33445f4dc9 100644 --- a/examples/foundationdb/README.md +++ b/examples/foundationdb/README.md @@ -24,7 +24,7 @@ cluster. on you cluster. * Kubernetes 1.9+ with Beta APIs enabled. * PV support on the underlying infrastructure. -* Kanister version 0.81.0 with `profiles.cr.kanister.io` CRD installed. +* Kanister version 0.82.0 with `profiles.cr.kanister.io` CRD installed. # Installation diff --git a/examples/foundationdb/blueprint-v2/foundationdb-blueprint.yaml b/examples/foundationdb/blueprint-v2/foundationdb-blueprint.yaml index 278bea60eb..68d95c39e5 100644 --- a/examples/foundationdb/blueprint-v2/foundationdb-blueprint.yaml +++ b/examples/foundationdb/blueprint-v2/foundationdb-blueprint.yaml @@ -77,7 +77,7 @@ actions: name: deleteBackup args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 command: - bash - -o diff --git a/examples/k8ssandra/README.md b/examples/k8ssandra/README.md index 5e92927f9b..0b52eba22d 100644 --- a/examples/k8ssandra/README.md +++ b/examples/k8ssandra/README.md @@ -8,7 +8,7 @@ K8ssandra operator uses Medusa to backup and restore Cassandra data. Kanister ca * Kubernetes 1.17+ * PV support on the underlying infrastructure -* Kanister controller version 0.81.0 installed in your cluster +* Kanister controller version 0.82.0 installed in your cluster * Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) * K8ssandra needs at least 4 cores and 8GB of RAM available to Docker and appropriate heap sizes for Cassandra and Stargate. If you don’t have those resources available, you can avoid deploying features such as monitoring, Reaper and Medusa, and also reduce the number of Cassandra nodes. diff --git a/examples/kafka/adobe-s3-connector/README.md b/examples/kafka/adobe-s3-connector/README.md index 0526ed2344..daa16d55c1 100644 --- a/examples/kafka/adobe-s3-connector/README.md +++ b/examples/kafka/adobe-s3-connector/README.md @@ -6,7 +6,7 @@ During restore, topic messages are purged before the restore operation is perfor ## Prerequisites * Kubernetes 1.9+ -* Kanister controller version 0.81.0 installed in the cluster in a namespace . This example uses `kanister` namespace +* Kanister controller version 0.82.0 installed in the cluster in a namespace . This example uses `kanister` namespace * Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Assumption diff --git a/examples/maria/blueprint-v2/maria-blueprint.yaml b/examples/maria/blueprint-v2/maria-blueprint.yaml index 55581fca28..ad24c0e5af 100644 --- a/examples/maria/blueprint-v2/maria-blueprint.yaml +++ b/examples/maria/blueprint-v2/maria-blueprint.yaml @@ -19,7 +19,7 @@ actions: name: '{{ .StatefulSet.Name }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -53,7 +53,7 @@ actions: name: '{{ .StatefulSet.Name }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -76,7 +76,7 @@ actions: - func: KubeTask name: deleteFromStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/maria/maria-blueprint.yaml b/examples/maria/maria-blueprint.yaml index 37f8db3774..32c5b80871 100644 --- a/examples/maria/maria-blueprint.yaml +++ b/examples/maria/maria-blueprint.yaml @@ -17,7 +17,7 @@ actions: name: '{{ .StatefulSet.Name }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -49,7 +49,7 @@ actions: name: '{{ .StatefulSet.Name }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/mongodb-deploymentconfig/README.md b/examples/mongodb-deploymentconfig/README.md index e1b46bbe5c..9a490b20e7 100644 --- a/examples/mongodb-deploymentconfig/README.md +++ b/examples/mongodb-deploymentconfig/README.md @@ -14,7 +14,7 @@ cluster's DeploymentConfig resources. - Setup OpenShift, you can follow steps mentioned below - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster in namespace `kanister` +- Kanister controller version 0.82.0 installed in your cluster in namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) **Note** diff --git a/examples/mongodb-deploymentconfig/blueprint-v2/mongo-dep-config-blueprint.yaml b/examples/mongodb-deploymentconfig/blueprint-v2/mongo-dep-config-blueprint.yaml index 1382baca47..5eb8a252c9 100644 --- a/examples/mongodb-deploymentconfig/blueprint-v2/mongo-dep-config-blueprint.yaml +++ b/examples/mongodb-deploymentconfig/blueprint-v2/mongo-dep-config-blueprint.yaml @@ -20,7 +20,7 @@ actions: namespace: "{{ .DeploymentConfig.Namespace }}" args: namespace: "{{ .DeploymentConfig.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -50,7 +50,7 @@ actions: namespace: "{{ .DeploymentConfig.Namespace }}" args: namespace: "{{ .DeploymentConfig.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -75,7 +75,7 @@ actions: name: deleteFromStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o diff --git a/examples/mongodb-deploymentconfig/mongo-dep-config-blueprint.yaml b/examples/mongodb-deploymentconfig/mongo-dep-config-blueprint.yaml index 61b9398fd8..3e62d1d01b 100644 --- a/examples/mongodb-deploymentconfig/mongo-dep-config-blueprint.yaml +++ b/examples/mongodb-deploymentconfig/mongo-dep-config-blueprint.yaml @@ -18,7 +18,7 @@ actions: namespace: "{{ .DeploymentConfig.Namespace }}" args: namespace: "{{ .DeploymentConfig.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -45,7 +45,7 @@ actions: namespace: "{{ .DeploymentConfig.Namespace }}" args: namespace: "{{ .DeploymentConfig.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -66,7 +66,7 @@ actions: name: deleteFromBlobStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o diff --git a/examples/mongodb-restic/README.md b/examples/mongodb-restic/README.md index 26f1049401..870801269c 100644 --- a/examples/mongodb-restic/README.md +++ b/examples/mongodb-restic/README.md @@ -7,7 +7,7 @@ * Kubernetes 1.9+ * Kubernetes beta APIs enabled only if `podDisruptionBudget` is enabled * PV support on the underlying infrastructure -* Kanister controller version 0.81.0 installed in your cluster +* Kanister controller version 0.82.0 installed in your cluster * Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Chart Details @@ -28,7 +28,7 @@ $ kubectl create namespace mongo-test $ helm install my-release bitnami/mongodb --namespace mongo-test \ --set architecture="replicaset" \ --set image.repository=ghcr.io/kanisterio/mongodb \ - --set image.tag=0.81.0 + --set image.tag=0.82.0 ``` The command deploys MongoDB on the Kubernetes cluster in the mongo-test namespace diff --git a/examples/mongodb-restic/mongodb-blueprint.yaml b/examples/mongodb-restic/mongodb-blueprint.yaml index 98daea7a42..04a45108f8 100644 --- a/examples/mongodb-restic/mongodb-blueprint.yaml +++ b/examples/mongodb-restic/mongodb-blueprint.yaml @@ -39,7 +39,7 @@ actions: name: restorePrimary args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 backupArtifactPrefix: "{{ .Profile.Location.Bucket }}/mongodb-backups/{{ .StatefulSet.Name }}/rs_backup" backupInfo: "{{ .ArtifactsIn.backupInfo.KeyValue.backupIdentifier }}" diff --git a/examples/mongodb/README.md b/examples/mongodb/README.md index bfc70fa12e..4fbf076c8f 100644 --- a/examples/mongodb/README.md +++ b/examples/mongodb/README.md @@ -7,7 +7,7 @@ * Kubernetes 1.9+ * Kubernetes beta APIs enabled only if `podDisruptionBudget` is enabled * PV support on the underlying infrastructure -* Kanister controller version 0.81.0 installed in your cluster +* Kanister controller version 0.82.0 installed in your cluster * Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Chart Details diff --git a/examples/mongodb/blueprint-v2/mongo-blueprint.yaml b/examples/mongodb/blueprint-v2/mongo-blueprint.yaml index b4432a1547..1ab310e769 100644 --- a/examples/mongodb/blueprint-v2/mongo-blueprint.yaml +++ b/examples/mongodb/blueprint-v2/mongo-blueprint.yaml @@ -20,7 +20,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -49,7 +49,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -74,7 +74,7 @@ actions: name: deleteFromStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o diff --git a/examples/mongodb/mongo-blueprint.yaml b/examples/mongodb/mongo-blueprint.yaml index b72434f26b..2a39681325 100644 --- a/examples/mongodb/mongo-blueprint.yaml +++ b/examples/mongodb/mongo-blueprint.yaml @@ -18,7 +18,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -44,7 +44,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o @@ -65,7 +65,7 @@ actions: name: deleteFromBlobStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.81.0 + image: ghcr.io/kanisterio/mongodb:0.82.0 command: - bash - -o diff --git a/examples/mssql/README.md b/examples/mssql/README.md index 3d1abed0f6..ec6e101a06 100644 --- a/examples/mssql/README.md +++ b/examples/mssql/README.md @@ -9,7 +9,7 @@ This document will cover how to install SQL Server and how to run backup/restore - Kubernetes 1.16+ with Beta APIs enabled - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster, let's assume in Namespace `kanister` +- Kanister controller version 0.82.0 installed in your cluster, let's assume in Namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) ## Installing Microsoft SQL Server diff --git a/examples/mssql/blueprint-v2/mssql-blueprint.yaml b/examples/mssql/blueprint-v2/mssql-blueprint.yaml index ab6698cc22..5d99912edf 100644 --- a/examples/mssql/blueprint-v2/mssql-blueprint.yaml +++ b/examples/mssql/blueprint-v2/mssql-blueprint.yaml @@ -16,7 +16,7 @@ actions: name: '{{ index .Object.metadata.labels "app" }}' namespace: '{{ .Deployment.Namespace }}' args: - image: ghcr.io/kanisterio/mssql-tools:0.81.0 + image: ghcr.io/kanisterio/mssql-tools:0.82.0 command: - bash - -o @@ -47,7 +47,7 @@ actions: name: '{{ index .Object.metadata.labels "app" }}' namespace: '{{ .Deployment.Namespace }}' args: - image: ghcr.io/kanisterio/mssql-tools:0.81.0 + image: ghcr.io/kanisterio/mssql-tools:0.82.0 command: - bash - -o @@ -74,7 +74,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mssql-tools:0.81.0 + image: ghcr.io/kanisterio/mssql-tools:0.82.0 command: - bash - -o diff --git a/examples/mssql/mssql-blueprint.yaml b/examples/mssql/mssql-blueprint.yaml index bc690df2e7..8647f44ee8 100644 --- a/examples/mssql/mssql-blueprint.yaml +++ b/examples/mssql/mssql-blueprint.yaml @@ -14,7 +14,7 @@ actions: - func: KubeTask name: dumpToObjectStore args: - image: ghcr.io/kanisterio/mssql-tools:0.81.0 + image: ghcr.io/kanisterio/mssql-tools:0.82.0 command: - bash - -o @@ -45,7 +45,7 @@ actions: - func: KubeTask name: restoreFromObjectStore args: - image: ghcr.io/kanisterio/mssql-tools:0.81.0 + image: ghcr.io/kanisterio/mssql-tools:0.82.0 command: - bash - -o @@ -71,7 +71,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mssql-tools:0.81.0 + image: ghcr.io/kanisterio/mssql-tools:0.82.0 command: - bash - -o diff --git a/examples/mysql-deploymentconfig/README.md b/examples/mysql-deploymentconfig/README.md index 20ded85b9b..84307d391e 100644 --- a/examples/mysql-deploymentconfig/README.md +++ b/examples/mysql-deploymentconfig/README.md @@ -14,7 +14,7 @@ cluster's DeploymentConfig resources. - Setup OpenShift, you can follow steps mentioned below - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster in namespace `kanister` +- Kanister controller version 0.82.0 installed in your cluster in namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) **Note** diff --git a/examples/mysql-deploymentconfig/blueprint-v2/mysql-dep-config-blueprint.yaml b/examples/mysql-deploymentconfig/blueprint-v2/mysql-dep-config-blueprint.yaml index 0d5eefb28b..7ccb34f983 100644 --- a/examples/mysql-deploymentconfig/blueprint-v2/mysql-dep-config-blueprint.yaml +++ b/examples/mysql-deploymentconfig/blueprint-v2/mysql-dep-config-blueprint.yaml @@ -19,7 +19,7 @@ actions: name: "{{ .DeploymentConfig.Name }}" namespace: "{{ .DeploymentConfig.Namespace }}" args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .DeploymentConfig.Namespace }}" command: - bash @@ -47,7 +47,7 @@ actions: name: "{{ .DeploymentConfig.Name }}" namespace: "{{ .DeploymentConfig.Namespace }}" args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .DeploymentConfig.Namespace }}" command: - bash @@ -71,7 +71,7 @@ actions: - func: KubeTask name: deleteFromStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/mysql-deploymentconfig/mysql-dep-config-blueprint.yaml b/examples/mysql-deploymentconfig/mysql-dep-config-blueprint.yaml index 6405c90191..558bca8dde 100644 --- a/examples/mysql-deploymentconfig/mysql-dep-config-blueprint.yaml +++ b/examples/mysql-deploymentconfig/mysql-dep-config-blueprint.yaml @@ -17,7 +17,7 @@ actions: name: "{{ .DeploymentConfig.Name }}" namespace: "{{ .DeploymentConfig.Namespace }}" args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .DeploymentConfig.Namespace }}" command: - bash @@ -43,7 +43,7 @@ actions: name: "{{ .DeploymentConfig.Name }}" namespace: "{{ .DeploymentConfig.Namespace }}" args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .DeploymentConfig.Namespace }}" command: - bash @@ -63,7 +63,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/mysql/README.md b/examples/mysql/README.md index 53874c9f15..5c7299ab02 100755 --- a/examples/mysql/README.md +++ b/examples/mysql/README.md @@ -10,7 +10,7 @@ This chart bootstraps a single node MySQL deployment on a [Kubernetes](http://ku - Kubernetes 1.16+ with Beta APIs enabled - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster, let's assume in Namespace `kanister` +- Kanister controller version 0.82.0 installed in your cluster, let's assume in Namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) ## Installing the Chart diff --git a/examples/mysql/blueprint-v2/mysql-blueprint.yaml b/examples/mysql/blueprint-v2/mysql-blueprint.yaml index 6d35dae642..58d35a0f52 100644 --- a/examples/mysql/blueprint-v2/mysql-blueprint.yaml +++ b/examples/mysql/blueprint-v2/mysql-blueprint.yaml @@ -19,7 +19,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -47,7 +47,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -71,7 +71,7 @@ actions: - func: KubeTask name: deleteFromStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/mysql/mysql-blueprint.yaml b/examples/mysql/mysql-blueprint.yaml index 9d19c51862..12a23cbfd7 100644 --- a/examples/mysql/mysql-blueprint.yaml +++ b/examples/mysql/mysql-blueprint.yaml @@ -17,7 +17,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -43,7 +43,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -63,7 +63,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.81.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/postgresql-deploymentconfig/README.md b/examples/postgresql-deploymentconfig/README.md index c32bb6ba3d..f66f7ae27f 100644 --- a/examples/postgresql-deploymentconfig/README.md +++ b/examples/postgresql-deploymentconfig/README.md @@ -14,7 +14,7 @@ cluster's DeploymentConfig resources. - Setup OpenShift, you can follow steps mentioned below - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster in namespace `kanister` +- Kanister controller version 0.82.0 installed in your cluster in namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) diff --git a/examples/postgresql-deploymentconfig/blueprint-v2/postgres-dep-config-blueprint.yaml b/examples/postgresql-deploymentconfig/blueprint-v2/postgres-dep-config-blueprint.yaml index be68b5d997..fede7ccc4a 100644 --- a/examples/postgresql-deploymentconfig/blueprint-v2/postgres-dep-config-blueprint.yaml +++ b/examples/postgresql-deploymentconfig/blueprint-v2/postgres-dep-config-blueprint.yaml @@ -20,7 +20,7 @@ actions: name: '{{ .DeploymentConfig.Name }}-{{ .DeploymentConfig.Namespace }}' namespace: '{{ .DeploymentConfig.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .DeploymentConfig.Namespace }}' command: - bash @@ -50,7 +50,7 @@ actions: name: '{{ .DeploymentConfig.Name }}-{{ .DeploymentConfig.Namespace }}' namespace: '{{ .DeploymentConfig.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .DeploymentConfig.Namespace }}' command: - bash @@ -75,7 +75,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/postgresql-deploymentconfig/postgres-dep-config-blueprint.yaml b/examples/postgresql-deploymentconfig/postgres-dep-config-blueprint.yaml index 26ed84c0d3..5721d90549 100644 --- a/examples/postgresql-deploymentconfig/postgres-dep-config-blueprint.yaml +++ b/examples/postgresql-deploymentconfig/postgres-dep-config-blueprint.yaml @@ -18,7 +18,7 @@ actions: name: '{{ .DeploymentConfig.Name }}-{{ .DeploymentConfig.Namespace }}' namespace: '{{ .DeploymentConfig.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .DeploymentConfig.Namespace }}' command: - bash @@ -47,7 +47,7 @@ actions: name: '{{ .DeploymentConfig.Name }}-{{ .DeploymentConfig.Namespace }}' namespace: '{{ .DeploymentConfig.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .DeploymentConfig.Namespace }}' command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/postgresql-ha/hook-blueprint/README.md b/examples/postgresql-ha/hook-blueprint/README.md index 891ae3f4f4..f50ca0b98d 100644 --- a/examples/postgresql-ha/hook-blueprint/README.md +++ b/examples/postgresql-ha/hook-blueprint/README.md @@ -20,7 +20,7 @@ This blueprint is only required when you face above mentioned issue, else you wi - Kubernetes 1.10+ - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster +- Kanister controller version 0.82.0 installed in your cluster - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Installing the Chart diff --git a/examples/postgresql-wale/README.md b/examples/postgresql-wale/README.md index b45f91973a..d3dd45c541 100755 --- a/examples/postgresql-wale/README.md +++ b/examples/postgresql-wale/README.md @@ -12,7 +12,7 @@ Bitnami charts can be used with [Kubeapps](https://kubeapps.com/) for deployment - Kubernetes 1.10+ - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster +- Kanister controller version 0.82.0 installed in your cluster - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Installing the Chart @@ -25,7 +25,7 @@ $ helm repo update $ helm install my-release bitnami/postgresql \ --namespace postgres-test --create-namespace \ --set image.repository=ghcr.io/kanisterio/postgresql \ - --set image.tag=0.81.0 \ + --set image.tag=0.82.0 \ --set postgresqlPassword=postgres-12345 \ --set postgresqlExtendedConf.archiveCommand="'envdir /bitnami/postgresql/data/env wal-e wal-push %p'" \ --set postgresqlExtendedConf.archiveMode=true \ @@ -41,7 +41,7 @@ In case, if you don't have `Kanister` installed already, you can use following c Add Kanister Helm repository and install Kanister operator ```bash $ helm repo add kanister https://charts.kanister.io -$ helm install kanister --namespace kanister --create-namespace kanister/kanister-operator --set image.tag=0.81.0 +$ helm install kanister --namespace kanister --create-namespace kanister/kanister-operator --set image.tag=0.82.0 ``` ## Integrating with Kanister diff --git a/examples/postgresql-wale/postgresql-blueprint.yaml b/examples/postgresql-wale/postgresql-blueprint.yaml index bb3f59b09c..19db47ff7e 100644 --- a/examples/postgresql-wale/postgresql-blueprint.yaml +++ b/examples/postgresql-wale/postgresql-blueprint.yaml @@ -132,7 +132,7 @@ actions: - func: PrepareData name: performRestore args: - image: "ghcr.io/kanisterio/postgresql:0.81.0" + image: "ghcr.io/kanisterio/postgresql:0.82.0" namespace: "{{ .StatefulSet.Namespace }}" volumes: "data-{{ .StatefulSet.Name }}-0": "/bitnami/postgresql" @@ -282,7 +282,7 @@ actions: name: deleteArtifact args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/postgresql:0.81.0" + image: "ghcr.io/kanisterio/postgresql:0.82.0" command: - bash - -o diff --git a/examples/postgresql/README.md b/examples/postgresql/README.md index a840342429..72031ec74c 100755 --- a/examples/postgresql/README.md +++ b/examples/postgresql/README.md @@ -12,7 +12,7 @@ Bitnami charts can be used with [Kubeapps](https://kubeapps.com/) for deployment - Kubernetes 1.10+ - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.81.0 installed in your cluster +- Kanister controller version 0.82.0 installed in your cluster - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Installing the Chart @@ -34,7 +34,7 @@ In case, if you don't have `Kanister` installed already, you can use following c Add Kanister Helm repository and install Kanister operator ```bash $ helm repo add kanister https://charts.kanister.io -$ helm install kanister --namespace kanister --create-namespace kanister/kanister-operator --set image.tag=0.81.0 +$ helm install kanister --namespace kanister --create-namespace kanister/kanister-operator --set image.tag=0.82.0 ``` ## Integrating with Kanister diff --git a/examples/postgresql/blueprint-v2/postgres-blueprint.yaml b/examples/postgresql/blueprint-v2/postgres-blueprint.yaml index e935b599bb..4547c3107c 100644 --- a/examples/postgresql/blueprint-v2/postgres-blueprint.yaml +++ b/examples/postgresql/blueprint-v2/postgres-blueprint.yaml @@ -20,7 +20,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}-postgresql' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -50,7 +50,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}-postgresql' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -75,7 +75,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/postgresql/postgres-blueprint.yaml b/examples/postgresql/postgres-blueprint.yaml index 62de9cd911..fccfc48ade 100644 --- a/examples/postgresql/postgres-blueprint.yaml +++ b/examples/postgresql/postgres-blueprint.yaml @@ -18,7 +18,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}-postgresql' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -47,7 +47,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}-postgresql' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/postgresql/v10.16.2/postgres-blueprint.yaml b/examples/postgresql/v10.16.2/postgres-blueprint.yaml index a7156ad480..81fde79e2e 100644 --- a/examples/postgresql/v10.16.2/postgres-blueprint.yaml +++ b/examples/postgresql/v10.16.2/postgres-blueprint.yaml @@ -18,7 +18,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}-postgresql' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -47,7 +47,7 @@ actions: name: '{{ index .Object.metadata.labels "app.kubernetes.io/instance" }}-postgresql' namespace: '{{ .StatefulSet.Namespace }}' args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.81.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.82.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/time-log/blueprint.yaml b/examples/time-log/blueprint.yaml index cf9fa0cae8..be002e07fd 100644 --- a/examples/time-log/blueprint.yaml +++ b/examples/time-log/blueprint.yaml @@ -38,7 +38,7 @@ actions: args: namespace: "{{ .Deployment.Namespace }}" pod: "{{ index .Deployment.Pods 0 }}" - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 backupArtifactPrefix: "{{ .ArtifactsIn.timeLog.KeyValue.path }}" backupIdentifier: "{{ .ArtifactsIn.backupIdentifier.KeyValue.id }}" - func: ScaleWorkload diff --git a/examples/time-log/time-logger-deployment.yaml b/examples/time-log/time-logger-deployment.yaml index 042a1e0158..aabbd9dcc7 100644 --- a/examples/time-log/time-logger-deployment.yaml +++ b/examples/time-log/time-logger-deployment.yaml @@ -27,7 +27,7 @@ spec: spec: containers: - name: test-container - image: ghcr.io/kanisterio/kanister-tools:0.81.0 + image: ghcr.io/kanisterio/kanister-tools:0.82.0 command: ["sh", "-c"] args: ["while true; do for x in $(seq 1200); do date >> /var/log/time.log; sleep 1; done; truncate /var/log/time.log --size 0; done"] volumeMounts: diff --git a/helm/kanister-operator/Chart.yaml b/helm/kanister-operator/Chart.yaml index 35c354c7b2..70515e2e1b 100644 --- a/helm/kanister-operator/Chart.yaml +++ b/helm/kanister-operator/Chart.yaml @@ -9,5 +9,5 @@ maintainers: - email: tom@kasten.io name: tdmanv icon: https://kasten.io/assets/img/kanister-logo.png -appVersion: 0.81.0 +appVersion: 0.82.0 source: https://github.com/kanisterio/kanister diff --git a/helm/kanister-operator/values.yaml b/helm/kanister-operator/values.yaml index ee73b32ed5..84e484c67b 100644 --- a/helm/kanister-operator/values.yaml +++ b/helm/kanister-operator/values.yaml @@ -3,7 +3,7 @@ # Declare variables to be passed into your templates. image: repository: ghcr.io/kanisterio/controller - tag: 0.81.0 + tag: 0.82.0 pullPolicy: IfNotPresent rbac: create: true diff --git a/helm/profile/Chart.yaml b/helm/profile/Chart.yaml index 2500a4db3e..ba6577af1b 100644 --- a/helm/profile/Chart.yaml +++ b/helm/profile/Chart.yaml @@ -3,7 +3,7 @@ description: A helm chart to create profile custom resource for kanister engine: gotpl name: profile home: https://kanister.io/ -version: 0.81.0 +version: 0.82.0 maintainers: - email: tom@kasten.io name: tdmanv diff --git a/pkg/app/csi-snapshot.go b/pkg/app/csi-snapshot.go index 66490ce1c7..e756dafd67 100644 --- a/pkg/app/csi-snapshot.go +++ b/pkg/app/csi-snapshot.go @@ -192,7 +192,7 @@ func (tlc TimeLogCSI) getAppDeploymentObj() *appsv1.Deployment { Containers: []v1.Container{ { Name: "test-container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"sh", "-c"}, Args: []string{"while true; do for x in $(seq 1200); do date >> /var/log/time.log; sleep 1; done; truncate /var/log/time.log --size 0; done"}, VolumeMounts: []v1.VolumeMount{ diff --git a/pkg/function/data_test.go b/pkg/function/data_test.go index f91bfc5e9c..2ace8773ac 100644 --- a/pkg/function/data_test.go +++ b/pkg/function/data_test.go @@ -135,7 +135,7 @@ func newRestoreDataBlueprint(pvc, identifierArg, identifierVal string) *crv1alph Func: RestoreDataFuncName, Args: map[string]interface{}{ RestoreDataNamespaceArg: "{{ .StatefulSet.Namespace }}", - RestoreDataImageArg: "ghcr.io/kanisterio/kanister-tools:0.81.0", + RestoreDataImageArg: "ghcr.io/kanisterio/kanister-tools:0.82.0", RestoreDataBackupArtifactPrefixArg: "{{ .Profile.Location.Bucket }}/{{ .Profile.Location.Prefix }}", RestoreDataRestorePathArg: "/mnt/data", RestoreDataEncryptionKeyArg: "{{ .Secrets.backupKey.Data.password | toString }}", @@ -267,7 +267,7 @@ func newRestoreDataAllBlueprint() *crv1alpha1.Blueprint { Func: RestoreDataAllFuncName, Args: map[string]interface{}{ RestoreDataAllNamespaceArg: "{{ .StatefulSet.Namespace }}", - RestoreDataAllImageArg: "ghcr.io/kanisterio/kanister-tools:0.81.0", + RestoreDataAllImageArg: "ghcr.io/kanisterio/kanister-tools:0.82.0", RestoreDataAllBackupArtifactPrefixArg: "{{ .Profile.Location.Bucket }}/{{ .Profile.Location.Prefix }}", RestoreDataAllBackupInfo: fmt.Sprintf("{{ .Options.%s }}", BackupDataAllOutput), RestoreDataAllRestorePathArg: "/mnt/data", @@ -478,7 +478,7 @@ func newCopyDataTestBlueprint() crv1alpha1.Blueprint { Func: RestoreDataFuncName, Args: map[string]interface{}{ RestoreDataNamespaceArg: "{{ .PVC.Namespace }}", - RestoreDataImageArg: "ghcr.io/kanisterio/kanister-tools:0.81.0", + RestoreDataImageArg: "ghcr.io/kanisterio/kanister-tools:0.82.0", RestoreDataBackupArtifactPrefixArg: fmt.Sprintf("{{ .Options.%s }}", CopyVolumeDataOutputBackupArtifactLocation), RestoreDataBackupTagArg: fmt.Sprintf("{{ .Options.%s }}", CopyVolumeDataOutputBackupTag), RestoreDataVolsArg: map[string]string{ diff --git a/pkg/function/export_rds_snapshot_location.go b/pkg/function/export_rds_snapshot_location.go index a338f414c1..23c6a1836d 100644 --- a/pkg/function/export_rds_snapshot_location.go +++ b/pkg/function/export_rds_snapshot_location.go @@ -60,7 +60,7 @@ const ( BackupAction RDSAction = "backup" RestoreAction RDSAction = "restore" - postgresToolsImage = "ghcr.io/kanisterio/postgres-kanister-tools:0.81.0" + postgresToolsImage = "ghcr.io/kanisterio/postgres-kanister-tools:0.82.0" ) type exportRDSSnapshotToLocationFunc struct{} diff --git a/pkg/function/kube_exec_test.go b/pkg/function/kube_exec_test.go index 74bad3e625..5e2968afea 100644 --- a/pkg/function/kube_exec_test.go +++ b/pkg/function/kube_exec_test.go @@ -179,11 +179,11 @@ func (s *KubeExecTest) TestParseLogAndCreateOutput(c *C) { errChecker Checker outChecker Checker }{ - {"###Phase-output###: {\"key\":\"version\",\"value\":\"0.81.0\"}", map[string]interface{}{"version": "0.81.0"}, IsNil, NotNil}, - {"###Phase-output###: {\"key\":\"version\",\"value\":\"0.81.0\"}\n###Phase-output###: {\"key\":\"path\",\"value\":\"/backup/path\"}", - map[string]interface{}{"version": "0.81.0", "path": "/backup/path"}, IsNil, NotNil}, - {"Random message ###Phase-output###: {\"key\":\"version\",\"value\":\"0.81.0\"}", map[string]interface{}{"version": "0.81.0"}, IsNil, NotNil}, - {"Random message with newline \n###Phase-output###: {\"key\":\"version\",\"value\":\"0.81.0\"}", map[string]interface{}{"version": "0.81.0"}, IsNil, NotNil}, + {"###Phase-output###: {\"key\":\"version\",\"value\":\"0.82.0\"}", map[string]interface{}{"version": "0.82.0"}, IsNil, NotNil}, + {"###Phase-output###: {\"key\":\"version\",\"value\":\"0.82.0\"}\n###Phase-output###: {\"key\":\"path\",\"value\":\"/backup/path\"}", + map[string]interface{}{"version": "0.82.0", "path": "/backup/path"}, IsNil, NotNil}, + {"Random message ###Phase-output###: {\"key\":\"version\",\"value\":\"0.82.0\"}", map[string]interface{}{"version": "0.82.0"}, IsNil, NotNil}, + {"Random message with newline \n###Phase-output###: {\"key\":\"version\",\"value\":\"0.82.0\"}", map[string]interface{}{"version": "0.82.0"}, IsNil, NotNil}, {"###Phase-output###: Invalid message", nil, NotNil, IsNil}, {"Random message", nil, IsNil, IsNil}, } { diff --git a/pkg/function/kube_task_test.go b/pkg/function/kube_task_test.go index 4b25bcd236..5457b1838c 100644 --- a/pkg/function/kube_task_test.go +++ b/pkg/function/kube_task_test.go @@ -71,7 +71,7 @@ func outputPhase(namespace string) crv1alpha1.BlueprintPhase { KubeTaskCommandArg: []string{ "sh", "-c", - "kando output version 0.81.0", + "kando output version 0.82.0", }, }, } @@ -144,7 +144,7 @@ func (s *KubeTaskSuite) TestKubeTask(c *C) { bp: newTaskBlueprint(outputPhase(s.namespace), sleepPhase(s.namespace), tickPhase(s.namespace)), outs: []map[string]interface{}{ { - "version": "0.81.0", + "version": "0.82.0", }, {}, {}, diff --git a/pkg/function/utils.go b/pkg/function/utils.go index 2eaf7de069..021637e732 100644 --- a/pkg/function/utils.go +++ b/pkg/function/utils.go @@ -28,7 +28,7 @@ import ( const ( // FunctionOutputVersion returns version FunctionOutputVersion = "version" - kanisterToolsImage = "ghcr.io/kanisterio/kanister-tools:0.81.0" + kanisterToolsImage = "ghcr.io/kanisterio/kanister-tools:0.82.0" kanisterToolsImageEnvName = "KANISTER_TOOLS" ) diff --git a/pkg/kube/pod_test.go b/pkg/kube/pod_test.go index 3d66cab787..215819371b 100644 --- a/pkg/kube/pod_test.go +++ b/pkg/kube/pod_test.go @@ -306,7 +306,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ @@ -352,7 +352,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ @@ -392,7 +392,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ @@ -446,7 +446,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ @@ -507,7 +507,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ @@ -570,7 +570,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"echo", "override command"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ @@ -610,7 +610,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"echo", "override command"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ @@ -653,7 +653,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []v1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.81.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.82.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: v1.PullPolicy(v1.PullIfNotPresent), VolumeMounts: []v1.VolumeMount{ diff --git a/pkg/testing/e2e_test.go b/pkg/testing/e2e_test.go index 98083aec39..bf31c9ba1d 100644 --- a/pkg/testing/e2e_test.go +++ b/pkg/testing/e2e_test.go @@ -228,7 +228,7 @@ func (s *E2ESuite) TestKubeTask(c *C) { Func: function.KubeTaskFuncName, Name: "test-kube-task", Args: map[string]interface{}{ - "image": "ghcr.io/kanisterio/kanister-tools:0.81.0", + "image": "ghcr.io/kanisterio/kanister-tools:0.82.0", "namespace": "{{ .Deployment.Namespace }}", "command": []string{"echo", "default specs"}, "podOverride": map[string]interface{}{ diff --git a/scripts/get.sh b/scripts/get.sh index c1efaa2018..5327b07c6d 100755 --- a/scripts/get.sh +++ b/scripts/get.sh @@ -140,7 +140,7 @@ cleanup() { } main() { - version="${1:-"0.81.0"}" + version="${1:-"0.82.0"}" initArch initOS verifySupported From ea168898802b9256eaf8c7d09be8ecc3d574489f Mon Sep 17 00:00:00 2001 From: Akanksha kumari Date: Thu, 8 Sep 2022 16:54:11 +0530 Subject: [PATCH 15/15] Update Image Tag to v9.99.9-dev only for ghcr/kanisterio images (#1623) * Modify UpdateImageTags function to only update image from blueprint if it has ghcr/kanisterio prefix Signed-off-by: Akanksha Kumari * Modify UpdateImageTags function to only update image from blueprint if it has ghcr/kanisterio prefix Signed-off-by: Akanksha Kumari * Update validateImageTags to verify if only image having prefix `ghcr.io/kanisterio` have tags updated Minor Refactor * Minor refactor, Add Comments Signed-off-by: Akanksha Kumari --- pkg/app/bp.go | 9 +++++++-- pkg/app/bp_test.go | 10 ++++++---- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/pkg/app/bp.go b/pkg/app/bp.go index 81e0852532..2dfbabf87a 100644 --- a/pkg/app/bp.go +++ b/pkg/app/bp.go @@ -28,6 +28,9 @@ import ( const ( blueprintsRepo = "./blueprints" + // imagePrefix specifies the prefix an image is going to have if it's being consumed from + // kanister's ghcr registry + imagePrefix = "ghcr.io/kanisterio" ) // Blueprint implements Blueprint() to return Blueprint specs for the app @@ -87,8 +90,10 @@ func updateImageTags(bp *crv1alpha1.Blueprint) { continue } - // ghcr.io/kanisterio/tools:v0.xx.x => ghcr.io/kanisterio/tools:v9.99.9-dev - phase.Args["image"] = fmt.Sprintf("%s:v9.99.9-dev", strings.Split(imageStr, ":")[0]) + if strings.HasPrefix(imageStr, imagePrefix) { + // ghcr.io/kanisterio/tools:v0.xx.x => ghcr.io/kanisterio/tools:v9.99.9-dev + phase.Args["image"] = fmt.Sprintf("%s:v9.99.9-dev", strings.Split(imageStr, ":")[0]) + } // Change imagePullPolicy to Always using podOverride config phase.Args["podOverride"] = crv1alpha1.JSONMap{ diff --git a/pkg/app/bp_test.go b/pkg/app/bp_test.go index fa2d3201e8..c96f5c07bc 100644 --- a/pkg/app/bp_test.go +++ b/pkg/app/bp_test.go @@ -73,7 +73,7 @@ func (bs *BlueprintSuite) TestUpdateImageTags(c *C) { Name: "test-kube-task", Args: map[string]interface{}{ "namespace": "{{ .Deployment.Namespace }}", - "image": "ghcr.io/image:v0.50.0", + "image": "ghcr.io/kanisterio/image:v0.50.0", "command": []string{"echo", "hello"}, }, }, @@ -104,7 +104,7 @@ func (bs *BlueprintSuite) TestUpdateImageTags(c *C) { Name: "test-kube-task", Args: map[string]interface{}{ "namespace": "{{ .Deployment.Namespace }}", - "image": "ghcr.io/image:v0.50.0", + "image": "ghcr.io/kanisterio/image:v0.50.0", "command": []string{"echo", "hello"}, }, }, @@ -153,9 +153,11 @@ func validateImageTags(c *C, bp *crv1alpha1.Blueprint) { if !ok { continue } - // Verify if the tag is "v9.99.9-dev" + // Verify if image with prefix "ghcr.io/kanisterio" is tagged "v9.99.9-dev" c.Log(fmt.Sprintf("phase:%s, image:%s", phase.Name, image.(string))) - c.Assert(strings.Split(image.(string), ":")[1], Equals, "v9.99.9-dev") + if strings.HasPrefix(image.(string), imagePrefix) { + c.Assert(strings.Split(image.(string), ":")[1], Equals, "v9.99.9-dev") + } c.Assert(phase.Args["podOverride"], DeepEquals, podOverride) } }