Skip to content

Commit

Permalink
feat(serverless): add node20 runtime (#3090)
Browse files Browse the repository at this point in the history
  • Loading branch information
scaleway-bot committed Apr 25, 2023
1 parent d05f064 commit 859d891
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ USAGE:
ARGS:
[namespace-id] Function Namespace ID to deploy to
name Name of the function to deploy, will be used in namespace's name if no ID is provided
runtime (unknown_runtime | golang | python | python3 | node8 | node10 | node14 | node16 | node17 | python37 | python38 | python39 | python310 | go113 | go117 | go118 | node18 | rust165 | go119 | python311 | php82 | node19 | go120)
runtime (unknown_runtime | golang | python | python3 | node8 | node10 | node14 | node16 | node17 | python37 | python38 | python39 | python310 | go113 | go117 | go118 | node18 | rust165 | go119 | python311 | php82 | node19 | go120 | node20)
zip-file Path of the zip file that contains your code
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ ARGS:
[environment-variables.{key}] Environment variables of the function
[min-scale] Minumum number of instances to scale the function to
[max-scale] Maximum number of instances to scale the function to
[runtime] Runtime to use with the function (unknown_runtime | golang | python | python3 | node8 | node10 | node14 | node16 | node17 | python37 | python38 | python39 | python310 | go113 | go117 | go118 | node18 | rust165 | go119 | python311 | php82 | node19 | go120)
[runtime] Runtime to use with the function (unknown_runtime | golang | python | python3 | node8 | node10 | node14 | node16 | node17 | python37 | python38 | python39 | python310 | go113 | go117 | go118 | node18 | rust165 | go119 | python311 | php82 | node19 | go120 | node20)
[memory-limit] Memory limit of the function in MB
[timeout.seconds]
[timeout.nanos]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ARGS:
[environment-variables.{key}] Environment variables of the function to update
[min-scale] Minumum number of instances to scale the function to
[max-scale] Maximum number of instances to scale the function to
[runtime] Runtime to use with the function (unknown_runtime | golang | python | python3 | node8 | node10 | node14 | node16 | node17 | python37 | python38 | python39 | python310 | go113 | go117 | go118 | node18 | rust165 | go119 | python311 | php82 | node19 | go120)
[runtime] Runtime to use with the function (unknown_runtime | golang | python | python3 | node8 | node10 | node14 | node16 | node17 | python37 | python38 | python39 | python310 | go113 | go117 | go118 | node18 | rust165 | go119 | python311 | php82 | node19 | go120 | node20)
[memory-limit] Memory limit of the function in MB
[timeout.seconds]
[timeout.nanos]
Expand Down
2 changes: 1 addition & 1 deletion cmd/scw/testdata/test-all-usage-function-usage.golden
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
Functions API.
Serverless Functions API.

USAGE:
scw function <command>
Expand Down
8 changes: 4 additions & 4 deletions docs/commands/function.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- DO NOT EDIT: this file is automatically generated using scw-doc-gen -->
# Documentation for `scw function`
Functions API.
Serverless Functions API.

- [Cron management commands](#cron-management-commands)
- [Create a new cron](#create-a-new-cron)
Expand Down Expand Up @@ -171,7 +171,7 @@ scw function deploy [arg=value ...]
|------|---|-------------|
| namespace-id | | Function Namespace ID to deploy to |
| name | Required | Name of the function to deploy, will be used in namespace's name if no ID is provided |
| runtime | Required<br />One of: `unknown_runtime`, `golang`, `python`, `python3`, `node8`, `node10`, `node14`, `node16`, `node17`, `python37`, `python38`, `python39`, `python310`, `go113`, `go117`, `go118`, `node18`, `rust165`, `go119`, `python311`, `php82`, `node19`, `go120` | |
| runtime | Required<br />One of: `unknown_runtime`, `golang`, `python`, `python3`, `node8`, `node10`, `node14`, `node16`, `node17`, `python37`, `python38`, `python39`, `python310`, `go113`, `go117`, `go118`, `node18`, `rust165`, `go119`, `python311`, `php82`, `node19`, `go120`, `node20` | |
| zip-file | Required | Path of the zip file that contains your code |
| region | Default: `fr-par`<br />One of: `fr-par`, `nl-ams`, `pl-waw` | Region to target. If none is passed will use default region from the config |

Expand Down Expand Up @@ -289,7 +289,7 @@ scw function function create [arg=value ...]
| environment-variables.{key} | | Environment variables of the function |
| min-scale | | Minumum number of instances to scale the function to |
| max-scale | | Maximum number of instances to scale the function to |
| runtime | One of: `unknown_runtime`, `golang`, `python`, `python3`, `node8`, `node10`, `node14`, `node16`, `node17`, `python37`, `python38`, `python39`, `python310`, `go113`, `go117`, `go118`, `node18`, `rust165`, `go119`, `python311`, `php82`, `node19`, `go120` | Runtime to use with the function |
| runtime | One of: `unknown_runtime`, `golang`, `python`, `python3`, `node8`, `node10`, `node14`, `node16`, `node17`, `python37`, `python38`, `python39`, `python310`, `go113`, `go117`, `go118`, `node18`, `rust165`, `go119`, `python311`, `php82`, `node19`, `go120`, `node20` | Runtime to use with the function |
| memory-limit | | Memory limit of the function in MB |
| timeout.seconds | | |
| timeout.nanos | | |
Expand Down Expand Up @@ -468,7 +468,7 @@ scw function function update <function-id ...> [arg=value ...]
| environment-variables.{key} | | Environment variables of the function to update |
| min-scale | | Minumum number of instances to scale the function to |
| max-scale | | Maximum number of instances to scale the function to |
| runtime | One of: `unknown_runtime`, `golang`, `python`, `python3`, `node8`, `node10`, `node14`, `node16`, `node17`, `python37`, `python38`, `python39`, `python310`, `go113`, `go117`, `go118`, `node18`, `rust165`, `go119`, `python311`, `php82`, `node19`, `go120` | Runtime to use with the function |
| runtime | One of: `unknown_runtime`, `golang`, `python`, `python3`, `node8`, `node10`, `node14`, `node16`, `node17`, `python37`, `python38`, `python39`, `python310`, `go113`, `go117`, `go118`, `node18`, `rust165`, `go119`, `python311`, `php82`, `node19`, `go120`, `node20` | Runtime to use with the function |
| memory-limit | | Memory limit of the function in MB |
| timeout.seconds | | |
| timeout.nanos | | |
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ require (
github.com/moby/buildkit v0.11.6
github.com/opencontainers/go-digest v1.0.0
github.com/pkg/errors v0.9.1
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.15.0.20230404142259-598b1ac41f06
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.16.0.20230424152630-05355b6e32c3
github.com/spf13/cobra v1.7.0
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.8.2
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -274,8 +274,8 @@ github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6L
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.15.0.20230404142259-598b1ac41f06 h1:QvmCsVGrajhRqLaJNd1KlZduhIkQvKYoUaUdv+I2yTM=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.15.0.20230404142259-598b1ac41f06/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.16.0.20230424152630-05355b6e32c3 h1:Qc8zmH5LqWj3veWJrX1tXrQU7O2QJCdAJ9oPPJfZM2s=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.16.0.20230424152630-05355b6e32c3/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg=
github.com/seccomp/libseccomp-golang v0.9.2-0.20220502022130-f33da4d89646/go.mod h1:JA8cRccbGaA1s33RQf7Y1+q9gHmZX1yB/z9WDN1C6fg=
github.com/secure-systems-lab/go-securesystemslib v0.4.0 h1:b23VGrQhTA8cN2CbBw7/FulN9fTtqYUdS5+Oxzt+DUE=
github.com/sergi/go-diff v1.2.0 h1:XU+rvMAioB0UC3q1MFrIQy4Vo5/4VsRDQQXHsEya6xQ=
Expand Down
6 changes: 3 additions & 3 deletions internal/namespaces/function/v1beta1/function_cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func GetGeneratedCommands() *core.Commands {
func functionRoot() *core.Command {
return &core.Command{
Short: `Function as a Service API`,
Long: `Functions API.`,
Long: `Serverless Functions API.`,
Namespace: "function",
}
}
Expand Down Expand Up @@ -537,7 +537,7 @@ func functionFunctionCreate() *core.Command {
Required: false,
Deprecated: false,
Positional: false,
EnumValues: []string{"unknown_runtime", "golang", "python", "python3", "node8", "node10", "node14", "node16", "node17", "python37", "python38", "python39", "python310", "go113", "go117", "go118", "node18", "rust165", "go119", "python311", "php82", "node19", "go120"},
EnumValues: []string{"unknown_runtime", "golang", "python", "python3", "node8", "node10", "node14", "node16", "node17", "python37", "python38", "python39", "python310", "go113", "go117", "go118", "node18", "rust165", "go119", "python311", "php82", "node19", "go120", "node20"},
},
{
Name: "memory-limit",
Expand Down Expand Up @@ -658,7 +658,7 @@ func functionFunctionUpdate() *core.Command {
Required: false,
Deprecated: false,
Positional: false,
EnumValues: []string{"unknown_runtime", "golang", "python", "python3", "node8", "node10", "node14", "node16", "node17", "python37", "python38", "python39", "python310", "go113", "go117", "go118", "node18", "rust165", "go119", "python311", "php82", "node19", "go120"},
EnumValues: []string{"unknown_runtime", "golang", "python", "python3", "node8", "node10", "node14", "node16", "node17", "python37", "python38", "python39", "python310", "go113", "go117", "go118", "node18", "rust165", "go119", "python311", "php82", "node19", "go120", "node20"},
},
{
Name: "memory-limit",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ RuntimeMessage -
"timeout": "300.000000000s",
"handler": "Handle",
"error_message": null,
"build_message": null,
"privacy": "public",
"description": "",
"domain_name": "clitestfunctiondeploeqj6jxof-cli-test-function-deploy.functions.fnc.fr-par.scw.cloud",
Expand Down

0 comments on commit 859d891

Please sign in to comment.