GithubHelp home page GithubHelp logo

springboot-gradle-cctrl-example's Introduction

#Building a Webapp with Spring Boot, MongoDB and Gradle

This project is a simple example project about how to create a webapp with Spring Boot, MongoDB and Gradle and then push it to a cloud service like CloudControl. With some simple tweeking you should be able to run this app on any cloud hoster.

###What this app is able to do

  • Say hello
  • create a person with first name and last name
  • find a person by its last name and display his full name

###Things you'll need for running this app locally

  • a running MongoDB instance

###Things you'll need for running this app on CloudControl

  • The cctrlapp installed
  • a CloudControl account
  • a CloudControl billing account in order to be able to add AddOns

###Run this app locally To run this app simply type "./gradlew bootRun" or "gradlew.bat bootRun" in a shell or command line.

###Run this app on CloudControl First, create a repository.

cctrlapp APP_NAME create java

Now add the MongoSoup addon to your repository (when in doubt about DEP_NAME, use "default").

cctrlapp APP_NAME/DEP_NAME addon.add mongosoup.sandbox

Third push your app to cloudControl (when in doubt about DEP_NAME, use "default").

cctrlapp APP_NAME/DEP_NAME push

Lastly deploy your app (when in doubt about DEP_NAME, use "default").

cctrlapp APP_NAME/DEP_NAME deploy

###Say hello Type in a browser window (if running on cloudControl, use your app's deployment URL)

http://localhost:8080/hello

###Create a person Type in a browser window (if running on cloudControl, use your app's deployment URL)

http://localhost:8080/persons.html

###Display/find a person

http://localhost:8080/persons/${alastname}

###Display all persons

http://localhost:8080/persons.json

###Credits

###License This project is released under the MIT License. Be aware of the Spring licenses!

springboot-gradle-cctrl-example's People

Contributors

agraphie avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.