azolotko / mill-aws-lambda

Mill plugin to deploy code to AWS Lambda.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Mill AWS Lambda

License Latest Version

Mill plugin to deploy code to AWS Lambda. This was inspired by the sbt plugin sbt-aws-lambda.

Usage

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

Configuration

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.

Scala Versions

It has been tested with:

  • 2.13.2
  • 2.13.1
  • 2.12.11
  • 2.12.10

License

All code in this repository is licensed under the Apache License, Version 2.0. See LICENSE.

About

Mill plugin to deploy code to AWS Lambda.

License:Apache License 2.0


Languages

Language:Scala 90.7%Language:Shell 9.3%