Package Exports
- serverless-swift
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (serverless-swift) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
serverless swift 
A ⚡ Serverless framework ⚡ plugin for Swift applications
📦 Install
Install the plugin with npm
$ npm i -D serverless-swift💡 This serverless plugin assumes you are building Swift lambdas targeting the AWS Lambda "provided" runtime. The AWS Lambda Swfit Sprinter makes this possible.
Add the following to your serverless project's serverless.yml file
service: demo
provider:
name: aws
runtime: swift
plugins:
# this adds informs serverless to use
# the serverless-swift plugin
- serverless-swift
# creates one artifact for each function
package:
individually: true
functions:
test:
# handler value syntax is `{your-executable-binary}.{bin-name}`
# or `{your-executable-binary}` for short when you are building a
# default bin for a given package.
handler: your-executable-binaryThe build needs to generate a swift executable. The name of the executable will either be the Swift project parent folder name or as specified in the Package.swift file, to replace with
Currently on every deploy it creates an AWS Lambda Layer, that is attached automatically to every swift functions. The layer makes it possible for the executable Swift binary to run in the Lambda.
🙌 Acknowledgements
This project has been possible thanks to the following people:
- Doug Tangren : https://github.com/softprops/serverless-rust
- Andrea Scuderi : https://github.com/swift-sprinter/aws-lambda-swift-sprinter-core