https://github.com/giosil/spring-samples
Spring-boot samples
https://github.com/giosil/spring-samples
microservices spring-boot springboot
Last synced: 2 months ago
JSON representation
Spring-boot samples
- Host: GitHub
- URL: https://github.com/giosil/spring-samples
- Owner: giosil
- Created: 2024-06-26T09:08:48.000Z (10 months ago)
- Default Branch: master
- Last Pushed: 2025-02-10T11:57:06.000Z (3 months ago)
- Last Synced: 2025-02-10T12:37:39.417Z (3 months ago)
- Topics: microservices, spring-boot, springboot
- Language: JavaScript
- Homepage:
- Size: 475 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Spring-samples
Spring-boot samples.
## Build frontend
Before install typescrpt, uglify-js and uglifycss
npm install -g typescript
npm install -g uglify-js
npm install -g uglifycssTo build:
npm run build
## Build application
mvn clean package
or
mvn clean package -DskipTests
## Run application
mvn spring-boot:run
mvn spring-boot:run "-Dspring-boot.run.jvmArguments=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:8787"
or
java -jar ./target/app-0.0.1-SNAPSHOT.jar
## Run application with prod profile
mvn spring-boot:run -Dspring-boot.run.profiles=prod
or
java -jar ./target/app-0.0.1-SNAPSHOT.jar --spring.profiles.active=prod
## Build docker appbe image (Backend)
docker build -t appbe .
## Build docker appdb image (Database)
cd database
docker build -t appdb .
## Run erpbdb separately
docker run --name appdb-postgres -p 5432:5432 -d appdb
## Run postgres separately (empty database)
docker run --name appdb-postgres -p 5432:5432 -e POSTGRES_DB=appdb -e POSTGRES_USER=appdb -e POSTGRES_PASSWORD=passw0rd -d postgres:12
## Docker compose
docker compose -p "app-cluster" up --detach
See [more samples](README_more.md).
## Contributors
* [Giorgio Silvestris](https://github.com/giosil)