Skip to content

openbrewerydb/openbrewerydb-java-api

Repository files navigation

openbrewerydb-java-api

Dependencies

  • Java 16 (See SDKMan for JDK management)
  • Gradle
  • Docker
  • Docker Compose

Getting Started

Quick

The run script will build the app, dockerize it, and deploy to docker compose automatically.

./run_it.sh

Manual

  • Run ./gradlew clean build to build the .jar locally.
  • Dockerize it with docker build ..
  • Substitute the tag in the docker.compose.yml file and run docker-compose up -d to deploy it locally.

Useful Docker Commands

  • docker-compose ps - Shows which docker containers are running.
  • docker logs -f openbrewerydb - Shows the server logs.
  • docker-compose stop - Stops all containers
  • docker-compose up - Starts all containers, or restarts if there were changes.

Running Dependency Analysis

We can run a dependency check analysis that will show us vulnerabilities. This command will start the analysis:

./gradlew dependencyCheckAnalyze

This will output an HTML and JSON file in the /build/reports/ directory.