- build the project with
shadowJar
- create a new lambda with java runtime
- upload the jar
- edit the entry point to use
dev.silverandro.maven.Handler::handleRequest
as the handler - create an s3 bucket
- configure env variables
- update permissions for the lambda to write and read s3
- optional: enable and use snapstart https://docs.aws.amazon.com/lambda/latest/dg/snapstart-activate.html
- create an api gateway
- create
$default
route for the gateway and attach the integration (and remove the default integration) - use https://kylebarron.dev/blog/caching-lambda-functions-cloudflare to connect through cloudflare
Required:
BUCKET_NAME
: name of the s3 bucket for your mavenUPLOAD_USERNAME
: username for uploadsUPLOAD_PASSWORD
: password for uploads
IS_INDEXING_ENABLED
: controls indexing for the maven (defaulttrue
)INDEXING_MAX_KEYS
: max keys to request from s3 at a time (default1000
)MAX_ARTIFACT_SIZE
: max size of artifacts (default5900000
)MAVEN_NAME
: name of the maven (defaultMaven
)MAVEN_IMAGE
: URL to an image for rich embeds (default unused)MAVEN_COLOR
: color for rich embeds (default unused)MAVEN_ICON
: URL to favicon (default unused)