Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: update generated APIs #2515

Merged
merged 1 commit into from
Sep 19, 2022
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
2 changes: 1 addition & 1 deletion cmd/scw/testdata/test-all-usage-config-set-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ ARGS:
[default-organization-id] A default Scaleway organization id
[default-project-id] A default Scaleway project id
[default-region] A default Scaleway region (fr-par | nl-ams | pl-waw)
[default-zone] A default Scaleway zone (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | pl-waw-1)
[default-zone] A default Scaleway zone (fr-par-1 | fr-par-2 | fr-par-3 | nl-ams-1 | nl-ams-2 | pl-waw-1 | pl-waw-2)
[send-telemetry] Set to false to disable telemetry

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ ARGS:
[pools.{index}.container-runtime] The container runtime for the nodes of the pool (unknown_runtime | docker | containerd | crio)
[pools.{index}.autohealing] The enablement of the autohealing feature for the pool
[pools.{index}.tags.{index}] The tags associated with the pool
[pools.{index}.kubelet-args.{key}]
[pools.{index}.kubelet-args.{key}] The Kubelet arguments to be used by this pool. Note that this feature is to be considered as experimental
[pools.{index}.upgrade-policy.max-unavailable] The maximum number of nodes that can be not ready at the same time
[pools.{index}.upgrade-policy.max-surge] The maximum number of nodes to be created during the upgrade
[pools.{index}.zone] The Zone in which the Pool's node will be spawn in
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ ARGS:
[container-runtime] The container runtime for the nodes of the pool (unknown_runtime | docker | containerd | crio)
[autohealing] The enablement of the autohealing feature for the pool
[tags.{index}] The tags associated with the pool
[kubelet-args.{key}]
[kubelet-args.{key}] The Kubelet arguments to be used by this pool. Note that this feature is to be considered as experimental
[upgrade-policy.max-unavailable]
[upgrade-policy.max-surge]
[zone] The Zone in which the Pool's node will be spawn in
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
Delete a DHCP configuration.

USAGE:
scw vpc-gw dhcp delete <dhcpid ...> [arg=value ...]
scw vpc-gw dhcp delete <dhcp-id ...> [arg=value ...]

ARGS:
dhcpid DHCP config id to delete
dhcp-id DHCP config id to delete
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | nl-ams-1 | pl-waw-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
Get a DHCP configuration.

USAGE:
scw vpc-gw dhcp get <dhcpid ...> [arg=value ...]
scw vpc-gw dhcp get <dhcp-id ...> [arg=value ...]

ARGS:
dhcpid ID of the DHCP config to fetch
dhcp-id ID of the DHCP config to fetch
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | nl-ams-1 | pl-waw-1)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
Update a DHCP configuration.

USAGE:
scw vpc-gw dhcp update <dhcpid ...> [arg=value ...]
scw vpc-gw dhcp update <dhcp-id ...> [arg=value ...]

ARGS:
dhcpid DHCP config to update
dhcp-id DHCP config to update
[subnet] Subnet for the DHCP server
[address] Address of the DHCP server. This will be the gateway's address in the private network
[pool-low] Low IP (included) of the dynamic address pool
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ ARGS:
[gateway-id] Gateway to connect
[private-network-id] Private Network to connect
[enable-masquerade] Whether to enable masquerade on this network
[dhcpid] Existing configuration
[dhcp-id] Existing configuration
[address] Static IP address in CIDR format to to use without DHCP
[enable-dhcp] Whether to enable DHCP on this Private Network
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | nl-ams-1 | pl-waw-1)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ARGS:
[gateway-id] Filter by gateway
[private-network-id] Filter by private network
[enable-masquerade] Filter by masquerade enablement
[dhcpid] Filter by DHCP configuration
[dhcp-id] Filter by DHCP configuration
[status] Filter GatewayNetworks by this status (unknown for any) (unknown | created | attaching | configuring | ready | detaching | deleted)
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | nl-ams-1 | pl-waw-1)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ USAGE:
ARGS:
gateway-network-id ID of the GatewayNetwork to update
[enable-masquerade] New masquerade enablement
[dhcpid] New DHCP configuration
[dhcp-id] New DHCP configuration
[enable-dhcp] Whether to enable DHCP on the connected Private Network
[address] New static IP address
[zone=fr-par-1] Zone to target. If none is passed will use default zone from the config (fr-par-1 | fr-par-2 | nl-ams-1 | pl-waw-1)
Expand Down
2 changes: 1 addition & 1 deletion docs/commands/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ scw config set [arg=value ...]
| default-organization-id | | A default Scaleway organization id |
| default-project-id | | A default Scaleway project id |
| default-region | One of: `fr-par`, `nl-ams`, `pl-waw` | A default Scaleway region |
| default-zone | One of: `fr-par-1`, `fr-par-2`, `fr-par-3`, `nl-ams-1`, `nl-ams-2`, `pl-waw-1` | A default Scaleway zone |
| default-zone | One of: `fr-par-1`, `fr-par-2`, `fr-par-3`, `nl-ams-1`, `nl-ams-2`, `pl-waw-1`, `pl-waw-2` | A default Scaleway zone |
| send-telemetry | | Set to false to disable telemetry |


