Coder Social home page Coder Social logo

danielberes / avrae Goto Github PK

View Code? Open in Web Editor NEW

This project forked from avrae/avrae

0.0 0.0 0.0 6.82 MB

A Discord bot to streamline running D&D 5e.

Home Page: https://avrae.io

License: GNU General Public License v3.0

Python 99.83% Shell 0.09% Dockerfile 0.08%

avrae's Introduction

avrae

Build Status Codacy Badge

Avrae is a bot to facilitate running Dungeons & Dragons 5e online over Discord.

You can join the Avrae Development Discord here!

Contributing

How to run Avrae locally

Using Docker (Recommended)

Check out docker/readme.md.

Building Manually

OS Requirements

Avrae runs best on Ubuntu 16.04.4, but should be fully compatible with any UNIX-based system. It is possible to run Avrae on Windows, but is not recommended.

Creating Support Files

Avrae is a large project, and can be a bit daunting to get running. You'll need to create a few files first.

Credentials

credentials.py should include, at the very least, variables as such:

  • officialToken - Empty string.
  • owner_id - The Discord User ID of the bot owner (you, if testing).
  • test_redis_url - The URI of a Redis cache (e.g. redis://localhost:6379/0)
  • test_mongo_url - The URI of a MongoDB instance. (e.g. mongodb://localhost:27017)
  • testToken - A valid Discord Bot token.
  • test_dicecloud_user - A Dicecloud username.
  • test_dicecloud_pass - The Dicecloud password of the Dicecloud user.
  • test_dicecloud_token - A Dicecloud API token.

You'll also need to create a Google Drive Service Account. You can find instructions on how to do this here. Follow steps 1-3 in the Signed Credentials portion. Rename the JSON avrae-google.json and put it in the project root.

Temp Folders

You will need to create a folder named temp.

Actually Running Avrae
Redis

You will need to run a Redis instance to serve as a high-performance cache. Download Redis 4.0 and run a redis server locally before launching Avrae.

MongoDB

You will also need to run a MongoDB instance to serve as Avrae's database.

Avrae

To actually run Avrae, you need Python version >= 3.6.0 < 3.7. First, install the dependencies with pip install -r requirements.txt.

  • If running Avrae in unsharded mode (recommended for testing), run python dbot.py test.
  • If running Avrae in sharded mode, run python dbot.py.

Testing

To test Avrae, run these commands:

docker-compose -f docker-compose.test.yml -p avrae build
docker-compose -f docker-compose.test.yml -p avrae up -d
docker logs -f avrae_tests_1

This should initialize an ephemeral database to run command unit tests in. You should set the DICECLOUD_USER, DICECLOUD_PASS, DICECLOUD_TOKEN, and GOOGLE_SERVICE_ACCOUNT env vars to their correct values.

avrae's People

Contributors

croebh avatar infinidoge avatar madcowfred avatar nadizak avatar zhudotexe avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.