Mill plugin to deploy code to AWS Lambda. This was inspired by the sbt plugin sbt-aws-lambda
.
Import the module in build.sc
using mill's $ivy
import syntax, and extend AwsLambdaModel
in your build definition:
import $ivy.`io.github.bbstilson::mill-aws-lambda:0.1.1`
import io.github.bbstilson.AwsLambdaModule
object project extends AwsLambdaModule {
def scalaVersion = "2.13.2"
def s3Bucket = "bucket"
def s3KeyPrefix = "prefix"
def lambdaName = "your-lambda-name"
def lambdaHandler = "org.bbstilson.Handler::handle"
}
Then, to package and deploy your project to an existing AWS Lambda.
mill project.deployLambda
Setting | Description |
---|---|
s3Bucket | The name of an S3 bucket where the lambda code will be stored. |
s3KeyPrefix | The prefix to the S3 key where the jar will be uploaded. |
lambdaName | The name to use for this AWS Lambda function. |
lambdaHandler | Class name and method to be executed. |
It has been tested with:
- 2.13.2
- 2.13.1
- 2.12.11
- 2.12.10
All code in this repository is licensed under the Apache License, Version 2.0. See LICENSE.