Skip to content

Commit 6e4c086

Browse files
authored
feat(ipam): add apple silicon resource types (#4300)
1 parent 2dfab68 commit 6e4c086

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

cmd/scw/testdata/test-all-usage-ipam-ip-list-usage.golden

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ ARGS:
1414
[vpc-id] VPC ID to filter for.
1515
[attached] Defines whether to filter only for IPs which are attached to a resource
1616
[resource-id] Resource ID to filter for. Only IPs attached to this resource will be returned
17-
[resource-type] Resource type to filter for. Only IPs attached to this type of resource will be returned (unknown_type | custom | instance_server | instance_ip | instance_private_nic | lb_server | fip_ip | vpc_gateway | vpc_gateway_network | k8s_node | k8s_cluster | rdb_instance | redis_cluster | baremetal_server | baremetal_private_nic | llm_deployment | mgdb_instance)
17+
[resource-type] Resource type to filter for. Only IPs attached to this type of resource will be returned (unknown_type | custom | instance_server | instance_ip | instance_private_nic | lb_server | fip_ip | vpc_gateway | vpc_gateway_network | k8s_node | k8s_cluster | rdb_instance | redis_cluster | baremetal_server | baremetal_private_nic | llm_deployment | mgdb_instance | apple_silicon_server | apple_silicon_private_nic)
1818
[mac-address] MAC address to filter for. Only IPs attached to a resource with this MAC address will be returned
1919
[tags.{index}] Tags to filter for, only IPs with one or more matching tags will be returned
2020
[is-ipv6] Defines whether to filter only for IPv4s or IPv6s
2121
[resource-name] Attached resource name to filter for, only IPs attached to a resource with this string within their name will be returned.
22-
[resource-types.{index}] Resource types to filter for. Only IPs attached to these types of resources will be returned (unknown_type | custom | instance_server | instance_ip | instance_private_nic | lb_server | fip_ip | vpc_gateway | vpc_gateway_network | k8s_node | k8s_cluster | rdb_instance | redis_cluster | baremetal_server | baremetal_private_nic | llm_deployment | mgdb_instance)
22+
[resource-types.{index}] Resource types to filter for. Only IPs attached to these types of resources will be returned (unknown_type | custom | instance_server | instance_ip | instance_private_nic | lb_server | fip_ip | vpc_gateway | vpc_gateway_network | k8s_node | k8s_cluster | rdb_instance | redis_cluster | baremetal_server | baremetal_private_nic | llm_deployment | mgdb_instance | apple_silicon_server | apple_silicon_private_nic)
2323
[organization-id] Organization ID to filter for. Only IPs belonging to this Organization will be returned
2424
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw | all)
2525

docs/commands/ipam.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -108,12 +108,12 @@ scw ipam ip list [arg=value ...]
108108
| vpc-id | | VPC ID to filter for. |
109109
| attached | | Defines whether to filter only for IPs which are attached to a resource |
110110
| resource-id | | Resource ID to filter for. Only IPs attached to this resource will be returned |
111-
| resource-type | One of: `unknown_type`, `custom`, `instance_server`, `instance_ip`, `instance_private_nic`, `lb_server`, `fip_ip`, `vpc_gateway`, `vpc_gateway_network`, `k8s_node`, `k8s_cluster`, `rdb_instance`, `redis_cluster`, `baremetal_server`, `baremetal_private_nic`, `llm_deployment`, `mgdb_instance` | Resource type to filter for. Only IPs attached to this type of resource will be returned |
111+
| resource-type | One of: `unknown_type`, `custom`, `instance_server`, `instance_ip`, `instance_private_nic`, `lb_server`, `fip_ip`, `vpc_gateway`, `vpc_gateway_network`, `k8s_node`, `k8s_cluster`, `rdb_instance`, `redis_cluster`, `baremetal_server`, `baremetal_private_nic`, `llm_deployment`, `mgdb_instance`, `apple_silicon_server`, `apple_silicon_private_nic` | Resource type to filter for. Only IPs attached to this type of resource will be returned |
112112
| mac-address | | MAC address to filter for. Only IPs attached to a resource with this MAC address will be returned |
113113
| tags.{index} | | Tags to filter for, only IPs with one or more matching tags will be returned |
114114
| is-ipv6 | | Defines whether to filter only for IPv4s or IPv6s |
115115
| resource-name | | Attached resource name to filter for, only IPs attached to a resource with this string within their name will be returned. |
116-
| resource-types.{index} | One of: `unknown_type`, `custom`, `instance_server`, `instance_ip`, `instance_private_nic`, `lb_server`, `fip_ip`, `vpc_gateway`, `vpc_gateway_network`, `k8s_node`, `k8s_cluster`, `rdb_instance`, `redis_cluster`, `baremetal_server`, `baremetal_private_nic`, `llm_deployment`, `mgdb_instance` | Resource types to filter for. Only IPs attached to these types of resources will be returned |
116+
| resource-types.{index} | One of: `unknown_type`, `custom`, `instance_server`, `instance_ip`, `instance_private_nic`, `lb_server`, `fip_ip`, `vpc_gateway`, `vpc_gateway_network`, `k8s_node`, `k8s_cluster`, `rdb_instance`, `redis_cluster`, `baremetal_server`, `baremetal_private_nic`, `llm_deployment`, `mgdb_instance`, `apple_silicon_server`, `apple_silicon_private_nic` | Resource types to filter for. Only IPs attached to these types of resources will be returned |
117117
| organization-id | | Organization ID to filter for. Only IPs belonging to this Organization will be returned |
118118
| region | Default: `fr-par`<br />One of: `fr-par`, `nl-ams`, `pl-waw`, `all` | Region to target. If none is passed will use default region from the config |
119119

