https://github.com/danielmachadovasconcelos/base-application
https://github.com/danielmachadovasconcelos/base-application
database postgres spring-boot-application
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/danielmachadovasconcelos/base-application
- Owner: DanielMachadoVasconcelos
- Created: 2020-04-05T07:25:56.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2022-08-01T07:09:28.000Z (over 3 years ago)
- Last Synced: 2025-01-08T16:07:49.725Z (about 1 year ago)
- Topics: database, postgres, spring-boot-application
- Language: Java
- Size: 170 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Spring boot application + PostgreSQL
Base application made with spring boot and postgres to serve as example.
## Starting Application using Docker Compose
Download the application using git:
```shell
$ git clone https://github.com/DanielMachadoVasconcelos/base-application.git
$ cd /base-application
```
Build the application using maven
```shell
$ mvn clean install
```
Start the database, and the application, using Docker Compose:
```shell
$ docker-compose up
```
## Initial database contents
Any files in the `initdb` directory will be used to initialize the database
when the Postgres container is first started. The sample `init.sql` file
shows how to create a database called `sampledb`.
## Application running
The compose file will run the spring boot application.
It will listen on your local system's port 8888.
Execute the command bellow to fetch the application endpoint:
```shell
$ curl --location --request GET 'http://localhost:8888/summary'
```