Skip to content

Commit 0ed2d79

Browse files
docs(lb): escape curly brackets (#3173)
Co-authored-by: Rémy Léone <rleone@scaleway.com>
1 parent e8e167c commit 0ed2d79

File tree

6 files changed

+9
-18
lines changed

6 files changed

+9
-18
lines changed

cmd/scw/testdata/test-all-usage-lbacl-create-usage.golden

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ARGS:
1010
name=<generated> ACL name
1111
[action.type] Action to take when incoming traffic matches an ACL filter (allow | deny | redirect)
1212
[action.redirect.type] Redirect type (location | scheme)
13-
[action.redirect.target] Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }}
13+
[action.redirect.target] Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\}
1414
[action.redirect.code] HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302
1515
[match.ip-subnet.{index}] List of IPs or CIDR v4/v6 addresses to filter for from the client side
1616
[match.http-filter] Type of HTTP filter to match. Extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends (acl_http_filter_none | path_begin | path_end | regex | http_header_match)

cmd/scw/testdata/test-all-usage-lbacl-set-usage.golden

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ARGS:
99
acls.{index}.name ACL name
1010
[acls.{index}.action.type] Action to take when incoming traffic matches an ACL filter (allow | deny | redirect)
1111
[acls.{index}.action.redirect.type] Redirect type (location | scheme)
12-
[acls.{index}.action.redirect.target] Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }}
12+
[acls.{index}.action.redirect.target] Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\}
1313
[acls.{index}.action.redirect.code] HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302
1414
[acls.{index}.match.ip-subnet.{index}] List of IPs or CIDR v4/v6 addresses to filter for from the client side
1515
[acls.{index}.match.http-filter] Type of HTTP filter to match. Extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends (acl_http_filter_none | path_begin | path_end | regex | http_header_match)

cmd/scw/testdata/test-all-usage-lbacl-update-usage.golden

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ARGS:
1010
name ACL name
1111
[action.type] Action to take when incoming traffic matches an ACL filter (allow | deny | redirect)
1212
[action.redirect.type] Redirect type (location | scheme)
13-
[action.redirect.target] Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }}
13+
[action.redirect.target] Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\}
1414
[action.redirect.code] HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302
1515
[match.ip-subnet.{index}] List of IPs or CIDR v4/v6 addresses to filter for from the client side
1616
[match.http-filter] Type of HTTP filter to match. Extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends (acl_http_filter_none | path_begin | path_end | regex | http_header_match)

cmd/scw/testdata/test-all-usage-lblb-create-usage.golden

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ ARGS:
1111
[description] Description for the Load Balancer
1212
[assign-flexible-ip] Defines whether to automatically assign a flexible public IP to lb. Default value is `false` (do not assign).
1313
[ip-ids.{index}] List of IP IDs to attach to the Load Balancer
14-
[assign-flexible-ip] Defines whether to automatically assign a flexible public IP to lb. Default value is `false` (do not assign).
1514
[tags.{index}] List of tags for the Load Balancer
1615
[type=LB-S] Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types (LB-S | LB-GP-M | LB-GP-L)
1716
[ssl-compatibility-level] Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort (ssl_compatibility_level_unknown | ssl_compatibility_level_intermediate | ssl_compatibility_level_modern | ssl_compatibility_level_old)

