All Projects → jonas747 → Yagpdb

jonas747 / Yagpdb

Licence: mit
Yet another general purpose discord bot

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to Yagpdb

Switchblade
The open source Discord bot that solves all of your problems.
Stars: ✭ 285 (-36.95%)
Mutual labels:  bot, discord-bot, discord
Discord bot.py
🍺 A simple discord bot that helps you getting started within discord.py
Stars: ✭ 313 (-30.75%)
Mutual labels:  bot, discord-bot, discord
Mathbot
Discord bot for mathematics
Stars: ✭ 207 (-54.2%)
Mutual labels:  bot, discord-bot, discord
Mantarobot
Multipurpose Discord bot made in Java using JDA.
Stars: ✭ 282 (-37.61%)
Mutual labels:  bot, discord-bot, discord
Commando
Official command framework for discord.js
Stars: ✭ 434 (-3.98%)
Mutual labels:  bot, discord-bot, discord
Master Bot
A Discord music bot with playlist support, music quiz, saved playlists, lyrics, gifs and more
Stars: ✭ 204 (-54.87%)
Mutual labels:  bot, discord-bot, discord
Nostrum
Elixir Discord Library
Stars: ✭ 274 (-39.38%)
Mutual labels:  bot, discord-bot, discord
Carl Bot
Bot for discord using discord.py (outdated code)
Stars: ✭ 160 (-64.6%)
Mutual labels:  bot, discord-bot, discord
Giveawaybot
🎉 Hold giveaways quickly and easily on your Discord server!
Stars: ✭ 290 (-35.84%)
Mutual labels:  bot, discord-bot, discord
Loritta
💁 A multipurpose, multilanguage, customizable, modular, and very cute bot for Discord using JDA! ~Making your server more awesome~
Stars: ✭ 253 (-44.03%)
Mutual labels:  bot, discord-bot, discord
Discord Spam Bots
Discord spam bots with multiple account support, account creator, auto-join, proxies, mass direct message and more.
Stars: ✭ 173 (-61.73%)
Mutual labels:  bot, discord-bot, discord
Javacord
An easy to use multithreaded library for creating Discord bots in Java.
Stars: ✭ 368 (-18.58%)
Mutual labels:  bot, discord-bot, discord
Discord.ts
🤖 Create your discord bot by using TypeScript and decorators!
Stars: ✭ 172 (-61.95%)
Mutual labels:  bot, discord-bot, discord
Xiao
Xiao is a Discord bot coded in JavaScript with discord.js using the Commando command framework. With over 500 commands, she is one of the most feature-rich bots out there. Formerly XiaoBot.
Stars: ✭ 302 (-33.19%)
Mutual labels:  bot, discord-bot, discord
Lenoxbot
🖥️ LenoxBot is a Discord bot that offers many cool new features to your Discord server!
Stars: ✭ 163 (-63.94%)
Mutual labels:  bot, discord-bot, discord
Bastion
🚀 Get an enhanced Discord experience!
Stars: ✭ 234 (-48.23%)
Mutual labels:  bot, discord-bot, discord
Amongcord
Among Us Discord Bot | Discord bot for controlling voice channels during Among Us matches
Stars: ✭ 144 (-68.14%)
Mutual labels:  bot, discord-bot, discord
Octave
Discord bot written in Java and Kotlin using JDA.
Stars: ✭ 156 (-65.49%)
Mutual labels:  bot, discord-bot, discord
Sidekick
Dice and LFG bot for Discord.
Stars: ✭ 254 (-43.81%)
Mutual labels:  bot, discord-bot, discord
Livebot
An app that allows you to be inside a bot!
Stars: ✭ 271 (-40.04%)
Mutual labels:  bot, discord-bot, discord

YAGPDB

Yet another general purpose discord bot

YAGPDB is a multifunctional, modular Discord bot. It's modular in that plugins exist for the most part on their own (with exceptions to some lazy things in the main stylesheet), some plugins do however depend on other plugins (most plugins depend on the commands plugin, for example).

Links

Running YAGPDB yourself

Running this bot may seem challenging, and that's because I don't have time to make it easy to run for everyone, for the most part, it should run fine after the initial work has been done. Please view this page for more information.

Updating

Updating after v1 should migrate schemas automatically, but you should always take backups beforehand if things go wrong.

I will put breaking changes in the breaking_changes.md file, which you should always read before updating.

There's 2 ways of running this bot

  1. Using Docker
  2. Standalone

I will not help with basic problems or how to do unrelated things (how to run it on startup for example), use Google, if those well written tutorials and articles confuse you, how the hell is a guy with English as a second language gonna be any better?

