GithubHelp home page GithubHelp logo

emmanuelu17 / spring-boot-on-aws-lambda Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 26.98 MB

Deploying a Native Executable RESTful Spring Boot Application using GraalVM to AWS Lambda.

License: MIT License

Java 58.10% HTML 17.37% Dockerfile 17.12% Shell 7.41%

spring-boot-on-aws-lambda's Introduction

Deploying a native executable Spring Boot application using GraalVM to AWS Lambda.

Overview

This project demonstrates deploying RESTful Spring Boot 3.2.2 application on AWS Lambda using two methods: deploying as a zip file and deploying as a docker image. It is based on the AWS sample repository.

Note for both ways of deployment, I manually uploaded the source code to seperate lambda functions. For the zip file deployment, the application is packaged locally using the script ./build-native-zip.sh and for docker image deployment, GitHub Actions workflow is used to deploy to Amazon ECR (Elastic Container Registry).

Dependencies

  1. Java 21 (runtime)
  2. Lombok

Prerequisite

If you would like to build and upload to lambda from your local system, Docker needs to be installed.

Docker Image Deployment

To deploy a docker image, execute cd ./backend and ./build-native-ecr.sh in your terminal. This script generates the docker image name server-graalvm21 tagged as native-web. You can view details about the image by running docker image ls in your CLI.

Zip File Deployment

To deploy a zip file, execute cd ./backend and ./build-native-zip.sh in your terminal. This script produces a zip file named server-0.0.1-SNAPSHOT-native-zip.zip in the root of project.

spring-boot-on-aws-lambda's People

Contributors

itchtherightspot avatar

Stargazers

David Ko avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.