docs/commands/lb.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ scw lb acl create [arg=value ...]
9393
| name | Required<br />Default: `<generated>` | ACL name |
9494
| action.type | One of: `allow`, `deny`, `redirect` | Action to take when incoming traffic matches an ACL filter |
9595
| action.redirect.type | One of: `location`, `scheme` | Redirect type |
96-
| action.redirect.target | | Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }} |
96+
| action.redirect.target | | Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\} |
9797
| action.redirect.code | | HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302 |
9898
| match.ip-subnet.{index} | | List of IPs or CIDR v4/v6 addresses to filter for from the client side |
9999
| match.http-filter | One of: `acl_http_filter_none`, `path_begin`, `path_end`, `regex`, `http_header_match` | Type of HTTP filter to match. Extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends |
@@ -186,7 +186,7 @@ scw lb acl set [arg=value ...]
186186
| acls.{index}.name | Required | ACL name |
187187
| acls.{index}.action.type | One of: `allow`, `deny`, `redirect` | Action to take when incoming traffic matches an ACL filter |
188188
| acls.{index}.action.redirect.type | One of: `location`, `scheme` | Redirect type |
189-
| acls.{index}.action.redirect.target | | Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }} |
189+
| acls.{index}.action.redirect.target | | Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\} |
190190
| acls.{index}.action.redirect.code | | HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302 |
191191
| acls.{index}.match.ip-subnet.{index} | | List of IPs or CIDR v4/v6 addresses to filter for from the client side |
192192
| acls.{index}.match.http-filter | One of: `acl_http_filter_none`, `path_begin`, `path_end`, `regex`, `http_header_match` | Type of HTTP filter to match. Extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends |
@@ -219,7 +219,7 @@ scw lb acl update <acl-id ...> [arg=value ...]
219219
| name | Required | ACL name |
220220
| action.type | One of: `allow`, `deny`, `redirect` | Action to take when incoming traffic matches an ACL filter |
221221
| action.redirect.type | One of: `location`, `scheme` | Redirect type |
222-
| action.redirect.target | | Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }} |
222+
| action.redirect.target | | Redirect target. For a location redirect, you can use a URL e.g. `https://scaleway.com`. Using a scheme name (e.g. `https`, `http`, `ftp`, `git`) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a `location` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\} |
223223
| action.redirect.code | | HTTP redirect code to use. Valid values are 301, 302, 303, 307 and 308. Default value is 302 |
224224
| match.ip-subnet.{index} | | List of IPs or CIDR v4/v6 addresses to filter for from the client side |
225225
| match.http-filter | One of: `acl_http_filter_none`, `path_begin`, `path_end`, `regex`, `http_header_match` | Type of HTTP filter to match. Extracts the request's URL path, which starts at the first slash and ends before the question mark (without the host part). Defines where to filter for the http_filter_value. Only supported for HTTP backends |
@@ -903,7 +903,6 @@ scw lb lb create [arg=value ...]
903903
| ~~ip-id~~ | Deprecated | ID of an existing flexible IP address to attach to the Load Balancer |
904904
| assign-flexible-ip | | Defines whether to automatically assign a flexible public IP to lb. Default value is `false` (do not assign). |
905905
| ip-ids.{index} | | List of IP IDs to attach to the Load Balancer |
906-
| assign-flexible-ip | | Defines whether to automatically assign a flexible public IP to lb. Default value is `false` (do not assign). |
907906
| tags.{index} | | List of tags for the Load Balancer |
908907
| type | Default: `LB-S`<br />One of: `LB-S`, `LB-GP-M`, `LB-GP-L` | Load Balancer commercial offer type. Use the Load Balancer types endpoint to retrieve a list of available offer types |
909908
| ssl-compatibility-level | One of: `ssl_compatibility_level_unknown`, `ssl_compatibility_level_intermediate`, `ssl_compatibility_level_modern`, `ssl_compatibility_level_old` | Determines the minimal SSL version which needs to be supported on the client side, in an SSL/TLS offloading context. Intermediate is suitable for general-purpose servers with a variety of clients, recommended for almost all systems. Modern is suitable for services with clients that support TLS 1.3 and do not need backward compatibility. Old is compatible with a small number of very old clients and should be used only as a last resort |

