https://github.com/dnovikoff/mahjong-api
Riichi mahjong grpc api
https://github.com/dnovikoff/mahjong-api
api golang grpc mahjong riichi riichi-mahjong
Last synced: 2 months ago
JSON representation
Riichi mahjong grpc api
- Host: GitHub
- URL: https://github.com/dnovikoff/mahjong-api
- Owner: dnovikoff
- License: mit
- Created: 2019-02-27T21:36:30.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-03-02T18:20:54.000Z (over 2 years ago)
- Last Synced: 2025-03-24T09:47:11.042Z (3 months ago)
- Topics: api, golang, grpc, mahjong, riichi, riichi-mahjong
- Language: Go
- Homepage:
- Size: 5.91 MB
- Stars: 12
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# mahjong-api
[](https://github.com/dnovikoff/mahjong-api/actions?query=workflow%3ACI)
[](https://codecov.io/gh/dnovikoff/mahjong-api)
[](https://goreportcard.com/report/github.com/dnovikoff/mahjong-api)## Start the log server
In memory mode`go run ./cmd/log-server --config ./cmd/log-server/data/memory_config.yaml`
or in file mode (files will be in `./logdb` folder)
`go run ./cmd/log-server --config ./cmd/log-server/data/file_config.yaml`
Or write your own implementation to collect logs, generated by `mahjong-server`
## Start mahjong-server
Update to the latest version
`docker pull tempai/mahjong-server:latest`Run the server
`docker run -t -i -p 9090:9090 --rm tempai/mahjong-server:latest`The code for `mahjong-server` is **private**. Take note, that the `mahjong-server`
is not allowed to be used as a part of **commercial/non-commercial**
online mahjong server without authors permission.
Could be used for such scenarios as: **AI training**, **testing**, **research**.Please contact me or open an issue in case of found bugs in `mahjong-server` work.
# Run example client
`go run ./cmd/example-client --config ./cmd/example-client/data/config.yaml`The client will run a game with a bot and report a log to the `log-server`
# Alternative run with docker-compose
`docker-compose up --abort-on-container-exit`