Expand Down
4 changes: 2 additions & 2 deletions docs/commands/k8s.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ scw k8s cluster create [arg=value ...]
| pools.{index}.container-runtime | One of: `unknown_runtime`, `docker`, `containerd`, `crio` | The container runtime for the nodes of the pool |
| pools.{index}.autohealing | | The enablement of the autohealing feature for the pool |
| pools.{index}.tags.{index} | | The tags associated with the pool |
| pools.{index}.kubelet-args.{key} | | |
| pools.{index}.kubelet-args.{key} | | The Kubelet arguments to be used by this pool. Note that this feature is to be considered as experimental |
| pools.{index}.upgrade-policy.max-unavailable | | The maximum number of nodes that can be not ready at the same time |
| pools.{index}.upgrade-policy.max-surge | | The maximum number of nodes to be created during the upgrade |
| pools.{index}.zone | | The Zone in which the Pool's node will be spawn in |
Expand Down Expand Up @@ -769,7 +769,7 @@ scw k8s pool create [arg=value ...]
| container-runtime | One of: `unknown_runtime`, `docker`, `containerd`, `crio` | The container runtime for the nodes of the pool |
| autohealing | | The enablement of the autohealing feature for the pool |
| tags.{index} | | The tags associated with the pool |
| kubelet-args.{key} | | |
| kubelet-args.{key} | | The Kubelet arguments to be used by this pool. Note that this feature is to be considered as experimental |
| upgrade-policy.max-unavailable | | |
| upgrade-policy.max-surge | | |
| zone | | The Zone in which the Pool's node will be spawn in |
Expand Down
18 changes: 9 additions & 9 deletions docs/commands/vpc-gw.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,15 +94,15 @@ Delete a DHCP configuration.
**Usage:**

```
scw vpc-gw dhcp delete <dhcpid ...> [arg=value ...]
scw vpc-gw dhcp delete <dhcp-id ...> [arg=value ...]
```


**Args:**

| Name | | Description |
|------|---|-------------|
| dhcpid | Required | DHCP config id to delete |
| dhcp-id | Required | DHCP config id to delete |
| zone | Default: `fr-par-1`<br />One of: `fr-par-1`, `fr-par-2`, `nl-ams-1`, `pl-waw-1` | Zone to target. If none is passed will use default zone from the config |


Expand All @@ -114,15 +114,15 @@ Get a DHCP configuration.
**Usage:**

```
scw vpc-gw dhcp get <dhcpid ...> [arg=value ...]
scw vpc-gw dhcp get <dhcp-id ...> [arg=value ...]
```


**Args:**

| Name | | Description |
|------|---|-------------|
| dhcpid | Required | ID of the DHCP config to fetch |
| dhcp-id | Required | ID of the DHCP config to fetch |
| zone | Default: `fr-par-1`<br />One of: `fr-par-1`, `fr-par-2`, `nl-ams-1`, `pl-waw-1` | Zone to target. If none is passed will use default zone from the config |


Expand Down Expand Up @@ -158,15 +158,15 @@ Update a DHCP configuration.
**Usage:**

```
scw vpc-gw dhcp update <dhcpid ...> [arg=value ...]
scw vpc-gw dhcp update <dhcp-id ...> [arg=value ...]
```


**Args:**

| Name | | Description |
|------|---|-------------|
| dhcpid | Required | DHCP config to update |
| dhcp-id | Required | DHCP config to update |
| subnet | | Subnet for the DHCP server |
| address | | Address of the DHCP server. This will be the gateway's address in the private network |
| pool-low | | Low IP (included) of the dynamic address pool |
Expand Down Expand Up @@ -496,7 +496,7 @@ scw vpc-gw gateway-network create [arg=value ...]
| gateway-id | | Gateway to connect |
| private-network-id | | Private Network to connect |
| enable-masquerade | | Whether to enable masquerade on this network |
| dhcpid | | Existing configuration |
| dhcp-id | | Existing configuration |
| address | | Static IP address in CIDR format to to use without DHCP |
| enable-dhcp | | Whether to enable DHCP on this Private Network |
| zone | Default: `fr-par-1`<br />One of: `fr-par-1`, `fr-par-2`, `nl-ams-1`, `pl-waw-1` | Zone to target. If none is passed will use default zone from the config |
Expand Down Expand Up @@ -563,7 +563,7 @@ scw vpc-gw gateway-network list [arg=value ...]
| gateway-id | | Filter by gateway |
| private-network-id | | Filter by private network |
| enable-masquerade | | Filter by masquerade enablement |
| dhcpid | | Filter by DHCP configuration |
| dhcp-id | | Filter by DHCP configuration |
| status | One of: `unknown`, `created`, `attaching`, `configuring`, `ready`, `detaching`, `deleted` | Filter GatewayNetworks by this status (unknown for any) |
| zone | Default: `fr-par-1`<br />One of: `fr-par-1`, `fr-par-2`, `nl-ams-1`, `pl-waw-1` | Zone to target. If none is passed will use default zone from the config |