go.mod

+1-1
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.20241122155133-e059a3142116
29+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241125164945-94736bc9e407
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

+2-2
Original file line numberDiff line numberDiff line change
@@ -466,8 +466,8 @@ github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUz
466466
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
467467
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06 h1:OkMGxebDjyw0ULyrTYWeN0UNCCkmCWfjPnIA2W6oviI=
468468
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06/go.mod h1:+ePHsJ1keEjQtpvf9HHw0f4ZeJ0TLRsxhunSI2hYJSs=
469-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241122155133-e059a3142116 h1:cMGaFcZ2ByIdOWy/QkRvMOu0HtwzQDLv+InToiqJPaM=
470-
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241122155133-e059a3142116/go.mod h1:kAoejOVBg1E/aVAR6IwKWEmbLCEg2IXklzPAkxzAaXA=
469+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241125164945-94736bc9e407 h1:fKdvTL5Uf2Yz9HuTkXvEXWIdYiwQN5e6Rx5n/R/E/Vg=
470+
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.30.0.20241125164945-94736bc9e407/go.mod h1:kAoejOVBg1E/aVAR6IwKWEmbLCEg2IXklzPAkxzAaXA=
471471
github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8=
472472
github.com/sclevine/spec v1.4.0/go.mod h1:LvpgJaFyvQzRvc1kaDs0bulYwzC70PbiYjC4QnFHkOM=
473473
github.com/secure-systems-lab/go-securesystemslib v0.8.0 h1:mr5An6X45Kb2nddcFlbmfHkLguCE9laoZCUzEEpIZXA=

internal/namespaces/ipam/v1/ipam_cli.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,7 @@ func ipamIPList() *core.Command {
361361
Required: false,
362362
Deprecated: false,
363363
Positional: false,
364-
EnumValues: []string{"unknown_type", "custom", "instance_server", "instance_ip", "instance_private_nic", "lb_server", "fip_ip", "vpc_gateway", "vpc_gateway_network", "k8s_node", "k8s_cluster", "rdb_instance", "redis_cluster", "baremetal_server", "baremetal_private_nic", "llm_deployment", "mgdb_instance"},
364+
EnumValues: []string{"unknown_type", "custom", "instance_server", "instance_ip", "instance_private_nic", "lb_server", "fip_ip", "vpc_gateway", "vpc_gateway_network", "k8s_node", "k8s_cluster", "rdb_instance", "redis_cluster", "baremetal_server", "baremetal_private_nic", "llm_deployment", "mgdb_instance", "apple_silicon_server", "apple_silicon_private_nic"},
365365
},
366366
{
367367
Name: "mac-address",
@@ -397,7 +397,7 @@ func ipamIPList() *core.Command {
397397
Required: false,
398398
Deprecated: false,
399399
Positional: false,
400-
EnumValues: []string{"unknown_type", "custom", "instance_server", "instance_ip", "instance_private_nic", "lb_server", "fip_ip", "vpc_gateway", "vpc_gateway_network", "k8s_node", "k8s_cluster", "rdb_instance", "redis_cluster", "baremetal_server", "baremetal_private_nic", "llm_deployment", "mgdb_instance"},
400+
EnumValues: []string{"unknown_type", "custom", "instance_server", "instance_ip", "instance_private_nic", "lb_server", "fip_ip", "vpc_gateway", "vpc_gateway_network", "k8s_node", "k8s_cluster", "rdb_instance", "redis_cluster", "baremetal_server", "baremetal_private_nic", "llm_deployment", "mgdb_instance", "apple_silicon_server", "apple_silicon_private_nic"},
401401
},
402402
{
403403
Name: "organization-id",

0 commit comments

Comments
 (0)