From ab2c4460411b01e952bc32da44250572f7289a4e Mon Sep 17 00:00:00 2001 From: Vivek Singh Date: Tue, 2 Jan 2024 17:28:27 +0100 Subject: [PATCH 01/17] Fix `CreateRDSSnapshot` function by correct the args and params (#2584) While refactoring in one of the previous PRs we interchanged two params of a function and because of that we started getting into a problem of `DBInstanceIdentifier` not specified. This commit corrects that. --- pkg/function/create_rds_snapshot.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/function/create_rds_snapshot.go b/pkg/function/create_rds_snapshot.go index 489faa6c797..7289b4fdfc0 100644 --- a/pkg/function/create_rds_snapshot.go +++ b/pkg/function/create_rds_snapshot.go @@ -139,8 +139,8 @@ func createRDSSnapshot(ctx context.Context, instanceID string, dbEngine RDSDBEng return output, nil } -func createSnapshot(ctx context.Context, rdsCli *rds.RDS, snapshotID, dbEngine, instanceID string) (int64, error) { - log.WithContext(ctx).Print("Creating RDS snapshot", field.M{"SnapshotID": snapshotID}) +func createSnapshot(ctx context.Context, rdsCli *rds.RDS, snapshotID, instanceID, dbEngine string) (int64, error) { + log.WithContext(ctx).Print("Creating RDS snapshot", field.M{"SnapshotID": snapshotID, "InstanceID": instanceID}) var allocatedStorage int64 if !isAuroraCluster(dbEngine) { dbSnapshotOutput, err := rdsCli.CreateDBSnapshot(ctx, instanceID, snapshotID) From e77bfc4bbb3b5177bd583be461696ddf057dcd5e Mon Sep 17 00:00:00 2001 From: Vladislav Naumov Date: Tue, 2 Jan 2024 18:33:11 +0100 Subject: [PATCH 02/17] K10-20312: add configs ref apps for OCP 4.14 (#2564) https://kasten.atlassian.net/browse/K10-20312 Co-authored-by: Vladislav Naumov Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> --- pkg/app/utils.go | 2 ++ pkg/testing/integration_register.go | 30 +++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+) diff --git a/pkg/app/utils.go b/pkg/app/utils.go index 0b446d91e4d..e1e7bac061a 100644 --- a/pkg/app/utils.go +++ b/pkg/app/utils.go @@ -49,6 +49,8 @@ const ( TemplateVersionOCP4_12 DBTemplate = "release-4.12" // TemplateVersionOCP4_13 stores version of db template 4.13 TemplateVersionOCP4_13 DBTemplate = "release-4.13" + // TemplateVersionOCP4_14 stores version of db template 4.14 + TemplateVersionOCP4_14 DBTemplate = "release-4.14" ) type storage string diff --git a/pkg/testing/integration_register.go b/pkg/testing/integration_register.go index 0164da179dd..d285e0730b5 100644 --- a/pkg/testing/integration_register.go +++ b/pkg/testing/integration_register.go @@ -550,3 +550,33 @@ var _ = Suite(&PostgreSQLDepConfig4_13{ profile: newSecretProfile(), }, }) + +// MysqlDBDepConfig4_14 for Mysql Instance that is deployed through DeploymentConfig on OpenShift cluster +type MysqlDBDepConfig4_14 struct { + IntegrationSuite +} + +var _ = Suite(&MysqlDBDepConfig4_14{ + IntegrationSuite{ + name: "mysqldc", + namespace: "mysqldc4-14-test", + app: app.NewMysqlDepConfig("mysqldeploymentconfig", app.TemplateVersionOCP4_14, app.EphemeralStorage, "8.0"), + bp: app.NewBlueprint("mysql-dep-config", "", true), + profile: newSecretProfile(), + }, +}) + +// PostgreSQLDepConfig4_14 for PostgreSQL deployed on openshift cluster +type PostgreSQLDepConfig4_14 struct { + IntegrationSuite +} + +var _ = Suite(&PostgreSQLDepConfig4_14{ + IntegrationSuite{ + name: "postgresdepconf", + namespace: "postgresdepconf4-14-test", + app: app.NewPostgreSQLDepConfig("postgresdepconf", app.TemplateVersionOCP4_14, app.EphemeralStorage), + bp: app.NewBlueprint("postgres-dep-config", "", true), + profile: newSecretProfile(), + }, +}) From a5a722fd84042c8e62d36cf59c2aea4061c9be9c Mon Sep 17 00:00:00 2001 From: Eugene Sumin <95425330+e-sumin@users.noreply.github.com> Date: Thu, 4 Jan 2024 18:03:30 +0100 Subject: [PATCH 03/17] ExecWithOption - get rid of stdout/stderr buffers (#2506) * `ExecWithOptions` should not return stdout / stdin Output could be obtained by writers passed via `ExecOptions` * Adjust `PodCommandExecutor` and tests --- pkg/kube/exec.go | 33 +++++++++------------- pkg/kube/exec_test.go | 6 ++-- pkg/kube/pod_command_executor.go | 2 +- pkg/kube/pod_command_executor_processor.go | 4 +-- pkg/kube/pod_command_executor_test.go | 6 ++-- 5 files changed, 22 insertions(+), 29 deletions(-) diff --git a/pkg/kube/exec.go b/pkg/kube/exec.go index ec082fb408d..dd96e6a49eb 100644 --- a/pkg/kube/exec.go +++ b/pkg/kube/exec.go @@ -81,14 +81,21 @@ type ExecOptions struct { // Exec is our version of the call to `kubectl exec` that does not depend on // k8s.io/kubernetes. func Exec(cli kubernetes.Interface, namespace, pod, container string, command []string, stdin io.Reader) (string, string, error) { + outbuf := &bytes.Buffer{} + errbuf := &bytes.Buffer{} opts := ExecOptions{ Command: command, Namespace: namespace, PodName: pod, ContainerName: container, Stdin: stdin, + Stdout: outbuf, + Stderr: errbuf, } - return ExecWithOptions(cli, opts) + + err := ExecWithOptions(cli, opts) + + return strings.TrimSpace(outbuf.String()), strings.TrimSpace(errbuf.String()), err } // ExecOutput is similar to Exec, except that inbound outputs are written to the @@ -113,32 +120,20 @@ func ExecOutput(cli kubernetes.Interface, namespace, pod, container string, comm }, } - _, _, err := ExecWithOptions(cli, opts) - return err + return ExecWithOptions(cli, opts) } -// ExecWithOptions executes a command in the specified container, -// returning stdout, stderr and error. `options` allowed for -// additional parameters to be passed. -func ExecWithOptions(kubeCli kubernetes.Interface, options ExecOptions) (string, string, error) { +// ExecWithOptions executes a command in the specified container, returning an error. +// `options` allowed for additional parameters to be passed. +func ExecWithOptions(kubeCli kubernetes.Interface, options ExecOptions) error { config, err := LoadConfig() if err != nil { - return "", "", err - } - - outbuf := &bytes.Buffer{} - if options.Stdout == nil { - options.Stdout = outbuf - } - - errbuf := &bytes.Buffer{} - if options.Stderr == nil { - options.Stderr = errbuf + return err } errCh := execStream(kubeCli, config, options) err = <-errCh - return strings.TrimSpace(outbuf.String()), strings.TrimSpace(errbuf.String()), errors.Wrap(err, "Failed to exec command in pod") + return errors.Wrap(err, "Failed to exec command in pod") } func execStream(kubeCli kubernetes.Interface, config *restclient.Config, options ExecOptions) chan error { diff --git a/pkg/kube/exec_test.go b/pkg/kube/exec_test.go index cadc3c395a5..417933c961f 100644 --- a/pkg/kube/exec_test.go +++ b/pkg/kube/exec_test.go @@ -139,7 +139,7 @@ func (s *ExecSuite) TestExecWithWriterOptions(c *C) { Stdout: bufout, Stderr: buferr, } - _, _, err := ExecWithOptions(s.cli, opts) + err := ExecWithOptions(s.cli, opts) c.Assert(err, IsNil) c.Assert(bufout.String(), Equals, testCase.expectedOut) c.Assert(buferr.String(), Equals, testCase.expectedErr) @@ -187,7 +187,7 @@ func (s *ExecSuite) TestErrorInExecWithOptions(c *C) { ContainerName: "", // use default container Stdin: nil, } - _, _, err1 := ExecWithOptions(s.cli, opts) // Output is not needed + err1 := ExecWithOptions(s.cli, opts) c.Assert(err1, Not(IsNil)) var ee1 *ExecError @@ -204,7 +204,7 @@ func (s *ExecSuite) TestErrorInExecWithOptions(c *C) { opts.Stdout = &bufout opts.Stderr = &buferr - _, _, err2 := ExecWithOptions(s.cli, opts) // Output is not needed + err2 := ExecWithOptions(s.cli, opts) c.Assert(err2, Not(IsNil)) var ee2 *ExecError diff --git a/pkg/kube/pod_command_executor.go b/pkg/kube/pod_command_executor.go index c6bc8f781a6..24899168b18 100644 --- a/pkg/kube/pod_command_executor.go +++ b/pkg/kube/pod_command_executor.go @@ -56,7 +56,7 @@ func (p *podCommandExecutor) Exec(ctx context.Context, command []string, stdin i ) go func() { - _, _, err = p.pcep.ExecWithOptions(opts) + err = p.pcep.ExecWithOptions(opts) close(cmdDone) }() diff --git a/pkg/kube/pod_command_executor_processor.go b/pkg/kube/pod_command_executor_processor.go index 94555bc5978..73de9270c4b 100644 --- a/pkg/kube/pod_command_executor_processor.go +++ b/pkg/kube/pod_command_executor_processor.go @@ -21,7 +21,7 @@ import ( // PodCommandExecutorProcessor is an interface wrapping kubernetes API invocation // it is purposed to be replaced by fake implementation in tests type PodCommandExecutorProcessor interface { - ExecWithOptions(opts ExecOptions) (string, string, error) + ExecWithOptions(opts ExecOptions) error } type podCommandExecutorProcessor struct { @@ -30,6 +30,6 @@ type podCommandExecutorProcessor struct { // ExecWithOptions executes a command in the specified pod and container, // returning stdout, stderr and error. -func (p *podCommandExecutorProcessor) ExecWithOptions(opts ExecOptions) (string, string, error) { +func (p *podCommandExecutorProcessor) ExecWithOptions(opts ExecOptions) error { return ExecWithOptions(p.cli, opts) } diff --git a/pkg/kube/pod_command_executor_test.go b/pkg/kube/pod_command_executor_test.go index 41361a0e36e..7d0e4d77cd0 100644 --- a/pkg/kube/pod_command_executor_test.go +++ b/pkg/kube/pod_command_executor_test.go @@ -69,8 +69,6 @@ type fakePodCommandExecutorProcessor struct { inExecWithOptionsOpts *ExecOptions execWithOptionsStdout string execWithOptionsStderr string - execWithOptionsRet1 string - execWithOptionsRet2 string execWithOptionsErr error // Signal to `ExecWithOptions` to start "executing" command. @@ -79,7 +77,7 @@ type fakePodCommandExecutorProcessor struct { execWithOptionsSyncEnd testBarrier } -func (fprp *fakePodCommandExecutorProcessor) ExecWithOptions(opts ExecOptions) (string, string, error) { +func (fprp *fakePodCommandExecutorProcessor) ExecWithOptions(opts ExecOptions) error { fprp.inExecWithOptionsOpts = &opts fprp.execWithOptionsSyncStart.SyncWithController() if opts.Stdout != nil && len(fprp.execWithOptionsStdout) > 0 { @@ -90,7 +88,7 @@ func (fprp *fakePodCommandExecutorProcessor) ExecWithOptions(opts ExecOptions) ( } fprp.execWithOptionsSyncEnd.SyncWithController() - return fprp.execWithOptionsRet1, fprp.execWithOptionsRet2, fprp.execWithOptionsErr + return fprp.execWithOptionsErr } func (s *PodCommandExecutorTestSuite) TestPodRunnerExec(c *C) { From e2967faa5677aeb1aa0c592fba7d290c0a86a89d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 01:58:23 +0000 Subject: [PATCH 04/17] deps(go): bump the common-golang group with 3 updates (#2590) Bumps the common-golang group with 3 updates: [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go), [golang.org/x/oauth2](https://github.com/golang/oauth2) and [google.golang.org/api](https://github.com/googleapis/google-api-go-client). Updates `github.com/aws/aws-sdk-go` from 1.49.9 to 1.49.17 - [Release notes](https://github.com/aws/aws-sdk-go/releases) - [Commits](https://github.com/aws/aws-sdk-go/compare/v1.49.9...v1.49.17) Updates `golang.org/x/oauth2` from 0.15.0 to 0.16.0 - [Commits](https://github.com/golang/oauth2/compare/v0.15.0...v0.16.0) Updates `google.golang.org/api` from 0.154.0 to 0.155.0 - [Release notes](https://github.com/googleapis/google-api-go-client/releases) - [Changelog](https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md) - [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.154.0...v0.155.0) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go dependency-type: direct:production update-type: version-update:semver-patch dependency-group: common-golang - dependency-name: golang.org/x/oauth2 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: common-golang - dependency-name: google.golang.org/api dependency-type: direct:production update-type: version-update:semver-minor dependency-group: common-golang ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- go.mod | 14 +++++++------- go.sum | 24 ++++++++++++------------ 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/go.mod b/go.mod index ad60d243e63..804fa975f7c 100644 --- a/go.mod +++ b/go.mod @@ -19,7 +19,7 @@ require ( github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/resources/armsubscriptions v1.3.0 github.com/Masterminds/semver v1.5.0 github.com/Masterminds/sprig v2.22.0+incompatible - github.com/aws/aws-sdk-go v1.49.9 + github.com/aws/aws-sdk-go v1.49.17 github.com/dustin/go-humanize v1.0.1 github.com/go-logr/logr v1.3.0 github.com/go-openapi/strfmt v0.21.10 @@ -45,9 +45,9 @@ require ( github.com/spf13/cobra v1.8.0 github.com/vmware/govmomi v0.34.0 go.uber.org/zap v1.26.0 - golang.org/x/oauth2 v0.15.0 + golang.org/x/oauth2 v0.16.0 gonum.org/v1/gonum v0.14.0 - google.golang.org/api v0.154.0 + google.golang.org/api v0.155.0 gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637 @@ -187,7 +187,7 @@ require ( golang.org/x/crypto v0.17.0 // indirect golang.org/x/exp v0.0.0-20231006140011-7918f672742d // indirect golang.org/x/mod v0.14.0 // indirect - golang.org/x/net v0.19.0 // indirect + golang.org/x/net v0.20.0 // indirect golang.org/x/sync v0.5.0 // indirect golang.org/x/sys v0.15.0 // indirect golang.org/x/term v0.15.0 // indirect @@ -197,9 +197,9 @@ require ( golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231127180814-3a041ad873d4 // indirect + google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20231211222908-989df2bf70f3 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 // indirect google.golang.org/grpc v1.60.1 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect diff --git a/go.sum b/go.sum index 33c0b18261f..81bb37c4ed7 100644 --- a/go.sum +++ b/go.sum @@ -109,8 +109,8 @@ github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPd github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so= github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= -github.com/aws/aws-sdk-go v1.49.9 h1:4xoyi707rsifB1yMsd5vGbAH21aBzwpL3gNRMSmjIyc= -github.com/aws/aws-sdk-go v1.49.9/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= +github.com/aws/aws-sdk-go v1.49.17 h1:Cc+7LgPjKeJkF2SdNo1IkpQ5Dfl9HCZEVw9OP3CPuEI= +github.com/aws/aws-sdk-go v1.49.17/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= @@ -644,8 +644,8 @@ golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4Iltr golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20191202225959-858c2ad4c8b6/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/oauth2 v0.15.0 h1:s8pnnxNVzjWyrvYdFUQq5llS1PX2zhPXmccZv99h7uQ= -golang.org/x/oauth2 v0.15.0/go.mod h1:q48ptWNTY5XWf+JNten23lcvHpLJ0ZSxF5ttTHKVCAM= +golang.org/x/oauth2 v0.16.0 h1:aDkGMBSYxElaoP81NpoUoz2oo2R2wHdZpGToUxfyQrQ= +golang.org/x/oauth2 v0.16.0/go.mod h1:hqZ+0LWXsiVoZpeld6jVt06P3adbS2Uu911W1SsJv2o= 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= @@ -761,8 +761,8 @@ google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= -google.golang.org/api v0.154.0 h1:X7QkVKZBskztmpPKWQXgjJRPA2dJYrL6r+sYPRLj050= -google.golang.org/api v0.154.0/go.mod h1:qhSMkM85hgqiokIYsrRyKxrjfBeIhgl4Z2JmeRkYylc= +google.golang.org/api v0.155.0 h1:vBmGhCYs0djJttDNynWo44zosHlPvHmA0XiN2zP2DtA= +google.golang.org/api v0.155.0/go.mod h1:GI5qK5f40kCpHfPn6+YzGAByIKWv8ujFnmoWm7Igduk= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -781,12 +781,12 @@ google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBr google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20201019141844-1ed22bb0c154/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= -google.golang.org/genproto v0.0.0-20231120223509-83a465c0220f h1:Vn+VyHU5guc9KjB5KrjI2q0wCOWEOIh0OEsleqakHJg= -google.golang.org/genproto v0.0.0-20231120223509-83a465c0220f/go.mod h1:nWSwAFPb+qfNJXsoeO3Io7zf4tMSfN8EA8RlDA04GhY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f h1:2yNACc1O40tTnrsbk9Cv6oxiW8pxI/pXj0wRtdlYmgY= -google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f/go.mod h1:Uy9bTZJqmfrw2rIBxgGLnamc78euZULUBrLZ9XTITKI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231127180814-3a041ad873d4 h1:DC7wcm+i+P1rN3Ff07vL+OndGg5OhNddHyTA+ocPqYE= -google.golang.org/genproto/googleapis/rpc v0.0.0-20231127180814-3a041ad873d4/go.mod h1:eJVxU6o+4G1PSczBr85xmyvSNYAKvAYgkub40YGomFM= +google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3 h1:1hfbdAfFbkmpg41000wDVqr7jUpK/Yo+LPnIxxGzmkg= +google.golang.org/genproto v0.0.0-20231211222908-989df2bf70f3/go.mod h1:5RBcpGRxr25RbDzY5w+dmaqpSEvl8Gwl1x2CICf60ic= +google.golang.org/genproto/googleapis/api v0.0.0-20231211222908-989df2bf70f3 h1:EWIeHfGuUf00zrVZGEgYFxok7plSAXBGcH7NNdMAWvA= +google.golang.org/genproto/googleapis/api v0.0.0-20231211222908-989df2bf70f3/go.mod h1:k2dtGpRrbsSyKcNPKKI5sstZkrNCZwpU/ns96JoHbGg= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0 h1:/jFB8jK5R3Sq3i/lmeZO0cATSzFfZaJq1J2Euan3XKU= +google.golang.org/genproto/googleapis/rpc v0.0.0-20231212172506-995d672761c0/go.mod h1:FUoWkonphQm3RhTS+kOEhF8h0iDpm4tdXolVCeZ9KKA= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= From 48afb3b53860701c736753dba5fd7dfcb49311b7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 02:10:39 +0000 Subject: [PATCH 05/17] deps(go): bump github.com/go-openapi/strfmt from 0.21.10 to 0.22.0 (#2591) Bumps [github.com/go-openapi/strfmt](https://github.com/go-openapi/strfmt) from 0.21.10 to 0.22.0. - [Commits](https://github.com/go-openapi/strfmt/compare/v0.21.10...v0.22.0) --- updated-dependencies: - dependency-name: github.com/go-openapi/strfmt dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 804fa975f7c..8d4fd374f51 100644 --- a/go.mod +++ b/go.mod @@ -22,7 +22,7 @@ require ( github.com/aws/aws-sdk-go v1.49.17 github.com/dustin/go-humanize v1.0.1 github.com/go-logr/logr v1.3.0 - github.com/go-openapi/strfmt v0.21.10 + github.com/go-openapi/strfmt v0.22.0 github.com/gofrs/uuid v4.4.0+incompatible github.com/golang/mock v1.6.0 github.com/google/uuid v1.5.0 diff --git a/go.sum b/go.sum index 81bb37c4ed7..16ef88cb617 100644 --- a/go.sum +++ b/go.sum @@ -218,8 +218,8 @@ github.com/go-openapi/jsonreference v0.20.1 h1:FBLnyygC4/IZZr893oiomc9XaghoveYTr github.com/go-openapi/jsonreference v0.20.1/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k= github.com/go-openapi/spec v0.0.0-20160808142527-6aced65f8501/go.mod h1:J8+jY1nAiCcj+friV/PDoE1/3eeccG9LYBs0tYvLOWc= github.com/go-openapi/spec v0.19.3/go.mod h1:FpwSN1ksY1eteniUU7X0N/BgJ7a4WvBFVA8Lj9mJglo= -github.com/go-openapi/strfmt v0.21.10 h1:JIsly3KXZB/Qf4UzvzJpg4OELH/0ASDQsyk//TTBDDk= -github.com/go-openapi/strfmt v0.21.10/go.mod h1:vNDMwbilnl7xKiO/Ve/8H8Bb2JIInBnH+lqiw6QWgis= +github.com/go-openapi/strfmt v0.22.0 h1:Ew9PnEYc246TwrEspvBdDHS4BVKXy/AOVsfqGDgAcaI= +github.com/go-openapi/strfmt v0.22.0/go.mod h1:HzJ9kokGIju3/K6ap8jL+OlGAbjpSv27135Yr9OivU4= github.com/go-openapi/swag v0.0.0-20160704191624-1d0bd113de87/go.mod h1:DXUve3Dpr1UfpPtxFw+EFuQ41HhCWZfha5jSVRG7C7I= github.com/go-openapi/swag v0.19.2/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= From 2968f6a30d7b7bdf3984a66e3557278bcd7fc15e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 03:35:12 +0000 Subject: [PATCH 06/17] deps(go): bump github.com/go-logr/logr from 1.3.0 to 1.4.1 (#2577) Bumps [github.com/go-logr/logr](https://github.com/go-logr/logr) from 1.3.0 to 1.4.1. - [Release notes](https://github.com/go-logr/logr/releases) - [Changelog](https://github.com/go-logr/logr/blob/master/CHANGELOG.md) - [Commits](https://github.com/go-logr/logr/compare/v1.3.0...v1.4.1) --- updated-dependencies: - dependency-name: github.com/go-logr/logr dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 8d4fd374f51..87ca2e84361 100644 --- a/go.mod +++ b/go.mod @@ -21,7 +21,7 @@ require ( github.com/Masterminds/sprig v2.22.0+incompatible github.com/aws/aws-sdk-go v1.49.17 github.com/dustin/go-humanize v1.0.1 - github.com/go-logr/logr v1.3.0 + github.com/go-logr/logr v1.4.1 github.com/go-openapi/strfmt v0.22.0 github.com/gofrs/uuid v4.4.0+incompatible github.com/golang/mock v1.6.0 diff --git a/go.sum b/go.sum index 16ef88cb617..5b72b85043b 100644 --- a/go.sum +++ b/go.sum @@ -198,8 +198,8 @@ github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7 github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= -github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-logr/logr v1.4.1 h1:pKouT5E8xu9zeFC39JXRDukb6JFQPXM5p5I91188VAQ= +github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-logr/zapr v1.2.3 h1:a9vnzlIBPQBBkeaR9IuMUfmVOrQlkoC4YfPoFkX3T7A= From bc4a5f85a2a411b750d0a89d39c1d8d8836c78f4 Mon Sep 17 00:00:00 2001 From: Haim Gelfenbeyn Date: Tue, 9 Jan 2024 13:34:27 -0500 Subject: [PATCH 07/17] Initial fixes to support multi-arch container building (#2524) * Do not constrain the architecture in the Docker debian repo: Docker debian repo has AMD64 and ARM64 images both. Do not contstrain it, so that a multi-platform build image can be built. * Support building AMD64 and ARM64 images: 1. Pass architecture from the Makefile and override the hardcoded AMD64 in the goreleaser file. 2. AMD64 artifacts have a _v1 suffix, ARM64 artifacts don't: relas the "cp" source glob to support both. * License extractor architecture does not have to be the same as the built image architecture: It's perfectly fine to use the native license extractor arch even when building a non-native architecture image. * Use current container's arch when downloading Kind into build container * Use TARGETPLATFORM argument in the build container * Build the build container for Intel and ARM architectures --------- Co-authored-by: Daniil Fedotov --- .github/workflows/kanister-image-build.yaml | 3 +++ Makefile | 4 ++-- build/package.sh | 1 - docker/build/Dockerfile | 7 +++++-- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/workflows/kanister-image-build.yaml b/.github/workflows/kanister-image-build.yaml index cd1db55d679..f49e58552ab 100644 --- a/.github/workflows/kanister-image-build.yaml +++ b/.github/workflows/kanister-image-build.yaml @@ -38,6 +38,8 @@ jobs: # needs: check-files # if: needs.check-files.outputs.changed == 'true' steps: + - name: Set up QEMU + uses: docker/setup-qemu-action@68827325e0b33c7199eb31dd4e31fbe9023e06e3 # v3.0.0 - name: Set up Docker Buildx uses: docker/setup-buildx-action@f95db51fddba0c2d1ec667646a06c2ce06100226 # v3.0.0 - name: Image metadata @@ -60,6 +62,7 @@ jobs: uses: docker/build-push-action@4a13e500e55cf31b7a5d59a38ab2040ab0f42f56 # v5.1.0 with: context: "{{defaultContext}}:docker/build" + platforms: linux/amd64,linux/arm64 push: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} diff --git a/Makefile b/Makefile index 4d922beb109..3972f555300 100644 --- a/Makefile +++ b/Makefile @@ -94,8 +94,8 @@ build: bin/$(ARCH)/$(BIN) build-controller: @$(MAKE) run CMD=" \ - goreleaser build --id $(BIN) --rm-dist --debug --snapshot \ - && cp dist/$(BIN)_linux_$(ARCH)_*/$(BIN) bin/$(ARCH)/$(BIN) \ + GOOS=linux GOARCH=$(ARCH) goreleaser build --id $(BIN) --rm-dist --debug --snapshot --single-target \ + && cp dist/$(BIN)_linux_$(ARCH)*/$(BIN) bin/$(ARCH)/$(BIN) \ " bin/$(ARCH)/$(BIN): diff --git a/build/package.sh b/build/package.sh index f7c0de2f80e..a4f096c9801 100755 --- a/build/package.sh +++ b/build/package.sh @@ -35,7 +35,6 @@ build_licenses_info_image() { exit 1 fi docker run --rm ${mount_cmd} \ - --platform linux/${ARCH}\ "ghcr.io/kanisterio/license-extractor:4e0a91a" \ --mode merge \ --source ${src_dir} \ diff --git a/docker/build/Dockerfile b/docker/build/Dockerfile index f81b22f3279..43e3e839a90 100644 --- a/docker/build/Dockerfile +++ b/docker/build/Dockerfile @@ -1,11 +1,13 @@ FROM golang:1.21-bullseye LABEL maintainer="Tom Manville" +ARG TARGETPLATFORM + RUN apt-get update && apt-get -y install apt-transport-https ca-certificates bash git gnupg2 software-properties-common curl jq wget \ && update-ca-certificates RUN curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg \ - && echo "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list + && echo "deb [signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list RUN apt update && apt install -y docker-ce docker-ce-cli containerd.io \ && apt-get clean @@ -18,7 +20,8 @@ COPY --from=alpine/helm:3.12.2 /usr/bin/helm /usr/local/bin/ COPY --from=golangci/golangci-lint:v1.55 /usr/bin/golangci-lint /usr/local/bin/ -RUN wget -O /usr/local/bin/kind https://github.com/kubernetes-sigs/kind/releases/download/v0.18.0/kind-linux-amd64 \ +RUN wget -O /usr/local/bin/kind \ + https://github.com/kubernetes-sigs/kind/releases/download/v0.18.0/kind-$(echo $TARGETPLATFORM | tr / -) \ && chmod +x /usr/local/bin/kind RUN git config --global --add safe.directory /go/src/github.com/kanisterio/kanister From e14d5169236b2c8bed2f59fa78fe8e70e4b19f66 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 19:00:06 +0000 Subject: [PATCH 08/17] Bump tj-actions/changed-files from 40.2.3 to 41.0.1 (#2578) Bumps [tj-actions/changed-files](https://github.com/tj-actions/changed-files) from 40.2.3 to 41.0.1. - [Release notes](https://github.com/tj-actions/changed-files/releases) - [Changelog](https://github.com/tj-actions/changed-files/blob/main/HISTORY.md) - [Commits](https://github.com/tj-actions/changed-files/compare/56284d80811fb5963a972b438f2870f175e5b7c8...716b1e13042866565e00e85fd4ec490e186c4a2f) --- updated-dependencies: - dependency-name: tj-actions/changed-files dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> Co-authored-by: Daniil Fedotov --- .github/workflows/atlas-image-build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/atlas-image-build.yaml b/.github/workflows/atlas-image-build.yaml index cb3059acdbc..366e94d43e0 100644 --- a/.github/workflows/atlas-image-build.yaml +++ b/.github/workflows/atlas-image-build.yaml @@ -21,7 +21,7 @@ jobs: - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 with: fetch-depth: 0 - - uses: tj-actions/changed-files@56284d80811fb5963a972b438f2870f175e5b7c8 # v40.2.3 + - uses: tj-actions/changed-files@716b1e13042866565e00e85fd4ec490e186c4a2f # v41.0.1 name: Get changed files id: changed-files with: From 91d5cbb0043bde441108041e37ba5590be624065 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 19:16:03 +0000 Subject: [PATCH 09/17] Bump the docker group with 1 update (#2588) Bumps the docker group with 1 update: [docker/metadata-action](https://github.com/docker/metadata-action). Updates `docker/metadata-action` from 5.4.0 to 5.5.0 - [Release notes](https://github.com/docker/metadata-action/releases) - [Commits](https://github.com/docker/metadata-action/compare/9dc751fe249ad99385a2583ee0d084c400eee04e...dbef88086f6cef02e264edb7dbf63250c17cef6c) --- updated-dependencies: - dependency-name: docker/metadata-action dependency-type: direct:production update-type: version-update:semver-minor dependency-group: docker ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> Co-authored-by: Daniil Fedotov --- .github/workflows/atlas-image-build.yaml | 2 +- .github/workflows/kanister-image-build.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/atlas-image-build.yaml b/.github/workflows/atlas-image-build.yaml index 366e94d43e0..d3fd460218e 100644 --- a/.github/workflows/atlas-image-build.yaml +++ b/.github/workflows/atlas-image-build.yaml @@ -39,7 +39,7 @@ jobs: uses: docker/setup-buildx-action@f95db51fddba0c2d1ec667646a06c2ce06100226 # v3.0.0 - name: Image metadata id: meta - uses: docker/metadata-action@9dc751fe249ad99385a2583ee0d084c400eee04e # v5.4.0 + uses: docker/metadata-action@dbef88086f6cef02e264edb7dbf63250c17cef6c # v5.5.0 with: images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} tags: | diff --git a/.github/workflows/kanister-image-build.yaml b/.github/workflows/kanister-image-build.yaml index f49e58552ab..eca550a8b31 100644 --- a/.github/workflows/kanister-image-build.yaml +++ b/.github/workflows/kanister-image-build.yaml @@ -44,7 +44,7 @@ jobs: uses: docker/setup-buildx-action@f95db51fddba0c2d1ec667646a06c2ce06100226 # v3.0.0 - name: Image metadata id: meta - uses: docker/metadata-action@9dc751fe249ad99385a2583ee0d084c400eee04e # v5.4.0 + uses: docker/metadata-action@dbef88086f6cef02e264edb7dbf63250c17cef6c # v5.5.0 with: images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} tags: | From 5866ad5817ef8e3dbfcbd3f162057d5054881dcf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 19:28:32 +0000 Subject: [PATCH 10/17] Bump alex-page/github-project-automation-plus from 0.8.3 to 0.9.0 (#2587) Bumps [alex-page/github-project-automation-plus](https://github.com/alex-page/github-project-automation-plus) from 0.8.3 to 0.9.0. - [Release notes](https://github.com/alex-page/github-project-automation-plus/releases) - [Commits](https://github.com/alex-page/github-project-automation-plus/compare/v0.8.3...v0.9.0) --- updated-dependencies: - dependency-name: alex-page/github-project-automation-plus dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Daniil Fedotov --- .github/workflows/triage-issues.yaml | 2 +- .github/workflows/triage-prs.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/triage-issues.yaml b/.github/workflows/triage-issues.yaml index ae4a4d4be6d..0a702768105 100644 --- a/.github/workflows/triage-issues.yaml +++ b/.github/workflows/triage-issues.yaml @@ -34,7 +34,7 @@ jobs: If you haven't already, please take a moment to review our project's [Code of Conduct](https://github.com/kanisterio/kanister/blob/master/CODE_OF_CONDUCT.md) document. - name: Update project - uses: alex-page/github-project-automation-plus@v0.8.3 + uses: alex-page/github-project-automation-plus@v0.9.0 with: repo-token: ${{ secrets.GH_TOKEN }} # must use a PAT here project: Kanister diff --git a/.github/workflows/triage-prs.yaml b/.github/workflows/triage-prs.yaml index 84c7f4531a6..e03fae29602 100644 --- a/.github/workflows/triage-prs.yaml +++ b/.github/workflows/triage-prs.yaml @@ -31,7 +31,7 @@ jobs: If you haven't already, please take a moment to review our project [contributing guideline](https://github.com/kanisterio/kanister/blob/master/CONTRIBUTING.md) and [Code of Conduct](https://github.com/kanisterio/kanister/blob/master/CODE_OF_CONDUCT.md) document. - name: Update status in project - uses: alex-page/github-project-automation-plus@v0.8.3 + uses: alex-page/github-project-automation-plus@v0.9.0 # This only works for PRs opened in the same repo and not by dependabot. # Other PRs don't get the necessary credentials. if: github.repository == 'kanisterio/kanister' && !github.event.pull_request.head.repo.fork From 1d9e89b6473c9b71fea8758393becc2a052c5563 Mon Sep 17 00:00:00 2001 From: ssuresh Date: Tue, 9 Jan 2024 19:07:26 -0500 Subject: [PATCH 11/17] Build kanister-tools Go binaries in fipsonly mode (#2492) * Build fipsonly restic * Build fipsonly kopia * Build fipsonly kando --- .goreleaser.yml | 4 +++- cmd/kando/fipsonly.go | 19 +++++++++++++++++++ docker/tools/Dockerfile | 11 ++++++++--- 3 files changed, 30 insertions(+), 4 deletions(-) create mode 100644 cmd/kando/fipsonly.go diff --git a/.goreleaser.yml b/.goreleaser.yml index 55b182b56ec..180b1cd013a 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -24,9 +24,11 @@ builds: - amd64 - id: kando binary: kando - main: cmd/kando/main.go + main: ./cmd/kando ldflags: *ldflags env: *env + tags: + - fipsonly goos: &goos - linux goarch: *goarch diff --git a/cmd/kando/fipsonly.go b/cmd/kando/fipsonly.go new file mode 100644 index 00000000000..e8a8258f2dd --- /dev/null +++ b/cmd/kando/fipsonly.go @@ -0,0 +1,19 @@ +// Copyright 2019 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. + +//go:build fipsonly + +package main + +import _ "crypto/tls/fipsonly" // Required for enabling fips only mode diff --git a/docker/tools/Dockerfile b/docker/tools/Dockerfile index 00e7c7c6027..df57da72a17 100644 --- a/docker/tools/Dockerfile +++ b/docker/tools/Dockerfile @@ -17,8 +17,11 @@ ENV GITHUB_REPOSITORY=https://github.com/restic/restic WORKDIR /restic -RUN git checkout v0.16.2 -RUN go run build.go +RUN git checkout v0.16.2 && \ + echo 'package main' > cmd/restic/fipsonly.go && \ + echo 'import _ "crypto/tls/fipsonly"' >> cmd/restic/fipsonly.go +# use debug flag to preserve symbols +RUN go run build.go --tags debug # Build kopia binary from specific commit WORKDIR / @@ -29,7 +32,9 @@ ENV GITHUB_REPOSITORY=https://github.com/${kopia_repo_org}/kopia WORKDIR /kopia -RUN git checkout ${kopia_build_commit} +RUN git checkout ${kopia_build_commit} && \ + echo 'package main' > fipsonly.go && \ + echo 'import _ "crypto/tls/fipsonly"' >> fipsonly.go RUN GO111MODULE=on GOOS=linux GOARCH=amd64 go build -o kopia \ -ldflags="-X github.com/kopia/kopia/repo.BuildVersion=$(git show --no-patch --format='%cs-%h') \ From 95cce71ac01c0f8ec1fd9deb40bd28b07a93961f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 10 Jan 2024 02:27:28 +0000 Subject: [PATCH 12/17] Bump the github-actions group with 1 update (#2592) Bumps the github-actions group with 1 update: [github/codeql-action](https://github.com/github/codeql-action). Updates `github/codeql-action` from 3.22.12 to 3.23.0 - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](https://github.com/github/codeql-action/compare/012739e5082ff0c22ca6d6ab32e07c36df03c4a4...e5f05b81d5b6ff8cfa111c80c22c5fd02a384118) --- updated-dependencies: - dependency-name: github/codeql-action dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/ossf-scorecard.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ossf-scorecard.yml b/.github/workflows/ossf-scorecard.yml index d996bf373ce..d0022c8b787 100644 --- a/.github/workflows/ossf-scorecard.yml +++ b/.github/workflows/ossf-scorecard.yml @@ -39,7 +39,7 @@ jobs: - # Upload the results to GitHub's code scanning dashboard. name: "Upload to results to dashboard" - uses: github/codeql-action/upload-sarif@012739e5082ff0c22ca6d6ab32e07c36df03c4a4 # v3.22.12 + uses: github/codeql-action/upload-sarif@e5f05b81d5b6ff8cfa111c80c22c5fd02a384118 # v3.23.0 with: sarif_file: results.sarif - From d7473c4307bafc89b89a75124374c0e1292993b5 Mon Sep 17 00:00:00 2001 From: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> Date: Tue, 9 Jan 2024 22:54:00 -0800 Subject: [PATCH 13/17] Replace kyaml/sets with kube-openapi/sets (#2593) Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- go.mod | 4 ++-- pkg/controllers/repositoryserver/server.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 87ca2e84361..4db90349f8f 100644 --- a/go.mod +++ b/go.mod @@ -58,10 +58,10 @@ require ( k8s.io/cli-runtime v0.26.11 k8s.io/client-go v0.26.11 k8s.io/code-generator v0.26.11 + k8s.io/kube-openapi v0.0.0-20230109183929-3758b55a6596 k8s.io/kubectl v0.26.11 k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 sigs.k8s.io/controller-runtime v0.14.7 - sigs.k8s.io/kustomize/kyaml v0.13.9 sigs.k8s.io/yaml v1.3.0 ) @@ -210,9 +210,9 @@ require ( k8s.io/component-base v0.26.11 // indirect k8s.io/gengo v0.0.0-20220902162205-c0856e24416d // indirect k8s.io/klog/v2 v2.90.1 // indirect - k8s.io/kube-openapi v0.0.0-20230109183929-3758b55a6596 // indirect sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect sigs.k8s.io/kustomize/api v0.12.1 // indirect + sigs.k8s.io/kustomize/kyaml v0.13.9 // indirect sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect ) diff --git a/pkg/controllers/repositoryserver/server.go b/pkg/controllers/repositoryserver/server.go index 37ff0969f28..b07d73d3aa4 100644 --- a/pkg/controllers/repositoryserver/server.go +++ b/pkg/controllers/repositoryserver/server.go @@ -28,7 +28,7 @@ import ( "github.com/kanisterio/kanister/pkg/kube" reposerver "github.com/kanisterio/kanister/pkg/secrets/repositoryserver" "github.com/pkg/errors" - "sigs.k8s.io/kustomize/kyaml/sets" + "k8s.io/kube-openapi/pkg/util/sets" ) const ( From 90771b94a1d27c81df37028c09968e762def03a8 Mon Sep 17 00:00:00 2001 From: Daniil Fedotov Date: Wed, 10 Jan 2024 11:21:52 +0000 Subject: [PATCH 14/17] Update blueprint images dependencies to fix reported vulnerabilities (#2523) Update base images Build go libs in kanister-tools image Remove unused tools with vulnerabilities Expand vulnerability report tool output to show more information --- .../grype-vulnerability-scanner.yaml | 8 +-- .goreleaser.yml | 6 ++ docker/cassandra/Dockerfile | 14 +++- .../image/adobeSink.Dockerfile | 12 ++-- .../image/adobeSource.Dockerfile | 14 +++- .../kanister-elasticsearch/image/Dockerfile | 4 +- docker/mongodb/Dockerfile | 10 ++- docker/postgres-kanister-tools/Dockerfile | 14 +++- docker/tools/Dockerfile | 18 ++++- examples/cassandra/README.md | 2 +- pkg/tools/grype_report_parser_tool.go | 72 +++++++++++++------ pkg/tools/grype_report_parser_tool_test.go | 4 +- 12 files changed, 134 insertions(+), 44 deletions(-) diff --git a/.github/workflows/grype-vulnerability-scanner.yaml b/.github/workflows/grype-vulnerability-scanner.yaml index 986a29ea300..6589cf135c0 100644 --- a/.github/workflows/grype-vulnerability-scanner.yaml +++ b/.github/workflows/grype-vulnerability-scanner.yaml @@ -34,10 +34,10 @@ jobs: steps: - name: Printing Image Registry id: image-registry - run: echo "image_registry=${{fromJson(needs.vulnerability-scanner.outputs.valid_images).image_registry}}" >> "$GITHUB_ENV" + run: echo "image_registry=${{fromJson(needs.vulnerability-scanner.outputs.valid_images).image_registry}}" >> "$GITHUB_ENV" - name: Printing Image Tag id: image-tag - run: echo "image_tag=${{fromJson(needs.vulnerability-scanner.outputs.valid_images).tag}}" >> "$GITHUB_ENV" + run: echo "image_tag=${{fromJson(needs.vulnerability-scanner.outputs.valid_images).tag}}" >> "$GITHUB_ENV" - name: Printing Image Path run: echo "image_path=${{env.image_registry}}/${{matrix.images}}:${{env.image_tag}}" >> "$GITHUB_ENV" - name: Running vulnerability scanner @@ -55,6 +55,6 @@ jobs: with: ref: master path: repo - - name: Parsing vulnerability scanner report - run: go run repo/pkg/tools/grype_report_parser_tool.go -s "High,Critical" -p results.json + - name: Parsing vulnerability scanner report + run: go run repo/pkg/tools/grype_report_parser_tool.go -s "High,Critical" -p results.json --github diff --git a/.goreleaser.yml b/.goreleaser.yml index 180b1cd013a..ccfb9f239e4 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -74,6 +74,8 @@ dockers: image_templates: - 'ghcr.io/kanisterio/postgres-kanister-tools:{{ .Tag }}' dockerfile: 'docker/postgres-kanister-tools/Dockerfile' + build_flag_templates: + - "--build-arg=TOOLS_IMAGE=ghcr.io/kanisterio/kanister-tools:{{ .Tag }}" - image_templates: - 'ghcr.io/kanisterio/postgresql:{{ .Tag }}' dockerfile: 'docker/postgresql/Dockerfile' @@ -101,11 +103,15 @@ dockers: image_templates: - 'ghcr.io/kanisterio/mongodb:{{ .Tag }}' dockerfile: 'docker/mongodb/Dockerfile' + build_flag_templates: + - "--build-arg=TOOLS_IMAGE=ghcr.io/kanisterio/kanister-tools:{{ .Tag }}" - ids: - kando image_templates: - 'ghcr.io/kanisterio/cassandra:{{ .Tag }}' dockerfile: 'docker/cassandra/Dockerfile' + build_flag_templates: + - "--build-arg=TOOLS_IMAGE=ghcr.io/kanisterio/kanister-tools:{{ .Tag }}" - image_templates: - 'ghcr.io/kanisterio/kafka-adobe-s3-source-connector:{{ .Tag }}' dockerfile: 'docker/kafka-adobes3Connector/image/adobeSource.Dockerfile' diff --git a/docker/cassandra/Dockerfile b/docker/cassandra/Dockerfile index f785eb26d95..a782b289a35 100644 --- a/docker/cassandra/Dockerfile +++ b/docker/cassandra/Dockerfile @@ -1,9 +1,17 @@ -FROM bitnami/cassandra:3.11.8-debian-10-r20 +# We get tools from tools image +# Tools are not up to date in debian repos +ARG TOOLS_IMAGE +FROM ${TOOLS_IMAGE} AS TOOLS_IMAGE + +# Actual image base +FROM bitnami/cassandra:4.1.3-debian-11-r76 MAINTAINER "Tom Manville " # Install restic to take backups -COPY --from=restic/restic:0.11.0 /usr/bin/restic /usr/local/bin/restic +COPY --from=TOOLS_IMAGE /usr/local/bin/restic /usr/local/bin/restic +# Update gosu from recent version +COPY --from=TOOLS_IMAGE /usr/local/bin/gosu /usr/local/bin/gosu -# Install kando +# Install kando ADD kando /usr/local/bin/ diff --git a/docker/kafka-adobes3Connector/image/adobeSink.Dockerfile b/docker/kafka-adobes3Connector/image/adobeSink.Dockerfile index edb2a886fea..194fcaa4e2a 100644 --- a/docker/kafka-adobes3Connector/image/adobeSink.Dockerfile +++ b/docker/kafka-adobes3Connector/image/adobeSink.Dockerfile @@ -1,11 +1,10 @@ -FROM confluentinc/cp-kafka-connect:6.1.0 +FROM confluentinc/cp-kafka-connect:7.4.3 USER root -RUN microdnf install -y lsof - -# copy the jar files +RUN microdnf install -y lsof platform-python python3-libs +# TODO: maybe use builder image for that RUN microdnf install -y \ java-1.8.0-openjdk \ java-1.8.0-openjdk-devel @@ -14,9 +13,14 @@ ENV JAVA_HOME /usr/lib/jvm/java-1.8.0-openjdk/ RUN microdnf install git -y RUN java -version RUN git clone https://github.com/adobe/kafka-connect-s3.git +# Temp patch until vulnerable deps are fixed +RUN sed -i "s/versions.awsSdkS3 = '1.11.803'/versions.awsSdkS3 = '1.12.261'/g" kafka-connect-s3/dependencies.gradle +RUN sed -i "s/versions.jackson = '2.10.4'/versions.jackson = '2.12.7.1'/g" kafka-connect-s3/dependencies.gradle RUN cd kafka-connect-s3 && ./gradlew shadowJar # copy the jar files RUN cp ./kafka-connect-s3/build/libs/kafka-connect-s3-chart/kafka-connect/0.0.4-2a8a4aa-all.jar /opt/ +# cleanup +RUN rm -rf ~/.gradle ./kafka-connect-s3 # Install kando ADD kando /usr/local/bin/ diff --git a/docker/kafka-adobes3Connector/image/adobeSource.Dockerfile b/docker/kafka-adobes3Connector/image/adobeSource.Dockerfile index 9532d85b8e4..ffb5fd97f30 100644 --- a/docker/kafka-adobes3Connector/image/adobeSource.Dockerfile +++ b/docker/kafka-adobes3Connector/image/adobeSource.Dockerfile @@ -1,8 +1,11 @@ -FROM confluentinc/cp-kafka-connect:6.1.0 +FROM confluentinc/cp-kafka-connect:7.4.3 USER root -# copy the jar files +RUN microdnf install -y \ + platform-python python3-libs + +# TODO: maybe use builder image for that RUN microdnf install -y \ java-1.8.0-openjdk \ java-1.8.0-openjdk-devel @@ -11,9 +14,14 @@ ENV JAVA_HOME /usr/lib/jvm/java-1.8.0-openjdk/ RUN microdnf install git -y RUN java -version RUN git clone https://github.com/adobe/kafka-connect-s3.git +# Temp patch until vulnerable deps are fixed +RUN sed -i "s/versions.awsSdkS3 = '1.11.803'/versions.awsSdkS3 = '1.12.261'/g" kafka-connect-s3/dependencies.gradle +RUN sed -i "s/versions.jackson = '2.10.4'/versions.jackson = '2.12.7.1'/g" kafka-connect-s3/dependencies.gradle RUN cd kafka-connect-s3 && ./gradlew shadowJar - +# copy the jar files RUN cp ./kafka-connect-s3/build/libs/kafka-connect-s3-chart/kafka-connect/0.0.4-2a8a4aa-all.jar /opt/ +# cleanup +RUN rm -rf ~/.gradle ./kafka-connect-s3 # adding script to monitor source connector COPY docker/kafka-adobes3Connector/image/adobe-monitorsource.sh monitorconnect.sh diff --git a/docker/kanister-elasticsearch/image/Dockerfile b/docker/kanister-elasticsearch/image/Dockerfile index 428927ffbd5..fb9eccb53e7 100644 --- a/docker/kanister-elasticsearch/image/Dockerfile +++ b/docker/kanister-elasticsearch/image/Dockerfile @@ -1,3 +1,5 @@ +# We get tools from tools image +# Tools are not up to date in debian repos ARG TOOLS_IMAGE FROM ${TOOLS_IMAGE} AS TOOLS_IMAGE @@ -10,7 +12,7 @@ RUN apt update RUN apt install -y npm bash curl libcap2-bin RUN curl -fsSL https://deb.nodesource.com/setup_current.x | bash - && \ apt-get install -y nodejs -RUN npm install -g npm yo grunt-cli bower express +RUN npm install -g npm RUN npm install elasticdump -g RUN setcap cap_chown,cap_fowner,cap_dac_override+iep /usr/local/bin/kopia diff --git a/docker/mongodb/Dockerfile b/docker/mongodb/Dockerfile index e053d59368a..3172061f549 100755 --- a/docker/mongodb/Dockerfile +++ b/docker/mongodb/Dockerfile @@ -1,6 +1,14 @@ -FROM bitnami/mongodb:5.0.14-debian-11-r0 +# We get tools from tools image +# Tools are not up to date in debian repos +ARG TOOLS_IMAGE +FROM ${TOOLS_IMAGE} AS TOOLS_IMAGE + +FROM bitnami/mongodb:7.0.4-debian-11-r0 LABEL maintainer="Tom Manville " +# Update gosu from recent version +COPY --from=TOOLS_IMAGE /usr/local/bin/gosu /usr/local/bin/gosu + # Install kando ADD kando /usr/local/bin/ diff --git a/docker/postgres-kanister-tools/Dockerfile b/docker/postgres-kanister-tools/Dockerfile index 8cdb6ab51ee..bcf9e225c92 100644 --- a/docker/postgres-kanister-tools/Dockerfile +++ b/docker/postgres-kanister-tools/Dockerfile @@ -1,4 +1,10 @@ -FROM postgres:16-bullseye +# We get tools from tools image +# Tools are not up to date in debian repos +ARG TOOLS_IMAGE +FROM ${TOOLS_IMAGE} AS TOOLS_IMAGE + +# Actual image base +FROM postgres:16.1-bullseye ENV DEBIAN_FRONTEND noninteractive @@ -9,7 +15,11 @@ RUN apt-get update && apt-get -y install curl python3 groff less jq python3-pip pip3 install --upgrade awscli && \ apt-get clean -COPY --from=restic/restic:0.11.0 /usr/bin/restic /usr/local/bin/restic +# Install restic to take backups +COPY --from=TOOLS_IMAGE /usr/local/bin/restic /usr/local/bin/restic +# Update gosu from recent version +COPY --from=TOOLS_IMAGE /usr/local/bin/gosu /usr/local/bin/gosu + ADD kando /usr/local/bin/ CMD ["tail", "-f", "/dev/null"] diff --git a/docker/tools/Dockerfile b/docker/tools/Dockerfile index df57da72a17..e5e79c0c14c 100644 --- a/docker/tools/Dockerfile +++ b/docker/tools/Dockerfile @@ -3,6 +3,8 @@ FROM golang:1.21-bullseye AS builder ARG kopia_build_commit=master ARG kopia_repo_org=kopia +ARG restic_vsn=v0.16.2 +ARG gosu_vsn=1.17 ENV CGO_ENABLED=1 GOEXPERIMENT=boringcrypto GO_EXTLINK_ENABLED=0 RUN apt-get install git @@ -17,12 +19,25 @@ ENV GITHUB_REPOSITORY=https://github.com/restic/restic WORKDIR /restic -RUN git checkout v0.16.2 && \ +RUN git checkout ${restic_vsn} && \ echo 'package main' > cmd/restic/fipsonly.go && \ echo 'import _ "crypto/tls/fipsonly"' >> cmd/restic/fipsonly.go # use debug flag to preserve symbols RUN go run build.go --tags debug +# Build restic binary from source - released version +# This will allow us to bring in security fixes more up to date then apt repos +WORKDIR / + +RUN git clone https://github.com/tianon/gosu.git + +ENV GITHUB_REPOSITORY=https://github.com/tianon/gosu + +WORKDIR /gosu + +RUN git checkout ${gosu_vsn} +RUN go build -o gosu + # Build kopia binary from specific commit WORKDIR / @@ -70,6 +85,7 @@ LABEL name="kanister-tools" \ description="Tools for application-specific data protection" COPY --from=builder /restic/restic /usr/local/bin/restic +COPY --from=builder /gosu/gosu /usr/local/bin/gosu COPY --from=builder /kopia/kopia /usr/local/bin/kopia COPY LICENSE /licenses/LICENSE diff --git a/examples/cassandra/README.md b/examples/cassandra/README.md index 6f956bc6b5a..a71e749cacc 100644 --- a/examples/cassandra/README.md +++ b/examples/cassandra/README.md @@ -33,7 +33,7 @@ $ helm install cassandra bitnami/cassandra --namespace --set ima ``` -This command will install Cassandra on your Kubernetes cluster with 2 nodes. You can notice that we are using custom image of Cassandra in the helm to install the Cassandra cluster. The reason is we have to use some Kanister tools to take backup, so only change that we have done is including that tooling on top of standard `cassandra:3.11.8-debian-10-r20` image. +This command will install Cassandra on your Kubernetes cluster with 2 nodes. You can notice that we are using custom image of Cassandra in the helm to install the Cassandra cluster. The reason is we have to use some Kanister tools to take backup, so only change that we have done is including that tooling on top of standard `4.1.3-debian-11-r76` image. ## Integrating with Kanister diff --git a/pkg/tools/grype_report_parser_tool.go b/pkg/tools/grype_report_parser_tool.go index 5aebeedf951..39ebf40328c 100644 --- a/pkg/tools/grype_report_parser_tool.go +++ b/pkg/tools/grype_report_parser_tool.go @@ -17,6 +17,7 @@ type vulnerabilityScannerResponse struct { type matchResponse struct { Vulnerabilities vulnerabilityReport `json:"vulnerability"` + Artifact artifact `json:"artifact"` } type fixVersionsResponse struct { @@ -26,46 +27,55 @@ type fixVersionsResponse struct { type vulnerabilityReport struct { ID string `json:"id"` + DataSource string `json:"dataSource,omitempty"` Severity string `json:"severity"` Namespace string `json:"namespace"` Description string `json:"description"` FixVersions fixVersionsResponse `json:"fix"` } +type artifact struct { + Name string `json:"name"` + Version string `json:"version"` + Type string `json:"type"` + Purl string `json:"purl"` + Locations json.RawMessage `json:"locations,omitempty"` + Metadata json.RawMessage `json:"metadata,omitempty"` +} + // filterVulnerabilityReportMatches filters vulnerabilities based on the severity levels set in severityTypeSet -func filterVulnerabilityReportMatches(matches []matchResponse, severityTypeSet map[string]bool) ([]vulnerabilityReport, error) { - mv := make([]vulnerabilityReport, 0) +func filterVulnerabilityReportMatches(matches []matchResponse, severityTypeSet map[string]bool) ([]matchResponse, error) { + filtered := make([]matchResponse, 0) for _, m := range matches { if severityTypeSet[m.Vulnerabilities.Severity] { - mv = append(mv, m.Vulnerabilities) + filtered = append(filtered, m) } } - return mv, nil + return filtered, nil } // decodeVulnerabilityReports unmarshals the specific matches from the vulnerability report // and returns a list of vulnerabilities based on the severity levels set in severityTypeSet -func decodeVulnerabilityReports(v vulnerabilityScannerResponse, severityTypeSet map[string]bool) ([]vulnerabilityReport, error) { +func decodeVulnerabilityReports(v vulnerabilityScannerResponse, severityTypeSet map[string]bool) ([]matchResponse, error) { var mr []matchResponse - mv := make([]vulnerabilityReport, 0) if err := json.Unmarshal(v.Matches, &mr); err != nil { - return mv, fmt.Errorf("failed to unmarshal matches: %v", err) + return make([]matchResponse, 0), fmt.Errorf("failed to unmarshal matches: %v", err) } return filterVulnerabilityReportMatches(mr, severityTypeSet) } // parseVulerabilitiesReport unmarshals the vulnerability report and returns a list of vulnerabilities // based on the severity levels set in severityTypeSet -func parseVulerabilitiesReport(filePath string, severityLevels []string) ([]vulnerabilityReport, error) { - mv := make([]vulnerabilityReport, 0) +func parseVulerabilitiesReport(filePath string, severityLevels []string) ([]matchResponse, error) { + mr := make([]matchResponse, 0) data, err := os.ReadFile(filePath) if err != nil { - return mv, fmt.Errorf("failed to read file at path %s: %v", filePath, err) + return mr, fmt.Errorf("failed to read file at path %s: %v", filePath, err) } var response vulnerabilityScannerResponse if err = json.Unmarshal(data, &response); err != nil { - return mv, fmt.Errorf("failed to unmarshal response: %v", err) + return mr, fmt.Errorf("failed to unmarshal response: %v", err) } severityTypeSet := make(map[string]bool) for _, severityLevel := range severityLevels { @@ -75,13 +85,30 @@ func parseVulerabilitiesReport(filePath string, severityLevels []string) ([]vuln } // printResult Displays the filtered list of vulnerability reports to stdout -func printResult(mv []vulnerabilityReport) { - for _, vulnerability := range mv { - fmt.Printf("ID: %s\n", vulnerability.ID) - fmt.Printf("Severity: %s\n", vulnerability.Severity) - fmt.Printf("Namespace: %s\n", vulnerability.Namespace) - fmt.Printf("Description: %s\n", vulnerability.Description) - fmt.Printf("Fix Versions: %v\n", vulnerability.FixVersions) +func printResult(mr []matchResponse, githubActionOutput bool) { + for _, response := range mr { + fmt.Printf("ID: %s\n", response.Vulnerabilities.ID) + fmt.Printf("Link: https://github.com/advisories/%s\n", response.Vulnerabilities.DataSource) + fmt.Printf("Severity: %s\n", response.Vulnerabilities.Severity) + fmt.Printf("Namespace: %s\n", response.Vulnerabilities.Namespace) + fmt.Printf("Description: %s\n", response.Vulnerabilities.Description) + fmt.Printf("Fix Versions: %v\n", response.Vulnerabilities.FixVersions) + fmt.Println("Package:") + fmt.Printf("Name: %v\n", response.Artifact.Name) + fmt.Printf("Version: %v\n", response.Artifact.Version) + fmt.Printf("Type: %v\n", response.Artifact.Type) + fmt.Printf("PURL: %v\n", response.Artifact.Purl) + if githubActionOutput { + fmt.Println("::group::Locations") + fmt.Printf("%s\n", response.Artifact.Locations) + fmt.Println("::endgroup::") + fmt.Println("::group::Metadata") + fmt.Printf("%s\n", response.Artifact.Metadata) + fmt.Println("::endgroup::") + } else { + fmt.Printf("Locations: %s\n", response.Artifact.Locations) + fmt.Printf("Metadata: \n%s\n", response.Artifact.Metadata) + } fmt.Printf("\n") } } @@ -90,6 +117,7 @@ func main() { validSeverityLevels := []string{"Negliable", "Low", "Medium", "High", "Critical"} severityInputList := flag.String("s", "High,Critical", "Comma separated list of severity levels to scan. Valid severity levels are: "+strings.Join(validSeverityLevels, ",")) reportJsonFilePath := flag.String("p", "", "Path to the JSON file containing the vulnerabilities report") + githubActionOutput := flag.Bool("github", false, "Whether to use github action output format") flag.Parse() // passing file path is compulsory @@ -98,15 +126,15 @@ func main() { os.Exit(1) } severityLevels := strings.Split(*severityInputList, ",") - mv, err := parseVulerabilitiesReport(*reportJsonFilePath, severityLevels) + mr, err := parseVulerabilitiesReport(*reportJsonFilePath, severityLevels) if err != nil { fmt.Printf("Failed to parse vulnerabilities report: %v\n", err) os.Exit(1) } - fmt.Printf("Found %d vulnerabilities\n", len(mv)) - if len(mv) == 0 { + fmt.Printf("Found %d vulnerabilities\n", len(mr)) + if len(mr) == 0 { os.Exit(0) } - printResult(mv) + printResult(mr, *githubActionOutput) os.Exit(1) } diff --git a/pkg/tools/grype_report_parser_tool_test.go b/pkg/tools/grype_report_parser_tool_test.go index 20645538e6f..7b8bb84e100 100644 --- a/pkg/tools/grype_report_parser_tool_test.go +++ b/pkg/tools/grype_report_parser_tool_test.go @@ -48,7 +48,7 @@ func (v *VulnerabilityParserSuite) TestValidJsonForMatchingVulerabilities(c *C) c.Assert(len(matchingVulnerabilities), Equals, 2) c.Assert(err, IsNil) for index, vulnerability := range matchingVulnerabilities { - c.Assert(vulnerability.ID, Equals, expectedIds[index]) - c.Assert(vulnerability.Severity, Equals, severityLevels[index]) + c.Assert(vulnerability.Vulnerabilities.ID, Equals, expectedIds[index]) + c.Assert(vulnerability.Vulnerabilities.Severity, Equals, severityLevels[index]) } } From 858bc9bb54afe0ba1d2651273750ac67b86e18a8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 10 Jan 2024 18:45:41 +0000 Subject: [PATCH 15/17] deps(go): bump the k8s group with 4 updates (#2595) Bumps the k8s group with 4 updates: [k8s.io/api](https://github.com/kubernetes/api), [k8s.io/apiextensions-apiserver](https://github.com/kubernetes/apiextensions-apiserver), [k8s.io/cli-runtime](https://github.com/kubernetes/cli-runtime) and [k8s.io/kubectl](https://github.com/kubernetes/kubectl). Updates `k8s.io/api` from 0.26.11 to 0.26.12 - [Commits](https://github.com/kubernetes/api/compare/v0.26.11...v0.26.12) Updates `k8s.io/apiextensions-apiserver` from 0.26.10 to 0.26.12 - [Release notes](https://github.com/kubernetes/apiextensions-apiserver/releases) - [Commits](https://github.com/kubernetes/apiextensions-apiserver/compare/v0.26.10...v0.26.12) Updates `k8s.io/cli-runtime` from 0.26.11 to 0.26.12 - [Commits](https://github.com/kubernetes/cli-runtime/compare/v0.26.11...v0.26.12) Updates `k8s.io/kubectl` from 0.26.11 to 0.26.12 - [Commits](https://github.com/kubernetes/kubectl/compare/v0.26.11...v0.26.12) --- updated-dependencies: - dependency-name: k8s.io/api dependency-type: direct:production update-type: version-update:semver-patch dependency-group: k8s - dependency-name: k8s.io/apiextensions-apiserver dependency-type: direct:production update-type: version-update:semver-patch dependency-group: k8s - dependency-name: k8s.io/cli-runtime dependency-type: direct:production update-type: version-update:semver-patch dependency-group: k8s - dependency-name: k8s.io/kubectl dependency-type: direct:production update-type: version-update:semver-patch dependency-group: k8s ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- go.mod | 16 ++++++++-------- go.sum | 32 ++++++++++++++++---------------- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/go.mod b/go.mod index 4db90349f8f..32f340ff246 100644 --- a/go.mod +++ b/go.mod @@ -52,14 +52,14 @@ require ( gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637 //pinned k8s.io to v0.26.x tag - k8s.io/api v0.26.11 - k8s.io/apiextensions-apiserver v0.26.10 - k8s.io/apimachinery v0.26.11 - k8s.io/cli-runtime v0.26.11 - k8s.io/client-go v0.26.11 - k8s.io/code-generator v0.26.11 + k8s.io/api v0.26.12 + k8s.io/apiextensions-apiserver v0.26.12 + k8s.io/apimachinery v0.26.12 + k8s.io/cli-runtime v0.26.12 + k8s.io/client-go v0.26.12 + k8s.io/code-generator v0.26.12 k8s.io/kube-openapi v0.0.0-20230109183929-3758b55a6596 - k8s.io/kubectl v0.26.11 + k8s.io/kubectl v0.26.12 k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 sigs.k8s.io/controller-runtime v0.14.7 sigs.k8s.io/yaml v1.3.0 @@ -207,7 +207,7 @@ require ( gopkg.in/kothar/go-backblaze.v0 v0.0.0-20210124194846-35409b867216 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/component-base v0.26.11 // indirect + k8s.io/component-base v0.26.12 // indirect k8s.io/gengo v0.0.0-20220902162205-c0856e24416d // indirect k8s.io/klog/v2 v2.90.1 // indirect sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect diff --git a/go.sum b/go.sum index 5b72b85043b..af886cf489d 100644 --- a/go.sum +++ b/go.sum @@ -842,23 +842,23 @@ honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= k8s.io/api v0.19.0/go.mod h1:I1K45XlvTrDjmj5LoM5LuP/KYrhWbjUKT/SoPG0qTjw= -k8s.io/api v0.26.11 h1:hLhTZRdYc3vBBOY4wbEyTLWgMyieOAk2Ws9NG57QqO4= -k8s.io/api v0.26.11/go.mod h1:bSr/A0TKRt5W2OMDdexkM/ER1NxOxiQqNNFXW2nMZrM= -k8s.io/apiextensions-apiserver v0.26.10 h1:wAriTUc6l7gUqJKOxhmXnYo/VNJzk4oh4QLCUR4Uq+k= -k8s.io/apiextensions-apiserver v0.26.10/go.mod h1:N2qhlxkhJLSoC4f0M1/1lNG627b45SYqnOPEVFoQXw4= +k8s.io/api v0.26.12 h1:jJm3s5ot05SUN3tPGg3b+XWuBE7rO/X0+dnVMhxyd5o= +k8s.io/api v0.26.12/go.mod h1:N+HUXukmtXNOKDngxXrEPbZWggWx01tH/N0nG4nV0oo= +k8s.io/apiextensions-apiserver v0.26.12 h1:WHfFheB9AM0eHZsz6wu2h/KVmZ8PM7ZAmNDr3smkUzA= +k8s.io/apiextensions-apiserver v0.26.12/go.mod h1:bvr3OVCML7icxP4rq/fJaNBPPiZ9KIi79n/icBbg5Rc= k8s.io/apimachinery v0.19.0/go.mod h1:DnPGDnARWFvYa3pMHgSxtbZb7gpzzAZ1pTfaUNDVlmA= -k8s.io/apimachinery v0.26.11 h1:w//840HHdwSRKqD15j9YX9HLlU6RPlfrvW0xEhLk2+0= -k8s.io/apimachinery v0.26.11/go.mod h1:2/HZp0l6coXtS26du1Bk36fCuAEr/lVs9Q9NbpBtd1Y= -k8s.io/cli-runtime v0.26.11 h1:HO3Sgf06XkT8/8wWnhskfz4+LMKrChRz+A13vDJSQrE= -k8s.io/cli-runtime v0.26.11/go.mod h1:D98GjQtDmqn7WDuKBgWivd6R8qEs3yzT19EmCM5pqBs= +k8s.io/apimachinery v0.26.12 h1:y+OgufxqLIZtyXIydRhjLBGzrYLF+qwiDdCFXYOjeN4= +k8s.io/apimachinery v0.26.12/go.mod h1:2/HZp0l6coXtS26du1Bk36fCuAEr/lVs9Q9NbpBtd1Y= +k8s.io/cli-runtime v0.26.12 h1:g0h59NrpXbjxokffyVQTt8j6XtZLfcqxsLiPrNE40VU= +k8s.io/cli-runtime v0.26.12/go.mod h1:g1q8WlUHIN6v1O+S9fH6gsp6vscWAL37vlMpVFbqm4I= k8s.io/client-go v0.19.0/go.mod h1:H9E/VT95blcFQnlyShFgnFT9ZnJOAceiUHM3MlRC+mU= -k8s.io/client-go v0.26.11 h1:RjfZr5+vQjjTRmk4oCqHyC0cgrZXPjw+X+ge35sk4GI= -k8s.io/client-go v0.26.11/go.mod h1:+emNszw9va/uRJIM5ALTBtFnlZMTjwBrNjRfEh0iuw8= +k8s.io/client-go v0.26.12 h1:kPpTpIeFNqwo4UyvoqzNp3DNK2mbGcdGv23eS1U8VMo= +k8s.io/client-go v0.26.12/go.mod h1:V7thEnIFroyNZOU30dKLiiVeqQmJz45shJG1mu7nONQ= k8s.io/code-generator v0.19.0/go.mod h1:moqLn7w0t9cMs4+5CQyxnfA/HV8MF6aAVENF+WZZhgk= -k8s.io/code-generator v0.26.11 h1:S0PJxapUhG6LWYezYB/FVE5Gf4BxGY0fCwnLrwfQ/70= -k8s.io/code-generator v0.26.11/go.mod h1:Hjxj7hpvSxcNnYIWzCSuEdwN0/9aHlezQRKJXr0Kv8U= -k8s.io/component-base v0.26.11 h1:1/JmB6fexefGByfFyIK6aHksZZVtaDskttzXOzmZ6zA= -k8s.io/component-base v0.26.11/go.mod h1:jYNisnoM6iWFRUg51pxaQabzL5fBYTr5CMpsLjUYGp0= +k8s.io/code-generator v0.26.12 h1:ocY1oVBBsiWvvSVldkRVBHOLL6qH+trXzyQRKj0T2Qg= +k8s.io/code-generator v0.26.12/go.mod h1:Hjxj7hpvSxcNnYIWzCSuEdwN0/9aHlezQRKJXr0Kv8U= +k8s.io/component-base v0.26.12 h1:OyYjCtruv4/Yau5Z1v6e59N+JRDTj8JnW95W9w9AMpg= +k8s.io/component-base v0.26.12/go.mod h1:X98Et5BxJ8i4TcDusUcKS8EYxCujBU1lCL3pc/CUtHQ= k8s.io/gengo v0.0.0-20200413195148-3a45101e95ac/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0= k8s.io/gengo v0.0.0-20200428234225-8167cfdcfc14/go.mod h1:ezvh/TsK7cY6rbqRK0oQQ8IAqLxYwwyPxAX1Pzy0ii0= k8s.io/gengo v0.0.0-20220902162205-c0856e24416d h1:U9tB195lKdzwqicbJvyJeOXV7Klv+wNAWENRnXEGi08= @@ -870,8 +870,8 @@ k8s.io/klog/v2 v2.90.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= k8s.io/kube-openapi v0.0.0-20200805222855-6aeccd4b50c6/go.mod h1:UuqjUnNftUyPE5H64/qeyjQoUZhGpeFDVdxjTeEVN2o= k8s.io/kube-openapi v0.0.0-20230109183929-3758b55a6596 h1:8cNCQs+WqqnSpZ7y0LMQPKD+RZUHU17VqLPMW3qxnxc= k8s.io/kube-openapi v0.0.0-20230109183929-3758b55a6596/go.mod h1:/BYxry62FuDzmI+i9B+X2pqfySRmSOW2ARmj5Zbqhj0= -k8s.io/kubectl v0.26.11 h1:cVPzYA4HKefU3tPiVK7hZpJ+5Lm04XoyvCCY5ODznpQ= -k8s.io/kubectl v0.26.11/go.mod h1:xjEX/AHtEQrGj2AGqVopyHr/JU1hLy1k7Yn48JuK9LQ= +k8s.io/kubectl v0.26.12 h1:wEPsNNHT4THWxoIYgJVhx6ok7lVnbJdJW0Pjl9QS6wc= +k8s.io/kubectl v0.26.12/go.mod h1:0O8moTv0xcYVuimWIaxRJLQY6h+e7O+cANf5jhEpW1o= k8s.io/utils v0.0.0-20200729134348-d5654de09c73/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 h1:qY1Ad8PODbnymg2pRbkyMT/ylpTrCM8P2RJ0yroCyIk= k8s.io/utils v0.0.0-20230406110748-d93618cff8a2/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= From 654951e8f48c4fee69cac1b03aa1ca26cb852818 Mon Sep 17 00:00:00 2001 From: Vivek Singh Date: Wed, 10 Jan 2024 20:04:23 +0100 Subject: [PATCH 16/17] Correct the `nodetool clearsnapshot` in cassandra bluerpint (#2596) Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- examples/cassandra/cassandra-blueprint.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/cassandra/cassandra-blueprint.yaml b/examples/cassandra/cassandra-blueprint.yaml index de6b62475d1..d1ab037ca7c 100644 --- a/examples/cassandra/cassandra-blueprint.yaml +++ b/examples/cassandra/cassandra-blueprint.yaml @@ -51,7 +51,7 @@ actions: - -c - | nodetool cleanup - nodetool clearsnapshot + nodetool clearsnapshot --all nodetool snapshot -t ${HOSTNAME} snapshot_prefix="{{ .Phases.getBackupPrefixLocation.Output.localSnapshotPrefixLocation }}" mkdir -p ${snapshot_prefix}/${HOSTNAME} @@ -62,7 +62,7 @@ actions: cd ${snapshot_prefix}/${HOSTNAME}/ cqlsh -u cassandra -p $CASSANDRA_PASSWORD -e "DESCRIBE SCHEMA" > schema.cql fi - nodetool clearsnapshot + nodetool clearsnapshot --all - func: BackupDataAll name: backupToObjectStore args: From 05ebcf95d03a297a0d78eb599aa1f06e7092cc64 Mon Sep 17 00:00:00 2001 From: InfraQ <63741182+infraq@users.noreply.github.com> Date: Wed, 10 Jan 2024 17:02:56 -0800 Subject: [PATCH 17/17] Kanister docs update to version 0.104.0 (#2572) 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 | 2 +- examples/csi-snapshot/README.md | 2 +- examples/elasticsearch/README.md | 4 ++-- .../blueprint-v2/elasticsearch-blueprint.yaml | 6 +++--- .../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/mongo-sidecar/README.md | 2 +- examples/mongodb-atlas/README.md | 4 ++-- 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 +- .../hook-blueprint/postgres-ha-hook.yaml | 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/redis/README.md | 2 +- 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 | 6 +++--- helm/profile/Chart.yaml | 2 +- pkg/app/csi-snapshot.go | 2 +- pkg/consts/consts.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/kube/pod_test.go | 16 ++++++++-------- pkg/testing/e2e_test.go | 2 +- scripts/get.sh | 2 +- 66 files changed, 142 insertions(+), 142 deletions(-) diff --git a/examples/aws-rds/postgresql/README.md b/examples/aws-rds/postgresql/README.md index e1df2cb7513..b8ce53fd83e 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.103.0 installed in your cluster +- Kanister controller version 0.104.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 989eb7b0ad4..3f1931be0be 100644 --- a/examples/aws-rds/postgresql/rds-postgres-blueprint.yaml +++ b/examples/aws-rds/postgresql/rds-postgres-blueprint.yaml @@ -14,7 +14,7 @@ actions: - func: KubeTask name: backupSnapshots args: - image: "ghcr.io/kanisterio/postgres-kanister-tools:0.103.0" + image: "ghcr.io/kanisterio/postgres-kanister-tools:0.104.0" namespace: "{{ .Object.metadata.namespace }}" command: - bash @@ -53,7 +53,7 @@ actions: - func: KubeTask name: restoreSnapshots args: - image: "ghcr.io/kanisterio/postgres-kanister-tools:0.103.0" + image: "ghcr.io/kanisterio/postgres-kanister-tools:0.104.0" namespace: "{{ .Object.metadata.namespace }}" command: - bash @@ -90,7 +90,7 @@ actions: - func: KubeTask name: restoreSnapshots args: - image: "ghcr.io/kanisterio/postgres-kanister-tools:0.103.0" + image: "ghcr.io/kanisterio/postgres-kanister-tools:0.104.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 a9364ea8fe8..97ae6c3620d 100644 --- a/examples/aws-rds/postgresql/rds-postgres-dump-blueprint.yaml +++ b/examples/aws-rds/postgresql/rds-postgres-dump-blueprint.yaml @@ -66,7 +66,7 @@ actions: name: deleteBackup args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/kanister-tools:0.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.0 command: - bash - -o diff --git a/examples/cassandra/README.md b/examples/cassandra/README.md index a71e749cacc..959495b2c4c 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.103.0 installed in your cluster, let's say in namespace `` +* Kanister controller version 0.104.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.103.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.104.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 d1ab037ca7c..0afb576a357 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.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.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 8d7ca377266..d31d45d38e2 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.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.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 e8247d9b0ff..5154259caaf 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.103.0 + image: ghcr.io/kanisterio/couchbase-tools:0.104.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.103.0 + image: ghcr.io/kanisterio/couchbase-tools:0.104.0 command: - bash - -o @@ -89,7 +89,7 @@ actions: name: deleteBackup args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/couchbase-tools:0.103.0 + image: ghcr.io/kanisterio/couchbase-tools:0.104.0 command: - bash - -o diff --git a/examples/couchbase/couchbase-blueprint.yaml b/examples/couchbase/couchbase-blueprint.yaml index 2dd0f32c4af..650b7b353f7 100644 --- a/examples/couchbase/couchbase-blueprint.yaml +++ b/examples/couchbase/couchbase-blueprint.yaml @@ -79,7 +79,7 @@ actions: name: deleteBackup args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/kanister-tools:0.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.0 command: - bash - -o diff --git a/examples/csi-snapshot/README.md b/examples/csi-snapshot/README.md index 72d6556e321..2ac15bfab75 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.103.0 installed in the cluster, let's assume in namespace `kanister` +- Kanister controller version 0.104.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 a1540261f88..39d6c98267d 100644 --- a/examples/elasticsearch/README.md +++ b/examples/elasticsearch/README.md @@ -20,7 +20,7 @@ moving on to Elasticsearch 6.0. * Kubernetes 1.20+ * PV provisioner support in the underlying infrastructure -* Kanister controller version 0.103.0 installed in your cluster +* Kanister controller version 0.104.0 installed in your cluster * Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) ## StatefulSets Details @@ -74,7 +74,7 @@ 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.103.0 + kanister/kanister-operator --set image.tag=0.104.0 ``` ### Create Profile diff --git a/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml b/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml index 88615ce8a29..42f5c730349 100644 --- a/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml +++ b/examples/elasticsearch/blueprint-v2/elasticsearch-blueprint.yaml @@ -20,7 +20,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.103.0" + image: "ghcr.io/kanisterio/es-sidecar:0.104.0" command: - bash - -o @@ -50,7 +50,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.103.0" + image: "ghcr.io/kanisterio/es-sidecar:0.104.0" command: - bash - -o @@ -75,7 +75,7 @@ actions: name: deleteFromStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/es-sidecar:0.103.0" + image: "ghcr.io/kanisterio/es-sidecar:0.104.0" command: - bash - -o diff --git a/examples/elasticsearch/elasticsearch-blueprint.yaml b/examples/elasticsearch/elasticsearch-blueprint.yaml index cbc4f6721ed..f2fbdc0fab0 100644 --- a/examples/elasticsearch/elasticsearch-blueprint.yaml +++ b/examples/elasticsearch/elasticsearch-blueprint.yaml @@ -18,7 +18,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.103.0" + image: "ghcr.io/kanisterio/es-sidecar:0.104.0" command: - bash - -o @@ -48,7 +48,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: "ghcr.io/kanisterio/es-sidecar:0.103.0" + image: "ghcr.io/kanisterio/es-sidecar:0.104.0" command: - bash - -o @@ -69,7 +69,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/es-sidecar:0.103.0" + image: "ghcr.io/kanisterio/es-sidecar:0.104.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 48dd5ec453a..ad68adb8a56 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.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -37,7 +37,7 @@ actions: - func: KubeTask name: uploadSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -55,7 +55,7 @@ actions: - func: KubeTask name: removeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -74,7 +74,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/kanister-tools:0.103.0" + image: "ghcr.io/kanisterio/kanister-tools:0.104.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 0b4da61149c..0cac3f28063 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.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -34,7 +34,7 @@ actions: - func: KubeTask name: uploadSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -50,7 +50,7 @@ actions: - func: KubeTask name: removeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -73,7 +73,7 @@ actions: - func: PrepareData name: copyFromObjectStore args: - image: "ghcr.io/kanisterio/kanister-tools:0.103.0" + image: "ghcr.io/kanisterio/kanister-tools:0.104.0" namespace: "{{ .Object.metadata.namespace }}" podOverride: nodeSelector: @@ -108,7 +108,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/kanister-tools:0.103.0" + image: "ghcr.io/kanisterio/kanister-tools:0.104.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 2ff74de8785..8b7a2ac87d0 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.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -35,7 +35,7 @@ actions: - func: KubeTask name: uploadSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -53,7 +53,7 @@ actions: - func: KubeTask name: removeSnapshot args: - image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.103.0 + image: ghcr.io/kanisterio/kanister-kubectl-1.18:0.104.0 command: - sh - -o @@ -72,7 +72,7 @@ actions: name: deleteFromObjectStore args: namespace: "{{ .Namespace.Name }}" - image: "ghcr.io/kanisterio/kanister-tools:0.103.0" + image: "ghcr.io/kanisterio/kanister-tools:0.104.0" command: - bash - -o diff --git a/examples/foundationdb/README.md b/examples/foundationdb/README.md index ad27b5ae15c..9a3f44bd677 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.103.0 with `profiles.cr.kanister.io` CRD installed. +* Kanister version 0.104.0 with `profiles.cr.kanister.io` CRD installed. * Docker CLI installed * A docker image containing the required tools to back up FoundationDB. The Dockerfile for the image can be found [here](https://raw.githubusercontent.com/kanisterio/kanister/master/docker/foundationdb/Dockerfile). diff --git a/examples/foundationdb/blueprint-v2/foundationdb-blueprint.yaml b/examples/foundationdb/blueprint-v2/foundationdb-blueprint.yaml index c4ae6d57511..cce729a869d 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.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.0 command: - bash - -o diff --git a/examples/k8ssandra/README.md b/examples/k8ssandra/README.md index 9f9a42d3ca5..8fbc92bcb0f 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.103.0 installed in your cluster +* Kanister controller version 0.104.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 247e3ad8bd9..94f20ea3046 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.103.0 installed in the cluster in a namespace . This example uses `kanister` namespace +* Kanister controller version 0.104.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 bd95065e097..0c781196e14 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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -76,7 +76,7 @@ actions: - func: KubeTask name: deleteFromStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/maria/maria-blueprint.yaml b/examples/maria/maria-blueprint.yaml index e1b101bbab7..362091da543 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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/mongo-sidecar/README.md b/examples/mongo-sidecar/README.md index 6f4fa83ae01..f1e5480e4cf 100644 --- a/examples/mongo-sidecar/README.md +++ b/examples/mongo-sidecar/README.md @@ -7,7 +7,7 @@ This is an example of using Kanister to backup and restore MongoDB. In this exam - Kubernetes 1.20+ - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.103.0 installed in your cluster, let's assume in Namespace `kanister` +- Kanister controller version 0.104.0 installed in your cluster, let's assume in Namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) diff --git a/examples/mongodb-atlas/README.md b/examples/mongodb-atlas/README.md index 67724be5312..85cbc6fd033 100644 --- a/examples/mongodb-atlas/README.md +++ b/examples/mongodb-atlas/README.md @@ -7,7 +7,7 @@ It deploys and scales a MongoDB cluster in the cloud. ## Prerequisites * Kubernetes 1.20+ -* Kanister controller version 0.103.0 installed in your cluster +* Kanister controller version 0.104.0 installed in your cluster * Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) * Already provisioned MongoDB Atlas cluster (https://www.mongodb.com/docs/atlas/getting-started) @@ -19,7 +19,7 @@ to install. ```bash $ helm repo add kanister https://charts.kanister.io $ helm install kanister --namespace kanister --create-namespace \ - kanister/kanister-operator --set image.tag=0.103.0 + kanister/kanister-operator --set image.tag=0.104.0 ``` ### Create Blueprint diff --git a/examples/mongodb-deploymentconfig/README.md b/examples/mongodb-deploymentconfig/README.md index 2d12e1bf324..c8fe7980316 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.103.0 installed in your cluster in namespace `kanister` +- Kanister controller version 0.104.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 325d0d4c055..6bd3dd24d2d 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.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -50,7 +50,7 @@ actions: namespace: "{{ .DeploymentConfig.Namespace }}" args: namespace: "{{ .DeploymentConfig.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -75,7 +75,7 @@ actions: name: deleteFromStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.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 255ee4570d7..d124b24fb74 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.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -45,7 +45,7 @@ actions: namespace: "{{ .DeploymentConfig.Namespace }}" args: namespace: "{{ .DeploymentConfig.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -66,7 +66,7 @@ actions: name: deleteFromBlobStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o diff --git a/examples/mongodb-restic/README.md b/examples/mongodb-restic/README.md index eb8d34c7151..405c3b1ebce 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.103.0 installed in your cluster +* Kanister controller version 0.104.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.103.0 + --set image.tag=0.104.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 f28d9d14338..1c177e51c12 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.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.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 a33072c2a41..679e969a7e7 100644 --- a/examples/mongodb/README.md +++ b/examples/mongodb/README.md @@ -7,7 +7,7 @@ * Kubernetes 1.20+ * Kubernetes beta APIs enabled only if `podDisruptionBudget` is enabled * PV support on the underlying infrastructure -* Kanister controller version 0.103.0 installed in your cluster +* Kanister controller version 0.104.0 installed in your cluster * Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) ## Chart Details diff --git a/examples/mongodb/blueprint-v2/mongo-blueprint.yaml b/examples/mongodb/blueprint-v2/mongo-blueprint.yaml index 8e8c61a6ddd..c109e82d2af 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.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -49,7 +49,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -74,7 +74,7 @@ actions: name: deleteFromStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o diff --git a/examples/mongodb/mongo-blueprint.yaml b/examples/mongodb/mongo-blueprint.yaml index 0127da552e9..a243c827841 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.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -44,7 +44,7 @@ actions: namespace: "{{ .StatefulSet.Namespace }}" args: namespace: "{{ .StatefulSet.Namespace }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o @@ -65,7 +65,7 @@ actions: name: deleteFromBlobStore args: namespace: "{{ .Namespace.Name }}" - image: ghcr.io/kanisterio/mongodb:0.103.0 + image: ghcr.io/kanisterio/mongodb:0.104.0 command: - bash - -o diff --git a/examples/mssql/README.md b/examples/mssql/README.md index 3503e827cd7..3ad9543f2de 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.103.0 installed in your cluster, let's assume in Namespace `kanister` +- Kanister controller version 0.104.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 0b06907f08f..124d8f30179 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.103.0 + image: ghcr.io/kanisterio/mssql-tools:0.104.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.103.0 + image: ghcr.io/kanisterio/mssql-tools:0.104.0 command: - bash - -o @@ -74,7 +74,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mssql-tools:0.103.0 + image: ghcr.io/kanisterio/mssql-tools:0.104.0 command: - bash - -o diff --git a/examples/mssql/mssql-blueprint.yaml b/examples/mssql/mssql-blueprint.yaml index 54b87625bda..4d87da8bbdd 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.103.0 + image: ghcr.io/kanisterio/mssql-tools:0.104.0 command: - bash - -o @@ -45,7 +45,7 @@ actions: - func: KubeTask name: restoreFromObjectStore args: - image: ghcr.io/kanisterio/mssql-tools:0.103.0 + image: ghcr.io/kanisterio/mssql-tools:0.104.0 command: - bash - -o @@ -71,7 +71,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mssql-tools:0.103.0 + image: ghcr.io/kanisterio/mssql-tools:0.104.0 command: - bash - -o diff --git a/examples/mysql-deploymentconfig/README.md b/examples/mysql-deploymentconfig/README.md index 3380bd5029e..c970cbc125b 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.103.0 installed in your cluster in namespace `kanister` +- Kanister controller version 0.104.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 24fa8207659..7fdc2f6d932 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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .DeploymentConfig.Namespace }}" command: - bash @@ -71,7 +71,7 @@ actions: - func: KubeTask name: deleteFromStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.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 f9501a72744..c06516e1605 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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .DeploymentConfig.Namespace }}" command: - bash @@ -63,7 +63,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/mysql/README.md b/examples/mysql/README.md index abf234f4efb..7d54a534890 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.20+ - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.103.0 installed in your cluster, let's assume in Namespace `kanister` +- Kanister controller version 0.104.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 cf1e76e5807..6b81d3433c0 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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -71,7 +71,7 @@ actions: - func: KubeTask name: deleteFromStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/mysql/mysql-blueprint.yaml b/examples/mysql/mysql-blueprint.yaml index 6a623aa9ac9..44402b41993 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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.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.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .StatefulSet.Namespace }}" command: - bash @@ -63,7 +63,7 @@ actions: - func: KubeTask name: deleteFromBlobStore args: - image: ghcr.io/kanisterio/mysql-sidecar:0.103.0 + image: ghcr.io/kanisterio/mysql-sidecar:0.104.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/postgresql-deploymentconfig/README.md b/examples/postgresql-deploymentconfig/README.md index 193f40f68da..9f9c5493776 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.103.0 installed in your cluster in namespace `kanister` +- Kanister controller version 0.104.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 d26d31b0a75..9be77a2d0f0 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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 namespace: '{{ .DeploymentConfig.Namespace }}' command: - bash @@ -75,7 +75,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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 39c2626075a..0c8823e4adc 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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 namespace: '{{ .DeploymentConfig.Namespace }}' command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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 33df3be4dcc..4a04cc5790e 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.103.0 installed in your cluster +- Kanister controller version 0.104.0 installed in your cluster - Kanctl CLI installed (https://docs.kanister.io/tooling.html#kanctl) ## Installing the Chart diff --git a/examples/postgresql-ha/hook-blueprint/postgres-ha-hook.yaml b/examples/postgresql-ha/hook-blueprint/postgres-ha-hook.yaml index b4087e7d68d..e5547355382 100644 --- a/examples/postgresql-ha/hook-blueprint/postgres-ha-hook.yaml +++ b/examples/postgresql-ha/hook-blueprint/postgres-ha-hook.yaml @@ -26,7 +26,7 @@ actions: namespace: '{{ .StatefulSet.Namespace }}' args: namespace: '{{ .StatefulSet.Namespace }}' - image: ghcr.io/kanisterio/postgres-kanister-tools:0.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 command: - bash - -o diff --git a/examples/postgresql-wale/README.md b/examples/postgresql-wale/README.md index 0f216f6911c..51feddbbaf6 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.103.0 installed in your cluster +- Kanister controller version 0.104.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.103.0 \ + --set image.tag=0.104.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.103.0 +$ helm install kanister --namespace kanister --create-namespace kanister/kanister-operator --set image.tag=0.104.0 ``` ## Integrating with Kanister diff --git a/examples/postgresql-wale/postgresql-blueprint.yaml b/examples/postgresql-wale/postgresql-blueprint.yaml index b01a35bc6a5..19e3a18da10 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.103.0" + image: "ghcr.io/kanisterio/postgresql:0.104.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.103.0" + image: "ghcr.io/kanisterio/postgresql:0.104.0" command: - bash - -o diff --git a/examples/postgresql/README.md b/examples/postgresql/README.md index 45c7534ec78..b94de6ccfdf 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.20+ - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.103.0 installed in your cluster +- Kanister controller version 0.104.0 installed in your cluster - Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) ## 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.103.0 +$ helm install kanister --namespace kanister --create-namespace kanister/kanister-operator --set image.tag=0.104.0 ``` ## Integrating with Kanister diff --git a/examples/postgresql/blueprint-v2/postgres-blueprint.yaml b/examples/postgresql/blueprint-v2/postgres-blueprint.yaml index 608a98a6c63..199ba7b4f44 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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -75,7 +75,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/postgresql/postgres-blueprint.yaml b/examples/postgresql/postgres-blueprint.yaml index 3ea67e9904e..aad7ecebbf9 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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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 6a060ff0784..6cd7fa55c86 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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.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.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 namespace: '{{ .StatefulSet.Namespace }}' command: - bash @@ -69,7 +69,7 @@ actions: - func: KubeTask name: deleteDump args: - image: ghcr.io/kanisterio/postgres-kanister-tools:0.103.0 + image: ghcr.io/kanisterio/postgres-kanister-tools:0.104.0 namespace: "{{ .Namespace.Name }}" command: - bash diff --git a/examples/redis/README.md b/examples/redis/README.md index 4fa38f7e947..74c86476501 100644 --- a/examples/redis/README.md +++ b/examples/redis/README.md @@ -11,7 +11,7 @@ We will be using [Redis](https://github.com/bitnami/charts/tree/main/bitnami/red - Kubernetes 1.20+ - PV provisioner support in the underlying infrastructure -- Kanister controller version 0.103.0 installed in your cluster, let's assume in Namespace `kanister` +- Kanister controller version 0.104.0 installed in your cluster, let's assume in Namespace `kanister` - Kanctl CLI installed (https://docs.kanister.io/tooling.html#install-the-tools) - Docker CLI installed - A docker image containing the required tools to back up Redis. The Dockerfile for the image can be found [here](https://raw.githubusercontent.com/kanisterio/kanister/master/docker/redis-tools/Dockerfile). To build and push the docker image to your docker registry, execute [these](#build-docker-image) steps. diff --git a/examples/time-log/blueprint.yaml b/examples/time-log/blueprint.yaml index 7230c11fd17..5529a4abe5c 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.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.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 b8c58b3b794..83639495cfa 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.103.0 + image: ghcr.io/kanisterio/kanister-tools:0.104.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 ea81f6c53fd..de932a1fd22 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.103.0 +appVersion: 0.104.0 source: https://github.com/kanisterio/kanister diff --git a/helm/kanister-operator/values.yaml b/helm/kanister-operator/values.yaml index 45539492fdd..70c7d0fcb55 100644 --- a/helm/kanister-operator/values.yaml +++ b/helm/kanister-operator/values.yaml @@ -3,17 +3,17 @@ # Declare variables to be passed into your templates. image: repository: ghcr.io/kanisterio/controller - tag: 0.103.0 + tag: 0.104.0 pullPolicy: IfNotPresent repositoryServerControllerImage: registry: ghcr.io/kanisterio name: repo-server-controller - tag: 0.103.0 + tag: 0.104.0 pullPolicy: IfNotPresent kanisterToolsImage: override: false image: ghcr.io/kanisterio/kanister-tools - tag: 0.103.0 + tag: 0.104.0 rbac: create: true serviceAccount: diff --git a/helm/profile/Chart.yaml b/helm/profile/Chart.yaml index 1bb614396a4..535c70ebb10 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.103.0 +version: 0.104.0 maintainers: - email: tom@kasten.io name: tdmanv diff --git a/pkg/app/csi-snapshot.go b/pkg/app/csi-snapshot.go index 8731e597c80..19b69807f69 100644 --- a/pkg/app/csi-snapshot.go +++ b/pkg/app/csi-snapshot.go @@ -192,7 +192,7 @@ func (tlc TimeLogCSI) getAppDeploymentObj() *appsv1.Deployment { Containers: []corev1.Container{ { Name: "test-container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.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: []corev1.VolumeMount{ diff --git a/pkg/consts/consts.go b/pkg/consts/consts.go index 445a9c1f3b0..c4961d9147e 100644 --- a/pkg/consts/consts.go +++ b/pkg/consts/consts.go @@ -43,7 +43,7 @@ const RepositoryServerResourceName = "repositoryserver" const RepositoryServerResourceNamePlural = "repositoryservers" const LatestKanisterToolsImage = "ghcr.io/kanisterio/kanister-tools:v9.99.9-dev" -const KanisterToolsImage = "ghcr.io/kanisterio/kanister-tools:0.103.0" +const KanisterToolsImage = "ghcr.io/kanisterio/kanister-tools:0.104.0" // KanisterToolsImageEnvName is used to set up a custom kanister-tools image const KanisterToolsImageEnvName = "KANISTER_TOOLS" diff --git a/pkg/function/data_test.go b/pkg/function/data_test.go index c0628e416a6..64254a6a27b 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.103.0", + RestoreDataImageArg: "ghcr.io/kanisterio/kanister-tools:0.104.0", RestoreDataBackupArtifactPrefixArg: "{{ .Profile.Location.Bucket }}/{{ .Profile.Location.Prefix }}", RestoreDataRestorePathArg: "/mnt/data", RestoreDataEncryptionKeyArg: "{{ .Secrets.backupKey.Data.password | toString }}", @@ -247,7 +247,7 @@ func newRestoreDataAllBlueprint() *crv1alpha1.Blueprint { Func: RestoreDataAllFuncName, Args: map[string]interface{}{ RestoreDataAllNamespaceArg: "{{ .StatefulSet.Namespace }}", - RestoreDataAllImageArg: "ghcr.io/kanisterio/kanister-tools:0.103.0", + RestoreDataAllImageArg: "ghcr.io/kanisterio/kanister-tools:0.104.0", RestoreDataAllBackupArtifactPrefixArg: "{{ .Profile.Location.Bucket }}/{{ .Profile.Location.Prefix }}", RestoreDataAllBackupInfo: fmt.Sprintf("{{ .Options.%s }}", BackupDataAllOutput), RestoreDataAllRestorePathArg: "/mnt/data", @@ -458,7 +458,7 @@ func newCopyDataTestBlueprint() crv1alpha1.Blueprint { Func: RestoreDataFuncName, Args: map[string]interface{}{ RestoreDataNamespaceArg: "{{ .PVC.Namespace }}", - RestoreDataImageArg: "ghcr.io/kanisterio/kanister-tools:0.103.0", + RestoreDataImageArg: "ghcr.io/kanisterio/kanister-tools:0.104.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 a11603fa38b..e9d718ef13b 100644 --- a/pkg/function/export_rds_snapshot_location.go +++ b/pkg/function/export_rds_snapshot_location.go @@ -64,7 +64,7 @@ const ( BackupAction RDSAction = "backup" RestoreAction RDSAction = "restore" - postgresToolsImage = "ghcr.io/kanisterio/postgres-kanister-tools:0.103.0" + postgresToolsImage = "ghcr.io/kanisterio/postgres-kanister-tools:0.104.0" ) type exportRDSSnapshotToLocationFunc struct { diff --git a/pkg/function/kube_exec_test.go b/pkg/function/kube_exec_test.go index a26594816f5..c5861b5d3de 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.103.0\"}", map[string]interface{}{"version": "0.103.0"}, IsNil, NotNil}, - {"###Phase-output###: {\"key\":\"version\",\"value\":\"0.103.0\"}\n###Phase-output###: {\"key\":\"path\",\"value\":\"/backup/path\"}", - map[string]interface{}{"version": "0.103.0", "path": "/backup/path"}, IsNil, NotNil}, - {"Random message ###Phase-output###: {\"key\":\"version\",\"value\":\"0.103.0\"}", map[string]interface{}{"version": "0.103.0"}, IsNil, NotNil}, - {"Random message with newline \n###Phase-output###: {\"key\":\"version\",\"value\":\"0.103.0\"}", map[string]interface{}{"version": "0.103.0"}, IsNil, NotNil}, + {"###Phase-output###: {\"key\":\"version\",\"value\":\"0.104.0\"}", map[string]interface{}{"version": "0.104.0"}, IsNil, NotNil}, + {"###Phase-output###: {\"key\":\"version\",\"value\":\"0.104.0\"}\n###Phase-output###: {\"key\":\"path\",\"value\":\"/backup/path\"}", + map[string]interface{}{"version": "0.104.0", "path": "/backup/path"}, IsNil, NotNil}, + {"Random message ###Phase-output###: {\"key\":\"version\",\"value\":\"0.104.0\"}", map[string]interface{}{"version": "0.104.0"}, IsNil, NotNil}, + {"Random message with newline \n###Phase-output###: {\"key\":\"version\",\"value\":\"0.104.0\"}", map[string]interface{}{"version": "0.104.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 8915c880a8a..ccc94c0f326 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.103.0", + "kando output version 0.104.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.103.0", + "version": "0.104.0", }, {}, {}, diff --git a/pkg/kube/pod_test.go b/pkg/kube/pod_test.go index 56d96b62f24..44674f3538a 100644 --- a/pkg/kube/pod_test.go +++ b/pkg/kube/pod_test.go @@ -464,7 +464,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ @@ -510,7 +510,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ @@ -550,7 +550,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ @@ -604,7 +604,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ @@ -665,7 +665,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ @@ -728,7 +728,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"echo", "override command"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ @@ -768,7 +768,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"echo", "override command"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ @@ -811,7 +811,7 @@ func (s *PodSuite) TestPatchDefaultPodSpecs(c *C) { Containers: []corev1.Container{ { Name: "container", - Image: "ghcr.io/kanisterio/kanister-tools:0.103.0", + Image: "ghcr.io/kanisterio/kanister-tools:0.104.0", Command: []string{"sh", "-c", "echo in default specs"}, ImagePullPolicy: corev1.PullPolicy(corev1.PullIfNotPresent), VolumeMounts: []corev1.VolumeMount{ diff --git a/pkg/testing/e2e_test.go b/pkg/testing/e2e_test.go index 6884f9e6ff5..08eaf933943 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.103.0", + "image": "ghcr.io/kanisterio/kanister-tools:0.104.0", "namespace": "{{ .Deployment.Namespace }}", "command": []string{"echo", "default specs"}, "podOverride": map[string]interface{}{ diff --git a/scripts/get.sh b/scripts/get.sh index 2c84727f530..7125612288d 100755 --- a/scripts/get.sh +++ b/scripts/get.sh @@ -140,7 +140,7 @@ cleanup() { } main() { - version="${1:-"0.103.0"}" + version="${1:-"0.104.0"}" initArch initOS verifySupported