Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ USAGE:

ARGS:
ssh-key-id
[name]
[name] Name of the SSH key

FLAGS:
-h, --help help for update
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ EXAMPLES:
scw instance image delete 11111111-1111-1111-1111-111111111111 zone=fr-par-1

ARGS:
image-id
image-id UUID of the image you want to delete
[with-snapshots] Delete the snapshots attached to this image
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ EXAMPLES:
scw instance image get 11111111-1111-1111-1111-111111111111 zone=fr-par-1

ARGS:
image-id
image-id UUID of the image you want to get
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ EXAMPLES:
scw instance placement-group delete 11111111-1111-1111-1111-111111111111 zone=fr-par-1

ARGS:
placement-group-id
placement-group-id UUID of the placement group you want to delete
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ EXAMPLES:
scw instance placement-group get 6c15f411-3b6f-402d-8eba-ae24ef9254e9

ARGS:
placement-group-id
placement-group-id UUID of the placement group you want to get
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ EXAMPLES:
scw instance security-group delete 69e17c83-9945-47ac-8b29-8c1ad050ee83

ARGS:
security-group-id
security-group-id UUID of the security group you want to delete
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ EXAMPLES:
scw instance security-group get a3244331-5d32-4e36-9bf9-b60233e201c7

ARGS:
security-group-id
security-group-id UUID of the security group you want to get
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ EXAMPLES:
scw instance server get 94ededdf-358d-4019-9886-d754f8a2e78d

ARGS:
server-id
server-id UUID of the server you want to get
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ EXAMPLES:
scw instance snapshot delete 11111111-1111-1111-1111-111111111111 zone=fr-par-1

ARGS:
snapshot-id
snapshot-id UUID of the snapshot you want to delete
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ EXAMPLES:
scw instance snapshot get 11111111-1111-1111-1111-111111111111 zone=fr-par-1

ARGS:
snapshot-id
snapshot-id UUID of the snapshot you want to get
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ EXAMPLES:
scw instance volume delete af136619-bc59-4b48-a0ed-ed7dceaad9a6

ARGS:
volume-id
volume-id UUID of the volume you want to delete
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ EXAMPLES:
scw instance volume get b70e9a0e-28b1-4542-bb9b-06d2d6debc0f

ARGS:
volume-id
volume-id UUID of the volume you want to get
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | nl-ams-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ USAGE:
scw rdb backup export <database-backup-id ...> [arg=value ...]

ARGS:
database-backup-id
database-backup-id UUID of the database backup you want to export
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
Get the TLS certificate of an instance.

USAGE:
scw rdb instance get-certificate <instance-id ...> [arg=value ...]

ARGS:
instance-id UUID of the instance
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams)

FLAGS:
-h, --help help for get-certificate

GLOBAL FLAGS:
-c, --config string The path to the config file
-D, --debug Enable debug mode
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
-p, --profile string The config profile to use
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
Get database instance metrics.

USAGE:
scw rdb instance get-metrics <instance-id ...> [arg=value ...]

ARGS:
instance-id UUID of the instance
[start-date] Start date to gather metrics from
[end-date] End date to gather metrics from
[metric-name] Name of the metric to gather
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams)

FLAGS:
-h, --help help for get-metrics

GLOBAL FLAGS:
-c, --config string The path to the config file
-D, --debug Enable debug mode
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
-p, --profile string The config profile to use
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ USAGE:
scw rdb instance upgrade <instance-id ...> [arg=value ...]

ARGS:
instance-id
[node-type] (DB-DEV-S | DB-DEV-M | DB-DEV-L | DB-DEV-XL | DB-GP-XS | DB-GP-S | DB-GP-M | DB-GP-L | DB-GP-XL)
[enable-ha]
instance-id UUID of the instance you want to upgrade
[node-type] Node type of the instance you want to upgrade to (DB-DEV-S | DB-DEV-M | DB-DEV-L | DB-DEV-XL | DB-GP-XS | DB-GP-S | DB-GP-M | DB-GP-L | DB-GP-XL)
[enable-ha] Set to true to enable high availability on your instance
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams)

FLAGS:
Expand Down
21 changes: 11 additions & 10 deletions cmd/scw/testdata/test-all-usage-rdb-instance-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,17 @@ USAGE:
scw rdb instance <command>

