diff --git a/cmd/scw/testdata/test-all-usage-lb-frontend-create-usage.golden b/cmd/scw/testdata/test-all-usage-lb-frontend-create-usage.golden index 735955c3fb..1eee705f85 100644 --- a/cmd/scw/testdata/test-all-usage-lb-frontend-create-usage.golden +++ b/cmd/scw/testdata/test-all-usage-lb-frontend-create-usage.golden @@ -13,6 +13,7 @@ ARGS: [timeout-client=5m] Maximum allowed inactivity time on the client side [certificate-ids.{index}] List of SSL/TLS certificate IDs to bind to the frontend [enable-http3] Defines whether to enable HTTP/3 protocol on the frontend + [connection-rate-limit] Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. [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 | nl-ams-2 | nl-ams-3 | pl-waw-1 | pl-waw-2 | pl-waw-3) DEPRECATED ARGS: diff --git a/cmd/scw/testdata/test-all-usage-lb-frontend-update-usage.golden b/cmd/scw/testdata/test-all-usage-lb-frontend-update-usage.golden index 5ae808cc5d..a880bc7268 100644 --- a/cmd/scw/testdata/test-all-usage-lb-frontend-update-usage.golden +++ b/cmd/scw/testdata/test-all-usage-lb-frontend-update-usage.golden @@ -13,6 +13,7 @@ ARGS: [timeout-client=5m] Maximum allowed inactivity time on the client side [certificate-ids.{index}] List of SSL/TLS certificate IDs to bind to the frontend [enable-http3] Defines whether to enable HTTP/3 protocol on the frontend + [connection-rate-limit] Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. [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 | nl-ams-2 | nl-ams-3 | pl-waw-1 | pl-waw-2 | pl-waw-3) DEPRECATED ARGS: diff --git a/docs/commands/lb.md b/docs/commands/lb.md index d6b9be6cc3..d879f76ade 100644 --- a/docs/commands/lb.md +++ b/docs/commands/lb.md @@ -676,6 +676,7 @@ scw lb frontend create [arg=value ...] | ~~certificate-id~~ | Deprecated | Certificate ID, deprecated in favor of certificate_ids array | | certificate-ids.{index} | | List of SSL/TLS certificate IDs to bind to the frontend | | enable-http3 | | Defines whether to enable HTTP/3 protocol on the frontend | +| connection-rate-limit | | Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. | | zone | Default: `fr-par-1`
One of: `fr-par-1`, `fr-par-2`, `nl-ams-1`, `nl-ams-2`, `nl-ams-3`, `pl-waw-1`, `pl-waw-2`, `pl-waw-3` | Zone to target. If none is passed will use default zone from the config | @@ -765,6 +766,7 @@ scw lb frontend update [arg=value ...] | ~~certificate-id~~ | Deprecated | Certificate ID, deprecated in favor of certificate_ids array | | certificate-ids.{index} | | List of SSL/TLS certificate IDs to bind to the frontend | | enable-http3 | | Defines whether to enable HTTP/3 protocol on the frontend | +| connection-rate-limit | | Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. | | zone | Default: `fr-par-1`
One of: `fr-par-1`, `fr-par-2`, `nl-ams-1`, `nl-ams-2`, `nl-ams-3`, `pl-waw-1`, `pl-waw-2`, `pl-waw-3` | Zone to target. If none is passed will use default zone from the config | diff --git a/internal/namespaces/lb/v1/lb_cli.go b/internal/namespaces/lb/v1/lb_cli.go index eb2df24576..895cbcf961 100644 --- a/internal/namespaces/lb/v1/lb_cli.go +++ b/internal/namespaces/lb/v1/lb_cli.go @@ -1721,6 +1721,13 @@ func lbFrontendCreate() *core.Command { Deprecated: false, Positional: false, }, + { + Name: "connection-rate-limit", + Short: `Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.`, + Required: false, + Deprecated: false, + Positional: false, + }, core.ZoneArgSpec(scw.ZoneFrPar1, scw.ZoneFrPar2, scw.ZoneNlAms1, scw.ZoneNlAms2, scw.ZoneNlAms3, scw.ZonePlWaw1, scw.ZonePlWaw2, scw.ZonePlWaw3), }, Run: func(ctx context.Context, args interface{}) (i interface{}, e error) { @@ -1831,6 +1838,13 @@ func lbFrontendUpdate() *core.Command { Deprecated: false, Positional: false, }, + { + Name: "connection-rate-limit", + Short: `Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second.`, + Required: false, + Deprecated: false, + Positional: false, + }, core.ZoneArgSpec(scw.ZoneFrPar1, scw.ZoneFrPar2, scw.ZoneNlAms1, scw.ZoneNlAms2, scw.ZoneNlAms3, scw.ZonePlWaw1, scw.ZonePlWaw2, scw.ZonePlWaw3), }, Run: func(ctx context.Context, args interface{}) (i interface{}, e error) {