diff --git a/cmd/scw/testdata/test-all-usage-interlink-link-detach-policy-usage.golden b/cmd/scw/testdata/test-all-usage-interlink-link-detach-policy-usage.golden index ef65df2d9c..441a4b7a00 100644 --- a/cmd/scw/testdata/test-all-usage-interlink-link-detach-policy-usage.golden +++ b/cmd/scw/testdata/test-all-usage-interlink-link-detach-policy-usage.golden @@ -6,8 +6,9 @@ USAGE: scw interlink link detach_policy [arg=value ...] ARGS: - link-id ID of the link to detach a routing policy from - [region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw) + link-id ID of the link to detach a routing policy from + routing-policy-id ID of the routing policy to be detached + [region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw) FLAGS: -h, --help help for detach_policy diff --git a/cmd/scw/testdata/test-all-usage-interlink-routing-policy-create-usage.golden b/cmd/scw/testdata/test-all-usage-interlink-routing-policy-create-usage.golden index 15de0baf6d..e5e215c12d 100644 --- a/cmd/scw/testdata/test-all-usage-interlink-routing-policy-create-usage.golden +++ b/cmd/scw/testdata/test-all-usage-interlink-routing-policy-create-usage.golden @@ -11,6 +11,7 @@ ARGS: [tags.{index}] List of tags to apply to the routing policy [prefix-filter-in.{index}] IP prefixes to accept from the peer (ranges of route announcements to accept) [prefix-filter-out.{index}] IP prefix filters to advertise to the peer (ranges of routes to advertise) + [is-ipv6] IP prefixes version of the routing policy [region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw) FLAGS: diff --git a/cmd/scw/testdata/test-all-usage-interlink-routing-policy-list-usage.golden b/cmd/scw/testdata/test-all-usage-interlink-routing-policy-list-usage.golden index 8e1f7ee8df..061fa57995 100644 --- a/cmd/scw/testdata/test-all-usage-interlink-routing-policy-list-usage.golden +++ b/cmd/scw/testdata/test-all-usage-interlink-routing-policy-list-usage.golden @@ -10,6 +10,7 @@ ARGS: [project-id] Project ID to filter for [name] Routing policy name to filter for [tags.{index}] Tags to filter for + [ipv6] Filter for the routing policies based on IP prefixes version [organization-id] Organization ID to filter for [region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw | all) diff --git a/docs/commands/interlink.md b/docs/commands/interlink.md index 8f5514f216..5e5126630c 100644 --- a/docs/commands/interlink.md +++ b/docs/commands/interlink.md @@ -153,6 +153,7 @@ scw interlink link detach_policy [arg=value ...] | Name | | Description | |------|---|-------------| | link-id | Required | ID of the link to detach a routing policy from | +| routing-policy-id | Required | ID of the routing policy to be detached | | region | Default: `fr-par`
One of: `fr-par`, `nl-ams`, `pl-waw` | Region to target. If none is passed will use default region from the config | @@ -416,6 +417,7 @@ scw interlink routing-policy create [arg=value ...] | tags.{index} | | List of tags to apply to the routing policy | | prefix-filter-in.{index} | | IP prefixes to accept from the peer (ranges of route announcements to accept) | | prefix-filter-out.{index} | | IP prefix filters to advertise to the peer (ranges of routes to advertise) | +| is-ipv6 | | IP prefixes version of the routing policy | | region | Default: `fr-par`
One of: `fr-par`, `nl-ams`, `pl-waw` | Region to target. If none is passed will use default region from the config | @@ -479,6 +481,7 @@ scw interlink routing-policy list [arg=value ...] | project-id | | Project ID to filter for | | name | | Routing policy name to filter for | | tags.{index} | | Tags to filter for | +| ipv6 | | Filter for the routing policies based on IP prefixes version | | organization-id | | Organization ID to filter for | | region | Default: `fr-par`
One of: `fr-par`, `nl-ams`, `pl-waw`, `all` | Region to target. If none is passed will use default region from the config | diff --git a/internal/namespaces/interlink/v1beta1/interlink_cli.go b/internal/namespaces/interlink/v1beta1/interlink_cli.go index a1bb8aee0a..d9be09d31a 100644 --- a/internal/namespaces/interlink/v1beta1/interlink_cli.go +++ b/internal/namespaces/interlink/v1beta1/interlink_cli.go @@ -8,7 +8,7 @@ import ( "reflect" "github.com/scaleway/scaleway-cli/v2/core" - interlink "github.com/scaleway/scaleway-sdk-go/api/interlink/v1beta1" + "github.com/scaleway/scaleway-sdk-go/api/interlink/v1beta1" "github.com/scaleway/scaleway-sdk-go/scw" ) @@ -826,6 +826,13 @@ func interlinkLinkDetachPolicy() *core.Command { Deprecated: false, Positional: true, }, + { + Name: "routing-policy-id", + Short: `ID of the routing policy to be detached`, + Required: true, + Deprecated: false, + Positional: false, + }, core.RegionArgSpec( scw.RegionFrPar, scw.RegionNlAms, @@ -955,6 +962,13 @@ func interlinkRoutingPolicyList() *core.Command { Deprecated: false, Positional: false, }, + { + Name: "ipv6", + Short: `Filter for the routing policies based on IP prefixes version`, + Required: false, + Deprecated: false, + Positional: false, + }, { Name: "organization-id", Short: `Organization ID to filter for`, @@ -1062,6 +1076,13 @@ func interlinkRoutingPolicyCreate() *core.Command { Deprecated: false, Positional: false, }, + { + Name: "is-ipv6", + Short: `IP prefixes version of the routing policy`, + Required: false, + Deprecated: false, + Positional: false, + }, core.RegionArgSpec( scw.RegionFrPar, scw.RegionNlAms,