You can deploy the full Jikan REST stack using Docker Compose. The setup includes the jikan_rest API service, mongodb for data storage, redis for caching, and typesense for search functionality.
Key Configuration Requirements
Environment Variables
Several parameters can be tuned via environment variables or an .env file:
_JIKAN_API_VERSION: Specifies the version of the Jikan API image to use (defaults to latest).APP_UID / APP_GID: Sets the user and group ID for the jikan_rest process (defaults to 10001).MONGO_CACHE_SIZE_GB: Configures the WiredTiger cache size for MongoDB (defaults to 1.0).
Secrets
The deployment relies on Docker secrets for sensitive credentials. You must provide the following files in your environment:
db_username.txt / db_password.txt: Database credentials.db_admin_username.txt / db_admin_password.txt: MongoDB admin credentials.redis_password.txt: Redis authentication password.typesense_api_key.txt: Typesense API key.
Networking and Ports
- Jikan REST API: Accessible on port
8080. - MongoDB: Port
27017. - Redis: Port
6379. - Typesense: Port
8108.
Configuration File
The jikan_rest service loads additional configuration from ./docker/config/.env.compose.
# Example of how the service is defined in docker-compose.yml
services:
jikan_rest:
image: "docker.io/jikanme/jikan-rest:${_JIKAN_API_VERSION:-latest}"
user: "${APP_UID:-10001}:${APP_GID:-10001}"
ports:
- '8080:8080/tcp'
env_file:
- ./docker/config/.env.compose