diff --git a/cmd/scw/testdata/test-all-usage-instance-private-nic-create-usage.golden b/cmd/scw/testdata/test-all-usage-instance-private-nic-create-usage.golden index 63356081e6..e57c46cb51 100644 --- a/cmd/scw/testdata/test-all-usage-instance-private-nic-create-usage.golden +++ b/cmd/scw/testdata/test-all-usage-instance-private-nic-create-usage.golden @@ -6,9 +6,9 @@ USAGE: scw instance private-nic create [arg=value ...] ARGS: - server-id - [private-network-id] - [zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | pl-waw-1 | pl-waw-2) + server-id UUID of the server the private NIC will be attached to + private-network-id UUID of the private network where the private NIC will be attached + [zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | pl-waw-1 | pl-waw-2) FLAGS: -h, --help help for create diff --git a/cmd/scw/testdata/test-all-usage-instance-private-nic-delete-usage.golden b/cmd/scw/testdata/test-all-usage-instance-private-nic-delete-usage.golden index 411c010b3c..1aada8d0ea 100644 --- a/cmd/scw/testdata/test-all-usage-instance-private-nic-delete-usage.golden +++ b/cmd/scw/testdata/test-all-usage-instance-private-nic-delete-usage.golden @@ -6,8 +6,8 @@ USAGE: scw instance private-nic delete [arg=value ...] ARGS: - server-id - private-nic-id + server-id The server the private NIC is attached to + private-nic-id The private NIC unique ID [zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | pl-waw-1 | pl-waw-2) FLAGS: diff --git a/cmd/scw/testdata/test-all-usage-instance-private-nic-get-usage.golden b/cmd/scw/testdata/test-all-usage-instance-private-nic-get-usage.golden index f8dab11613..75892a4396 100644 --- a/cmd/scw/testdata/test-all-usage-instance-private-nic-get-usage.golden +++ b/cmd/scw/testdata/test-all-usage-instance-private-nic-get-usage.golden @@ -6,8 +6,8 @@ USAGE: scw instance private-nic get [arg=value ...] ARGS: - server-id - private-nic-id + server-id The server the private NIC is attached to + private-nic-id The private NIC unique ID [zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | pl-waw-1 | pl-waw-2) FLAGS: diff --git a/cmd/scw/testdata/test-all-usage-instance-private-nic-list-usage.golden b/cmd/scw/testdata/test-all-usage-instance-private-nic-list-usage.golden index e87193475e..953d32c7b2 100644 --- a/cmd/scw/testdata/test-all-usage-instance-private-nic-list-usage.golden +++ b/cmd/scw/testdata/test-all-usage-instance-private-nic-list-usage.golden @@ -13,7 +13,7 @@ EXAMPLES: scw instance private-nic list server-id=my_server_id ARGS: - server-id + server-id The server the private NIC is attached to [zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | pl-waw-1 | pl-waw-2) FLAGS: diff --git a/docs/commands/instance.md b/docs/commands/instance.md index 2dc1493aee..d51d7b418d 100644 --- a/docs/commands/instance.md +++ b/docs/commands/instance.md @@ -845,8 +845,8 @@ scw instance private-nic create [arg=value ...] | Name | | Description | |------|---|-------------| -| server-id | Required | | -| private-network-id | | | +| server-id | Required | UUID of the server the private NIC will be attached to | +| private-network-id | Required | UUID of the private network where the private NIC will be attached | | zone | Default: `fr-par-1`
One of: `fr-par-1`, `fr-par-2`, `fr-par-3`, `nl-ams-1`, `nl-ams-2`, `pl-waw-1`, `pl-waw-2` | Zone to target. If none is passed will use default zone from the config | @@ -866,8 +866,8 @@ scw instance private-nic delete [arg=value ...] | Name | | Description | |------|---|-------------| -| server-id | Required | | -| private-nic-id | Required | | +| server-id | Required | The server the private NIC is attached to | +| private-nic-id | Required | The private NIC unique ID | | zone | Default: `fr-par-1`
One of: `fr-par-1`, `fr-par-2`, `fr-par-3`, `nl-ams-1`, `nl-ams-2`, `pl-waw-1`, `pl-waw-2` | Zone to target. If none is passed will use default zone from the config | @@ -887,8 +887,8 @@ scw instance private-nic get [arg=value ...] | Name | | Description | |------|---|-------------| -| server-id | Required | | -| private-nic-id | Required | | +| server-id | Required | The server the private NIC is attached to | +| private-nic-id | Required | The private NIC unique ID | | zone | Default: `fr-par-1`
One of: `fr-par-1`, `fr-par-2`, `fr-par-3`, `nl-ams-1`, `nl-ams-2`, `pl-waw-1`, `pl-waw-2` | Zone to target. If none is passed will use default zone from the config | @@ -908,7 +908,7 @@ scw instance private-nic list [arg=value ...] | Name | | Description | |------|---|-------------| -| server-id | Required | | +| server-id | Required | The server the private NIC is attached to | | zone | Default: `fr-par-1`
One of: `fr-par-1`, `fr-par-2`, `fr-par-3`, `nl-ams-1`, `nl-ams-2`, `pl-waw-1`, `pl-waw-2` | Zone to target. If none is passed will use default zone from the config | diff --git a/go.mod b/go.mod index 551b4d6206..7436b8c71a 100644 --- a/go.mod +++ b/go.mod @@ -18,7 +18,7 @@ require ( github.com/kubernetes-client/go-base v0.0.0-20190205182333-3d0e39759d98 github.com/mattn/go-colorable v0.1.13 github.com/mattn/go-isatty v0.0.16 - github.com/scaleway/scaleway-sdk-go v1.0.0-beta.10.0.20221226150403-e0f006954fd8 + github.com/scaleway/scaleway-sdk-go v1.0.0-beta.10.0.20221228142400-b21744e9949a github.com/spf13/cobra v1.6.1 github.com/spf13/pflag v1.0.5 github.com/stretchr/testify v1.8.1 diff --git a/go.sum b/go.sum index 0900d5db00..763a2b91f2 100644 --- a/go.sum +++ b/go.sum @@ -71,8 +71,8 @@ github.com/pkg/term v1.1.0/go.mod h1:E25nymQcrSllhX42Ok8MRm1+hyBdHY0dCeiKZ9jpNGw github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/scaleway/scaleway-sdk-go v1.0.0-beta.10.0.20221226150403-e0f006954fd8 h1:HvVzojcSGcZf7YZ2mtkZ1uoTyGolfiynND+NDuF7Ht4= -github.com/scaleway/scaleway-sdk-go v1.0.0-beta.10.0.20221226150403-e0f006954fd8/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg= +github.com/scaleway/scaleway-sdk-go v1.0.0-beta.10.0.20221228142400-b21744e9949a h1:AN3KX9UupxrBlNe6YE5SUE2IP2jNdy47OyT2Pvv+2mc= +github.com/scaleway/scaleway-sdk-go v1.0.0-beta.10.0.20221228142400-b21744e9949a/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg= github.com/sergi/go-diff v1.2.0 h1:XU+rvMAioB0UC3q1MFrIQy4Vo5/4VsRDQQXHsEya6xQ= github.com/sergi/go-diff v1.2.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= github.com/spf13/cobra v1.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA= diff --git a/internal/namespaces/instance/v1/instance_cli.go b/internal/namespaces/instance/v1/instance_cli.go index 9f67c13d36..03b83d82bd 100644 --- a/internal/namespaces/instance/v1/instance_cli.go +++ b/internal/namespaces/instance/v1/instance_cli.go @@ -2709,6 +2709,7 @@ func instancePrivateNicList() *core.Command { ArgSpecs: core.ArgSpecs{ { Name: "server-id", + Short: `The server the private NIC is attached to`, Required: true, Deprecated: false, Positional: false, @@ -2748,13 +2749,15 @@ func instancePrivateNicCreate() *core.Command { ArgSpecs: core.ArgSpecs{ { Name: "server-id", + Short: `UUID of the server the private NIC will be attached to`, Required: true, Deprecated: false, Positional: false, }, { Name: "private-network-id", - Required: false, + Short: `UUID of the private network where the private NIC will be attached`, + Required: true, Deprecated: false, Positional: false, }, @@ -2783,12 +2786,14 @@ func instancePrivateNicGet() *core.Command { ArgSpecs: core.ArgSpecs{ { Name: "server-id", + Short: `The server the private NIC is attached to`, Required: true, Deprecated: false, Positional: false, }, { Name: "private-nic-id", + Short: `The private NIC unique ID`, Required: true, Deprecated: false, Positional: false, @@ -2818,12 +2823,14 @@ func instancePrivateNicDelete() *core.Command { ArgSpecs: core.ArgSpecs{ { Name: "server-id", + Short: `The server the private NIC is attached to`, Required: true, Deprecated: false, Positional: false, }, { Name: "private-nic-id", + Short: `The private NIC unique ID`, Required: true, Deprecated: false, Positional: false,