Skip to content

adolfojunior/spring-boot-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spring Boot Sample

A simple RESTful Service using Spring Boot that autoconfigure JAX-RS Beans

How to run it?

Clone from git:

git clone https://github.com/adolfojunior/spring-boot-demo.git
cd spring-boot-demo

Use the embedded maven wrapper to package it and run it!

./mvnw clean package

./mvnw spring-boot:run or java -jar target/*.jar

Check if everything is ok: http://localhost:8080/api

  • curl http://localhost:8080/api
  • curl http://localhost:8080/health
  • curl http://localhost:8080/metrics

App Endpoints:

  • curl -X GET http://localhost:8080/api/post
  • curl -X GET http://localhost:8080/api/post/1

Running on Heroku

Check PORT and PROFILE

git remote add heroku -f <heroku-git-repo-url>

git push heroku master

Running on Openshift

Check the deploy files:

Use the DIY Linux!

git remote add openshift -f <openshift-git-repo-url>

git merge openshift/master -s recursive -X ours

git push openshift master

About

Simple Spring Boot Demo

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors