Giter VIP home page Giter VIP logo

mixapi's Introduction

Mixapi

Unofficial API for the game mixmaster FR.
wikipedia link

Database schema

The database schema is available in the mixmaster-data repository.

You can also use Hibernate to initialise the database schema on API startup.

spring:
  jpa:
    hibernate:
      ddl-auto: update

How to ?

1. Override configuration

All the configuration of the application is present in ./app/src/main/resources/application.yml. If you need to edit some of the configuration you can do it in the application-local.yml yml file.

By doing so you can override the database connection or add some debugging config lines

# Local database config
spring:
  datasource:
    url: jdbc:mysql://127.0.0.1:3306/mixmaster?serverTimezone=UTC
    username: root
    password: root
  # Show SQL request executed by JPA
  jpa:
    show-sql: true

# Increase debug logging level
logging:
  level:
    org:
      hibernate:
        SQL: DEBUG
        type: trace

2. Maven commands

# Run the application
mvn spring-boot:run

# Execute the tests
mvn test

# Build the application
mvn clean install

# Or if you don't want the test to execute while building the jar
mvn clean install -DskipTests

Docker

To build the docker image and then launch it we use the following commands

docker build -t mixmaster-app/mixapi:latest .
docker run -p 0.0.0.0:3000:3000/tcp mixmaster-app/mixapi:latest

you can also use existing docker images available on GitHub container registry (https://ghcr.io): mixapi docker registry

Dev environment

To setup your own dev environment you'll need:

If you want to set up MySQL locally you can use the ./docker/dev/docker-compose.yml file to do so (On Windows this will require you to install docker-desktop).

For any configuration changes required you can create an ./app/src/main/resources/application-local.yml file which will override the main application.yml configs (cf. How to ?).

mixapi's People

Contributors

kiiow 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.