internal/namespaces/lb/v1/lb_cli.go

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -292,13 +292,6 @@ func lbLBCreate() *core.Command {
292292
Deprecated: false,
293293
Positional: false,
294294
},
295-
{
296-
Name: "assign-flexible-ip",
297-
Short: `Defines whether to automatically assign a flexible public IP to lb. Default value is ` + "`" + `false` + "`" + ` (do not assign).`,
298-
Required: false,
299-
Deprecated: false,
300-
Positional: false,
301-
},
302295
{
303296
Name: "tags.{index}",
304297
Short: `List of tags for the Load Balancer`,
@@ -2203,7 +2196,7 @@ func lbACLCreate() *core.Command {
22032196
},
22042197
{
22052198
Name: "action.redirect.target",
2206-
Short: `Redirect target. For a location redirect, you can use a URL e.g. ` + "`" + `https://scaleway.com` + "`" + `. Using a scheme name (e.g. ` + "`" + `https` + "`" + `, ` + "`" + `http` + "`" + `, ` + "`" + `ftp` + "`" + `, ` + "`" + `git` + "`" + `) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a ` + "`" + `location` + "`" + ` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }}`,
2199+
Short: `Redirect target. For a location redirect, you can use a URL e.g. ` + "`" + `https://scaleway.com` + "`" + `. Using a scheme name (e.g. ` + "`" + `https` + "`" + `, ` + "`" + `http` + "`" + `, ` + "`" + `ftp` + "`" + `, ` + "`" + `git` + "`" + `) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a ` + "`" + `location` + "`" + ` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\}`,
22072200
Required: false,
22082201
Deprecated: false,
22092202
Positional: false,
@@ -2350,7 +2343,7 @@ func lbACLUpdate() *core.Command {
23502343
},
23512344
{
23522345
Name: "action.redirect.target",
2353-
Short: `Redirect target. For a location redirect, you can use a URL e.g. ` + "`" + `https://scaleway.com` + "`" + `. Using a scheme name (e.g. ` + "`" + `https` + "`" + `, ` + "`" + `http` + "`" + `, ` + "`" + `ftp` + "`" + `, ` + "`" + `git` + "`" + `) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a ` + "`" + `location` + "`" + ` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }}`,
2346+
Short: `Redirect target. For a location redirect, you can use a URL e.g. ` + "`" + `https://scaleway.com` + "`" + `. Using a scheme name (e.g. ` + "`" + `https` + "`" + `, ` + "`" + `http` + "`" + `, ` + "`" + `ftp` + "`" + `, ` + "`" + `git` + "`" + `) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a ` + "`" + `location` + "`" + ` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\}`,
23542347
Required: false,
23552348
Deprecated: false,
23562349
Positional: false,
@@ -2496,7 +2489,7 @@ func lbACLSet() *core.Command {
24962489
},
24972490
{
24982491
Name: "acls.{index}.action.redirect.target",
2499-
Short: `Redirect target. For a location redirect, you can use a URL e.g. ` + "`" + `https://scaleway.com` + "`" + `. Using a scheme name (e.g. ` + "`" + `https` + "`" + `, ` + "`" + `http` + "`" + `, ` + "`" + `ftp` + "`" + `, ` + "`" + `git` + "`" + `) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a ` + "`" + `location` + "`" + ` redirect to preserve parts of the original request in the redirection URL are {{ host }}, {{ query }}, {{ path }} and {{ scheme }}`,
2492+
Short: `Redirect target. For a location redirect, you can use a URL e.g. ` + "`" + `https://scaleway.com` + "`" + `. Using a scheme name (e.g. ` + "`" + `https` + "`" + `, ` + "`" + `http` + "`" + `, ` + "`" + `ftp` + "`" + `, ` + "`" + `git` + "`" + `) will replace the request's original scheme. This can be useful to implement HTTP to HTTPS redirects. Valid placeholders that can be used in a ` + "`" + `location` + "`" + ` redirect to preserve parts of the original request in the redirection URL are \{\{ host \}\}, \{\{ query \}\}, \{\{ path \}\} and \{\{ scheme \}\}`,
25002493
Required: false,
25012494
Deprecated: false,
25022495
Positional: false,

0 commit comments

Comments
 (0)