-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updating readme to reflect standalone project Signed-off-by: Diana <dmoore@xn4p4lm.com>
- Loading branch information
Showing
1 changed file
with
99 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,104 @@ | ||
# Bot-O-Cat: Bot - This is the bot portion of the [Bot-O-Cat](https://github.com/xN4P4LM-org/bot-o-cat) | ||
# Bot-O-Cat | ||
|
||
[![Linting](https://github.com/xN4P4LM-org/bot-o-cat_bot/actions/workflows/lint.yaml/badge.svg)](https://github.com/xN4P4LM-org/bot-o-cat_bot/actions/workflows/lint.yaml) | ||
[![Linting](https://github.com/xN4P4LM-org/bot-o-cat/actions/workflows/lint.yaml/badge.svg)](https://github.com/xN4P4LM-org/bot-o-cat/actions/workflows/lint.yaml) | ||
|
||
## Contributing guidelines | ||
### ( This is a work in progress - use at your own risk ) | ||
|
||
If you would like to contribute to the project, please navigate to the [Bot-O-Cat](https://github.com/xN4P4LM-org/bot-o-cat) repository and follow the [CONTRIBUTING.md](https://github.com/xN4P4LM-org/bot-o-cat/blob/main/CONTRIBUTING.md) guidelines. | ||
## Overview | ||
|
||
## Running the bot standalone (Optional) | ||
This is a general purpose bot where the primary intention is to enable server owners, as well as third parties to create a bot that is tailored to their specific need or uses cases. The bot is designed to be modular. You can add new features and functionality without the need to modify the core codebase or you can create your own bot using this as a framework. | ||
|
||
You can run the bot standalone with the following dockerfile: | ||
## Features | ||
|
||
This is also part of a comprehensive service, more information can be found over on the service's page: [discord-bot-o-cat-service](https://github.com/xN4P4LM-org/discord-bot-o-cat-service) | ||
|
||
## Running the bot | ||
|
||
To run this bot you will use the following `docker-compose` file and a docker compatible environment. | ||
|
||
```yaml | ||
version: "3" | ||
services: | ||
bot: | ||
container_name: discord-bot | ||
build: ./bot | ||
environment: | ||
- DISCORD_BOT_DESCRIPTION="A simple discord bot" | ||
- DISCORD_BOT_TOKEN= | ||
- DISCORD_BOT_OWNER_ID= | ||
- DISCORD_BOT_COMMAND_PREFIX=. | ||
- DISCORD_BOT_LOG_LEVEL=20 # 10=DEBUG, 20=INFO, 30=WARNING, 40=ERROR, 50=CRITICAL | ||
- DISCORD_MONGO_DB_HOST_NAME=mongo-db | ||
- DISCORD_MONGO_DB_PORT=27017 | ||
volumes: | ||
- discord_cogs:/bot/cogs | ||
- discord_git_ssh:/root/.ssh | ||
depends_on: | ||
mongo-db: | ||
condition: service_healthy | ||
restart: true | ||
|
||
mongo-db: | ||
container_name: discord-mongodb | ||
build: ./db | ||
environment: | ||
- MONGO_INITDB_ROOT_USERNAME= | ||
- MONGO_INITDB_ROOT_PASSWORD= | ||
volumes: | ||
- discord_db:/data/db | ||
healthcheck: | ||
test: mongosh mongo-db:27017/test --tls --tlsCertificateKeyFile /etc/ssl/mongo-db.pem --tlsCAFile /etc/ssl/ca.pem --quiet --eval 'db.runCommand({ping:1})' | ||
interval: 10s | ||
timeout: 5s | ||
retries: 3 | ||
start_period: 5s | ||
|
||
# api: | ||
# container_name: discord-api | ||
# build: ./api | ||
# environment: | ||
# - API_PORT=8443 | ||
# ports: | ||
# - "8443:8443" | ||
# volumes: | ||
# - discord_api_ssl_certs:/etc/letsencrypt/live/ | ||
|
||
# api: | ||
# container_name: discord-web | ||
# build: ./web | ||
# environment: | ||
# - WEB_PORT=8443 | ||
# ports: | ||
# - "8443:8443" | ||
# volumes: | ||
# - discord_web_ssl_certs:/etc/letsencrypt/live/ | ||
|
||
volumes: | ||
discord_cogs: | ||
discord_git_ssh: | ||
discord_db: | ||
#discord_api_ssl_certs: | ||
#discord_web_ssl_certs: | ||
``` | ||
|
||
## Required environment variables | ||
|
||
- `DISCORD_BOT_DESCRIPTION` - The description of the bot | ||
- `DISCORD_BOT_TOKEN` - Discord Token for your bot from the Discord Developer Portal | ||
- `DISCORD_BOT_OWNER_ID` - The Bot Owner's user id | ||
- `DISCORD_BOT_COMMAND_PREFIX` - Command Prefix Ex. `!` | ||
- `DISCORD_BOT_LOG_LEVEL` - the int log level `(10, 20, 30, 40, 50)` | ||
- `MONGO_INITDB_ROOT_USERNAME` - The root user for MongoDB | ||
- `MONGO_INITDB_ROOT_PASSWORD` - The root password for MongoDB | ||
|
||
# Contributing | ||
|
||
If you would like to contribute to the project, please read both the [CONTRIBUTING.md](CONTRIBUTING.md) and the [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md) guidelines. | ||
|
||
Features request can be submitted by using [GitHub Issues](https://github.com/xn4p4lm-org/bot-o-cat/issues). | ||
|
||
All code, comments, and critiques are greatly appreciated. | ||
|
||
# License | ||
|
||
Bot-O-Cat and all components are licensed under the Apache License, Version 2.0. See [LICENSE](LICENSE) for the full license text. |