Skip to content

Installation and Configuration

iDarkLightning edited this page Jul 13, 2021 · 4 revisions

Installing and Configuring the Bot

Prerequisites

In order to use this bot, you must have docker and docker-compose installed on your system. You can learn how to install them here.

Installing

Once you are done installing those, you can follow this guide to set up a discord application.

After you have created a discord application, you can clone this repository like such:

git clone https://github.com/iDarkLightning/LiteBot.git

After cloning the repo, navigate to the cloned directory and run:

docker-compose up --build

On the first run, the config file will be generated at config/config.json

Configuring the Bot

Within the server server.properties of your server(s) configure these properties:

  • broadcast-rcon-to-ops should be set to false in order to ensure that the chat is not spammed for OP players from bot usage
  • enable-rcon must be set to true
  • rcon.port set to a unique port (not same as server port)
  • rcon.password create a secure password

You must fill in the following fields inside config.json:

  • token: The bot token for your discord app
  • prefixes: The prefixes that the bot will respond to
  • main_guild_id: The ID of the main guild that the bot will be used in
  • log_channel_id: The channel that log messages will be sent in
  • api_secret: The secret key to use for signing and validating tokens
  • servers: All the servers that the bot will have access to. You can add as many as you would like
    • name: The name of the server, and the key that will be used to access the server
    • numerical_server_ip: The server IP address
    • server_port: The port that the server is running on
    • rcon_port: The port that the RCON listener is running on (set in server.properties)
    • rcon_password: The RCON password you set in the server.properties
    • operator: Whether or not all players on the server should receive OP
    • bridge_channel_id: The "bridge" channel for the server. Meant for usage with the chat bridge plugin.

Configuring Settings

You can read about configuring the various settings for the bot here

Running

You can run the bot by running the following command inside the bot's directory:

docker-compose up # you can add -d if you would like the bot to run in the background

You can shut down the bot by running:

docker-compose down

Updating

Updating the bot is extremely simple. Simply run:

git pull

To pull the latest version of the bot from the git repository.

Clone this wiki locally