AVAILABLE COMMANDS:
clone Clone an instance
connect Connect to an instance using locally installed CLI
create Create an instance
delete Delete an instance
get Get an instance
list List instances
metrics Get instance metrics
update Update an instance
upgrade Upgrade an instance to an higher instance type
wait Wait for an instance to reach a stable state
clone Clone an instance
connect Connect to an instance using locally installed CLI
create Create an instance
delete Delete an instance
get Get an instance
get-certificate Get the TLS certificate of an instance
get-metrics Get instance metrics
list List instances
update Update an instance
upgrade Upgrade an instance to an higher instance type
wait Wait for an instance to reach a stable state

FLAGS:
-h, --help help for instance
Expand Down
1 change: 0 additions & 1 deletion cmd/scw/testdata/test-all-usage-rdb-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ USAGE:
AVAILABLE COMMANDS:
acl Access Control List (ACL) management commands
backup Backup management commands
certificate Instance TLS certificate management commands
database Database management commands
engine Database engines commands
instance Instance management commands
Expand Down
2 changes: 1 addition & 1 deletion internal/e2e/testdata/test-human-delete-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ USAGE:
scw test human delete <human-id ...> [arg=value ...]

ARGS:
human-id
human-id UUID of the human you want to delete
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)

FLAGS:
Expand Down
2 changes: 1 addition & 1 deletion internal/e2e/testdata/test-human-get-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ USAGE:
scw test human get <human-id ...> [arg=value ...]

ARGS:
human-id
human-id UUID of the human you want to get
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)

FLAGS:
Expand Down
2 changes: 1 addition & 1 deletion internal/e2e/testdata/test-human-run-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ EXAMPLES:
scw test human run xxxxx

ARGS:
human-id
human-id UUID of the human you want to make run
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par)

FLAGS:
Expand Down
2 changes: 1 addition & 1 deletion internal/e2e/testdata/test-human-update-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ USAGE:
scw test human update <human-id ...> [arg=value ...]

ARGS:
human-id
human-id UUID of the human you want to update
[height]
[shoe-size]
[altitude-in-meter]
Expand Down
1 change: 1 addition & 0 deletions internal/namespaces/account/v2alpha1/account_cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,7 @@ func accountSSHKeyUpdate() *core.Command {
},
{
Name: "name",
Short: `Name of the SSH key`,
Required: false,
Positional: false,
},
Expand Down
11 changes: 11 additions & 0 deletions internal/namespaces/instance/v1/instance_cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -441,6 +441,7 @@ func instanceServerGet() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "server-id",
Short: `UUID of the server you want to get`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -828,6 +829,7 @@ func instanceImageGet() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "image-id",
Short: `UUID of the image you want to get`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -957,6 +959,7 @@ func instanceImageDelete() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "image-id",
Short: `UUID of the image you want to delete`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1096,6 +1099,7 @@ func instanceSnapshotGet() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "snapshot-id",
Short: `UUID of the snapshot you want to get`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1133,6 +1137,7 @@ func instanceSnapshotDelete() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "snapshot-id",
Short: `UUID of the snapshot you want to delete`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1341,6 +1346,7 @@ func instanceVolumeGet() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "volume-id",
Short: `UUID of the volume you want to get`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1428,6 +1434,7 @@ func instanceVolumeDelete() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "volume-id",
Short: `UUID of the volume you want to delete`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1599,6 +1606,7 @@ func instanceSecurityGroupGet() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "security-group-id",
Short: `UUID of the security group you want to get`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1632,6 +1640,7 @@ func instanceSecurityGroupDelete() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "security-group-id",
Short: `UUID of the security group you want to delete`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1787,6 +1796,7 @@ func instancePlacementGroupGet() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "placement-group-id",
Short: `UUID of the placement group you want to get`,
Required: true,
Positional: true,
},
Expand Down Expand Up @@ -1880,6 +1890,7 @@ func instancePlacementGroupDelete() *core.Command {
ArgSpecs: core.ArgSpecs{
{
Name: "placement-group-id",
Short: `UUID of the placement group you want to delete`,
Required: true,
Positional: true,
},
Expand Down
Loading