rndzx / trace.moe-api

API server for serving backend requests for trace.moe

Home Page:https://soruly.github.io/trace.moe-api/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

trace.moe-api

License GitHub Workflow Status Discord

API server for trace.moe

API Docs

Features

  • serve image search request
  • crop black borders on search images
  • rate limiting and user management
  • serve server and database status
  • create solr cores
  • store and serve compressed hash files
  • serve workers and mange video and hash status

Prerequisites

  • Node.js 14.x
  • mariaDB 10.4.x
  • apache solr 7.x
  • redis
  • git
  • g++, cmake (for compiling OpenCV)
  • pm2

Install

Install Prerequisites first, then:

git clone https://github.com/soruly/trace.moe-api.git
cd trace.moe-api
npm install

Configuration

  • Copy .env.example to .env
  • Edit .env as appropriate for your setup

Start server

You can use pm2 to run this in background in cluster mode.

Use below commands to start / restart / stop server.

npm run start
npm run stop
npm run reload
npm run restart
npm run delete

To change the number of nodejs instances, edit ecosystem.config.json

About

API server for serving backend requests for trace.moe

https://soruly.github.io/trace.moe-api/

License:MIT License


Languages

Language:JavaScript 92.8%Language:HTML 6.1%Language:Shell 1.2%