Skip to content

Commit e7d9d8e

Browse files
authored
feat(rdb): activate encryption on existing instances (scaleway#4231)
1 parent 2c2b9e3 commit e7d9d8e

File tree

5 files changed

+12
-3
lines changed

5 files changed

+12
-3
lines changed

cmd/scw/testdata/test-all-usage-rdb-instance-upgrade-usage.golden

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ ARGS:
1414
[upgradable-version-id] Update your database engine to a newer version
1515
[major-upgrade-workflow.upgradable-version-id] Update your database engine to a newer version
1616
[major-upgrade-workflow.with-endpoints] Include endpoint during the migration
17+
[enable-encryption] Defines whether or not encryption should be enabled on the Database Instance
1718
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw)
1819

1920
FLAGS:

docs/commands/rdb.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -992,6 +992,7 @@ scw rdb instance upgrade <instance-id ...> [arg=value ...]
992992
| upgradable-version-id | | Update your database engine to a newer version |
993993
| major-upgrade-workflow.upgradable-version-id | | Update your database engine to a newer version |
994994
| major-upgrade-workflow.with-endpoints | | Include endpoint during the migration |
995+
| enable-encryption | | Defines whether or not encryption should be enabled on the Database Instance |
995996
| region | Default: `fr-par`<br />One of: `fr-par`, `nl-ams`, `pl-waw` | Region to target. If none is passed will use default region from the config |
996997

997998

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ require (
2626
github.com/mattn/go-isatty v0.0.20
2727
github.com/moby/buildkit v0.13.2
2828
github.com/opencontainers/go-digest v1.0.0
29-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241025112925-105ce0f288e4
29+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241025151430-736ebc291485
3030
github.com/skratchdot/open-golang v0.0.0-20200116055534-eef842397966
3131
github.com/spf13/cobra v1.8.1
3232
github.com/spf13/pflag v1.0.5

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -465,8 +465,8 @@ github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUz
465465
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
466466
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06 h1:OkMGxebDjyw0ULyrTYWeN0UNCCkmCWfjPnIA2W6oviI=
467467
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06/go.mod h1:+ePHsJ1keEjQtpvf9HHw0f4ZeJ0TLRsxhunSI2hYJSs=
468-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241025112925-105ce0f288e4 h1:2pEfSGb8zVgPgS1sQHMeJX+TaMMMkeldFjqR/J7ZZyI=
469-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241025112925-105ce0f288e4/go.mod h1:3jrRJM7638J+P33hKy9MBvfOBxNo8pEGNQQoIv65Ihg=
468+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241025151430-736ebc291485 h1:pio5yJbu5NPDTB4qRsQTf/w/9XwBZS/Vud0oXqVAZIA=
469+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241025151430-736ebc291485/go.mod h1:3jrRJM7638J+P33hKy9MBvfOBxNo8pEGNQQoIv65Ihg=
470470
github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8=
471471
github.com/sclevine/spec v1.4.0/go.mod h1:LvpgJaFyvQzRvc1kaDs0bulYwzC70PbiYjC4QnFHkOM=
472472
github.com/secure-systems-lab/go-securesystemslib v0.8.0 h1:mr5An6X45Kb2nddcFlbmfHkLguCE9laoZCUzEEpIZXA=

internal/namespaces/rdb/v1/rdb_cli.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -702,6 +702,13 @@ func rdbInstanceUpgrade() *core.Command {
702702
Deprecated: false,
703703
Positional: false,
704704
},
705+
{
706+
Name: "enable-encryption",
707+
Short: `Defines whether or not encryption should be enabled on the Database Instance`,
708+
Required: false,
709+
Deprecated: false,
710+
Positional: false,
711+
},
705712
core.RegionArgSpec(scw.RegionFrPar, scw.RegionNlAms, scw.RegionPlWaw),
706713
},
707714
Run: func(ctx context.Context, args interface{}) (i interface{}, e error) {

0 commit comments

Comments
 (0)