serverless-rust icon indicating copy to clipboard operation
serverless-rust copied to clipboard

fix: use `tags` instead of a custom invalid `runtime` option

Open fdaciuk opened this issue 3 years ago • 0 comments

What did you implement:

Serverless 3 will throw an error if we use a provider.runtime option different from the allowed values:

Error:
Configuration error at 'provider.runtime': must be equal to one of the allowed values [dotnet6, dotnetcore3.1, go1.x, java11, java8, java8.al2, nodejs12.x, nodejs14.x, nodejs16.x, provided, provided.al2, python3.6, python3.7, python3.8, python3.9, ruby2.7]

Learn more about configuration validation here: http://slss.io/configuration-validation

This PR removes the need to use the new runtime option (rust) and uses tags.rust: true inside the function configuration.

Closes: #107

How did you verify your change:

Just put a tag.rust: true in your function configuration and run npx serverless package:

functions:
  rust:
    handler: your_rust_project_name
    runtime: provided.al2
    tags:
      rust: true

What (if anything) would need to be called out in the CHANGELOG for the next release:

You can use the title of this PR.

@softprops =)

fdaciuk avatar Jun 25 '22 22:06 fdaciuk