ZiziBot.NETOfficial repository for Zizi.Bot, written in .NET

联合创作 · 2023-09-30 01:55

Zizi Bot .NET

Official repository WinTenDev Zizi Bot, written in .NET

Status

CodeFactor License Lines of code GitHub repo size

GitHub last commit GitHub commit activity GitHub commit activity

CI/CD

Preparation

  1. .NET 5 SDK
  2. MySQL/MariaDB
  3. Nginx or OpenLiteSpeed for reverse proxy (Optional)
  4. ClickHouse (Optional, for analytic)
  5. GoogleDrive API (Optional)
  6. Uptobox Token (For mirror)
  7. Datadog (Optional, for logging)

Run Development

  • Clone this repo and open .sln using your favorite IDE or Text Editor.
  • Install MySQL/MariaDB and create database e.g. zizibot.
  • Copy appsettings.example.json to appsettings.jon and fill some property.
  • Press Start in your IDE to start debugging or via CLI.
  • Your bot has ran local as Development using Poll mode.

Run Production

  • Install .NET 5 ASP.NET Runtime
  • Server with domain name include HTTPS support (e.g https://yoursite.co.id)
  • Run dotnet publish and upload your binary.
    If you use Rider, you can easily select Publish profile and Play to publish.
  • Setup proxy for Web Server with localhost:PORT, here example.
  • Launch your binary, then WebHook will automatically ensured (depending your EngineMode config on appsettings.json).

Run in Docker (Production)

  • docker-compose -f docker-compose.yml build
  • docker-compose -f docker-compose.yml up -d --scale zizi-bot=4 --no-recreate

Currently run on Zizi Bot and under beta in Zizi Beta Bot

浏览 8
点赞
评论
收藏
分享

手机扫一扫分享

编辑 分享
举报
评论
图片
表情
推荐
点赞
评论
收藏
分享

手机扫一扫分享

编辑 分享
举报