Skip to content

Registers meigens from captured image on Discord.

License

Notifications You must be signed in to change notification settings

approvers/cadocr

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cadocr

.NET Core Docker
Registers meigens from captured image on Discord.

Prerequisites

  • .NET Core Runtime 3.1 or Docker with Compose 3.8+
  • A application on Discord with bot access
  • An IAM user on Google Cloud Platform with Cloud Vision access

Installation

Using Docker

  1. Pull an image from GitHub Packages Registry.
  2. Configure with environment variables or appsettings.local.json .
  3. Create and run a container with the image.

Otherwise

  1. Clone this repository.
  2. Configure with environment variables or appsettings.local.json .
  3. Build the project with dotnet build -c Release -o bin .
  4. Run the built application with docker ./bin/Cadocr.dll .

Configuration

Using environment variables

Discord__Bot__Token="[YOUR DISCORD BOT TOKEN]"
CloudVision__Credentials__Path="[YOUR CLOUDVISION CREDENTIALS JSON PATH]"

Using appsettings.local.json

{
  "Discord": {
    "Bot": {
      "Token": "[YOUR DISCORD BOT TOKEN]"
    }
  },
  "CloudVision": {
    "Credentials": {
      "Path": "[YOUR CLOUDVISION CREDENTIALS JSON PATH]"
    }
  }
}

If you are using Docker, make sure you mounted the config file to your container.

volumes:
  - ./appsettings.local.json:/app/appsettings.local.json:ro