(There's still a lot of contributing you can do without this though, such as writing docs, fixing my horrible typos and so on)

General Discord bot setup

Directions on creating an app and getting credentials may be found here. YAGPDB does not require you to authorize the bot: all of that will be handled via the Control Panel.

In addition, you will need to add the following urls to the bot's "REDIRECT URI(S)" configuration:

Docker quickstart

If you have docker-compose installed, it will offer the fastest route to getting up-and-running.

git clone https://github.com/jonas747/yagpdb
cp yagpdb/yagpdb_docker/{app.example.env,app.env}
cp yagpdb/yagpdb_docker/{db.example.env,db.env}

Edit app.env and db.env to specify the Discord bot values from above.

Make sure ports 80 and 443 are accessible on your network and launch:

docker-compose -f yagpdb/yagpdb_docker/docker-compose.yml up

The bot will connect automatically and the control panel will be available via your host after a short setup.

If you are running several bots (or other websites alongside the bot), consider running a proxy such as jrcs/letsencrypt-nginx-proxy-companion.

First, start the proxy. This needs to be started only once and is shared by all websites:

docker network create proxy-tier
docker-compose -p proxy yagpdb/yagpdb_docker/docker-compose.proxy.yml up

And then start the bot using the proxy:

docker-compose -f yagpdb/yagpdb_docker/docker-compose.proxied.yml up

Standalone/Manual setup

Requirements

  • Fairly recent go version (1.11 or later, I use new features as soon as they're out, so watch out in breaking_changes)
  • PostgreSQL 9.6 or later
  • Redis version 3.x or later (maybe it's possible to get it working with earlier versions, however I'm not 100% sure)

I may update the bot at any point to require newer versions of any of these, so you should ALWAYS check breaking_changes before updating.

First step is to set those up and get them running:

  1. Install and configure redis and postgres with your desired settings (my DM's are not Google, you'll have to figure at least this much out on your own...)
  2. Create a user named yagpdb and database named yagpdb which the user yagpdb has write access to
  3. Update your env vars with the config (see example env file in cmd/yagpdb/)
  4. Done.

Steps for building:

YAGPDB currently uses a lot of alternative branches of my projects, mainly because I also use a discordgo fork with a lot of goodies in it (why not push my changes upstream? Cause a ton of breaking changes that would never get accepted)

I'm working towards making YAGPDB fully go get ...-able

git clone -b yagpdb https://github.com/jonas747/discordgo $GOPATH/src/github.com/jonas747/discordgo
git clone -b dgofork https://github.com/jonas747/dutil $GOPATH/src/github.com/jonas747/dutil
git clone -b dgofork https://github.com/jonas747/dshardmanager $GOPATH/src/github.com/jonas747/dshardmanager
go get -v -d github.com/jonas747/yagpdb/cmd/yagpdb
cd $GOPATH/src/github.com/jonas747/yagpdb/cmd/yagpdb
go build

After this, unless you wanna run it in testing mode using YAGPDB_TESTING=yes you have to run cmd/yagpdb/copytemplates.sh to copy all the plugin specific template files into the cmd/yagpdb/templates/plugins folder.

You can now run ./yagpdb

Configuration is done through environment variables. See cmd/yagpdb/sampleenvfile for what environment variables are available.

You can run the web server, bot, reddit and youtube parts as separate processes (some smallish limitations require to to run it on the same machine, will likely be removed soon as I'm gonna need to work on horizontal scaling soon)

You specify -bot to run the bot, -web to run the web server, -feeds "youtube,reddit" to run the reddit and youtube feeds.

The web server by default (unless -pa) listens on 5000(http) and 5001(https) So if you're behind a NAT, forward those, if not you can either use the -pa switch or add an entry to iptables.

Plugins

Standard plugins:

  • Youtube-Feed
  • Stream-announcements
  • Server Stats
  • Soundboard
  • Reputation
  • Reminder
  • Reddit-Feed
  • Notifications
  • Moderation
  • Logs
  • Custom commands
  • And More!

Planned plugins

See the Issues Tab for more

Core packages:

  • Web: The core web server package, in charge of authentication.
  • Bot: Core bot package, delegates events to plugins.
  • Common: Handles all the common stuff between web and bot (config, discord session, redis pool etc).
  • Feeds: Handles all feeds, personally I like to run each feed as its own service, that way I can start and stop individual feeds without taking everything down.
  • Commands: Handles all commands.

Currently, YAGPDB builds everything into one executable and you run the bot with the -bot switch, the web server with the -web switch and so on (see -h for help).

Databases

YAGPDB uses redis for light data and caching (and some remnants of configuration).

It uses PostgreSQL for most configuration and more heavy data (logs and such).

Contributing new features

See bot/plugin for info about bot plugins, web/plugin for web plugins and feeds/plugin for feeds if you wanna make a new fully fledged plugin.

Expect web, bot and feed instances to be run separately.

For basic utility/fun commands, you can just jam them in stdcommands. Use the existing commands there as an example of how to add one.

If you need any help finding things in the source or have any other questions, don't be afraid of messaging me.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].