Cero is a card game web application based on Crazy Eights. The UI and API for Cero is split between two code bases: cero-ui
and cero-api
.
This API, built on Spring Boot, is the interface between the Redis session store and the cero-ui frontend.
This project is still a work in progress, and as such there are milestones yet to hit before hitting the first major release.
- works with cero-ui
- dockerize
- swagger ui
- validate card IDs
- unit tests
Most setups will require:
docker
docker-compose
A development setup can be run without docker using just:
java 15
redis
To run this app locally:
- Run
docker-compose up
- Follow the API docs from
http://localhost:8080/api-docs
.
To set up an environment for development:
- To run the application:
./mvnw spring-boot:run -Dspring-boot.run.profiles=dev
- Spin up a redis store. Either do this with a local redis install or use the redis docker image provided the dev docker-compose config by running
docker-compose -f docker-compose.dev.yaml up
Although a Cero production environment is actually created from the docker files in the Cero UI project as it contains the reverse proxy, an API-only deployment is possible using the same docker-compose
config as the local environment setup:
So after connecting to your host server:
- Copy over the
docker-compose.yaml
file from the project root onto your host server. - Run
docker-compose up
- Follow the API docs from
http://<your ip or host>:8080/api-docs
.