Skip to content

Commit

Permalink
Add Rust files support (#123)
Browse files Browse the repository at this point in the history
Co-authored-by: norbjd <[email protected]>
  • Loading branch information
thomas-tacquet and norbjd authored Nov 25, 2022
1 parent 2976550 commit 5791d19
Show file tree
Hide file tree
Showing 9 changed files with 521 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/.idea
node_modules
.serverless
.serverless
**/rust*/target/
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ Serverless Framework handles everything from creating namespaces to function/cod
- [Node](#node)
- [Python](#python)
- [Golang](#golang)
- [Rust](#rust)
- [Events](#events)
- [Custom domains](#custom-domains)
- [Ways to deploy functions](#ways-to-deploy-functions)
Expand Down Expand Up @@ -294,6 +295,25 @@ functions:
handler: src/second
```

### Rust

Recommanded folder structure for `rust` runtime :
```yml
- src
- handler.rs
- serverless.yml
```

Your serverless.yml `functions` should look something like this:

```yml
provider:
runtime: rust165
functions:
main:
handler: "handler"
```

### Events

With `events`, you may link your functions with `CRON Schedule (Time based)` triggers.
Expand Down
Loading

0 comments on commit 5791d19

Please sign in to comment.