Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ravening/springboot-generator
Custom spring boot generator
https://github.com/ravening/springboot-generator
docker gradle java maven spring-boot spring-boot-generator
Last synced: 20 days ago
JSON representation
Custom spring boot generator
- Host: GitHub
- URL: https://github.com/ravening/springboot-generator
- Owner: ravening
- Created: 2020-02-27T15:49:40.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2020-02-27T16:12:33.000Z (almost 5 years ago)
- Last Synced: 2024-12-06T09:42:14.628Z (3 months ago)
- Topics: docker, gradle, java, maven, spring-boot, spring-boot-generator
- Language: Java
- Size: 62.5 KB
- Stars: 0
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Custom Spring Boot generator
A simple Java applicaton developed using Spring boot generators to\
quickly bootstrap a customized spring boot application## Description
You can use this custom generator to quickly build a web application\
with preconfigured artifactid, groupid, names and specific dependencies.When generating projects from standard generators like start.spring.io,\
you need to rename the artifactid, groupid, name and add some dependencies.With one single command line you can do all the above using this generator.
## Prerequisites
Below are the softwares that needs to be installed as a dependency
```
Maven
Docker (to build Docker image)
httpie (command line tool) or curl is also good enough
```## Getting started
You can either clone this repo, build the application or run the docker container
```bash
docker pull rakgenius/springboot-generator:v1
```and run the image image using
```bash
docker run -it -d -p 8081:8081 rakgenius/springboot-generator:v1
```Then navigate to
```
http://localhost:8081
```This will display all the supported actions.
## Running the application manually
1 . Git clone the repo to any machine
2 . Build the packages using the command
```bash
mvnw package -DskipTests
```4 . Run the application using
```bash
java -jar target/demo-0.0.1-SNAPSHOT.jar
```Below are the useful commands
### To create a default project:
```bash
http http://localhost:8081/starter.zip -d
```### To create a web project using Java 11:
```bash
http http://localhost:8081/starter.zip dependencies==web javaVersion==11 -d
```### To create a web/data-jpa gradle project unpacked:
```bash
http http://localhost:8081/starter.tgz dependencies==web,data-jpa type==gradle-project baseDir==my-dir | tar -xzvf -
```### To generate a Maven POM with war packaging and specific dependencies:
```bash
http http://localhost:8081/pom.xml packaging==war -o pom.xml dependencies==web,data-jpa,thymeleaf,actuator
```## Building the docker images
Below are the command to build the docker image and to publish it to docker hub
1 . Build the docker image using
```bash
docker build -t springboot-generator .
```2 . Run the docker image using
```bash
docker run -d -it -p 8081:8081 --name springboot-generator springboot-generator
```3 . Create your own image which has to be pushed to the docker hub
```bash
docker image ls
```Get the "IMAGE ID" of "springboot-generator" image
Set the tag to your image
```bash
docker tag /springboot-generator:latest
```4 . Now push the docker image to docker hub
```bash
docker push /springboot-generator
```6 . Now you can pull the image on any machine anywhere using
```bash
docker pull /springboot-generator
```And run it using the command mentioned in step 2.
## Built With
* [Maven](https://maven.apache.org/) - Dependency Management
## Authors
Rakesh Venkatesh