Expand All @@ -586,7 +586,7 @@ scw vpc-gw gateway-network update <gateway-network-id ...> [arg=value ...]
|------|---|-------------|
| gateway-network-id | Required | ID of the GatewayNetwork to update |
| enable-masquerade | | New masquerade enablement |
| dhcpid | | New DHCP configuration |
| dhcp-id | | New DHCP configuration |
| enable-dhcp | | Whether to enable DHCP on the connected Private Network |
| address | | New static IP address |
| zone | Default: `fr-par-1`<br />One of: `fr-par-1`, `fr-par-2`, `nl-ams-1`, `pl-waw-1` | Zone to target. If none is passed will use default zone from the config |
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -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.9.0.20220912091438-7eb3f47b338d
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.9.0.20220919083933-2acf59344918
github.com/spf13/cobra v1.5.0
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.8.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -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.9.0.20220912091438-7eb3f47b338d h1:bm9Vc3dz8oHAZTf9XoO6hRkv1CcOZLFbxT1pGok551k=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.9.0.20220912091438-7eb3f47b338d/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.9.0.20220919083933-2acf59344918 h1:fIicsimHAwEvkoQrnyW5b72MIYw+bJnkvSIAd7Qz4VI=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.9.0.20220919083933-2acf59344918/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.5.0 h1:X+jTBEBqF0bHN+9cSMgmfuvv2VHJ9ezmFNf9Y/XstYU=
Expand Down
2 changes: 2 additions & 0 deletions internal/namespaces/k8s/v1/k8s_cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -374,6 +374,7 @@ func k8sClusterCreate() *core.Command {
},
{
Name: "pools.{index}.kubelet-args.{key}",
Short: `The Kubelet arguments to be used by this pool. Note that this feature is to be considered as experimental`,
Required: false,
Deprecated: false,
Positional: false,
Expand Down Expand Up @@ -1292,6 +1293,7 @@ func k8sPoolCreate() *core.Command {
},
{
Name: "kubelet-args.{key}",
Short: `The Kubelet arguments to be used by this pool. Note that this feature is to be considered as experimental`,
Required: false,
Deprecated: false,
Positional: false,
Expand Down
12 changes: 6 additions & 6 deletions internal/namespaces/vpcgw/v1/vpcgw_cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ func vpcGwGatewayNetworkList() *core.Command {
Positional: false,
},
{
Name: "dhcpid",
Name: "dhcp-id",
Short: `Filter by DHCP configuration`,
Required: false,
Deprecated: false,
Expand Down Expand Up @@ -686,7 +686,7 @@ func vpcGwGatewayNetworkCreate() *core.Command {
Positional: false,
},
{
Name: "dhcpid",
Name: "dhcp-id",
Short: `Existing configuration`,
Required: false,
Deprecated: false,
Expand Down Expand Up @@ -744,7 +744,7 @@ func vpcGwGatewayNetworkUpdate() *core.Command {
Positional: false,
},
{
Name: "dhcpid",
Name: "dhcp-id",
Short: `New DHCP configuration`,
Required: false,
Deprecated: false,
Expand Down Expand Up @@ -953,7 +953,7 @@ func vpcGwDHCPGet() *core.Command {
ArgsType: reflect.TypeOf(vpcgw.GetDHCPRequest{}),
ArgSpecs: core.ArgSpecs{
{
Name: "dhcpid",
Name: "dhcp-id",
Short: `ID of the DHCP config to fetch`,
Required: true,
Deprecated: false,
Expand Down Expand Up @@ -1113,7 +1113,7 @@ func vpcGwDHCPUpdate() *core.Command {
ArgsType: reflect.TypeOf(vpcgw.UpdateDHCPRequest{}),
ArgSpecs: core.ArgSpecs{
{
Name: "dhcpid",
Name: "dhcp-id",
Short: `DHCP config to update`,
Required: true,
Deprecated: false,
Expand Down Expand Up @@ -1249,7 +1249,7 @@ func vpcGwDHCPDelete() *core.Command {
ArgsType: reflect.TypeOf(vpcgw.DeleteDHCPRequest{}),
ArgSpecs: core.ArgSpecs{
{
Name: "dhcpid",
Name: "dhcp-id",
Short: `DHCP config id to delete`,
Required: true,
Deprecated: false,
Expand Down