Skip to content

NoelJB/NeuedaCDApplication

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Docker (Compose), Spring Boot, React and database (MySQL or H2) example

The Example

This is a fork of the simple CD Library application that was communally developed as a technology demo during a 2024 Neueda corporate traning. The backend is implemented using Spring Boot with Spring Web MVC and Spring Data JPA.

Two versions

The main branch can run standalone or as a single Docker container with the h2 embedded database. The compose branch runs as two containers, one running the backend Spring Boot application, the other running MySQL.

The Multistage Build

There are three stages to the Docker build. Stage 1 builds the React artifact as a static SPA. Stage 2 builds the Spring Boot application, incorporating the static UI. Stage 3 is the "production" image.

Run the Docker version

To bring up this app, run the bring_up script, which will build the front-end, copy the static files to the Spring application, and go on from there.

docker build . -t cdapp && docker run --rm -p 8100:8080 cdapp

About

Spring Boot Application

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 59.1%
  • CSS 26.3%
  • JavaScript 10.2%
  • Dockerfile 4.4%