Light Docs

Setting up

Run and properly set up the OmegaLicensing system.

Managed hosting

The steps below apply for local environments and self-hosted servers.

If running on a managed hosting, like the Light Services Hosting, Pebblehost or other Pterodactyl-based hosting, set the main file to index.js in the Startup tab and restart the bot.

Prerequisites

Before you start, you'll need to have the following:

You can validate that node.js is installed & the correct version by running:

node -v

Installation

Extract the contents of the ZIP file you received when you purchased the bot.

You should see, among other files, the index.js file, package.json and config.yml. Those 3 are the most important.

Open config.yml in your preferred editor (we recommend VSCode or Sublime Text, but this is up to your preference.)

Configure the options in config.yml. Most of them are self-explanatory if you've done this kind of thing above, but there is a detailed explanation below.

  • token - This is your bot's token, used for authenticating the bot on Discord. You can obtain a token for free from the Discord Developer Portal.

    Replace the text YOUR_BOT_TOKEN with the token. Keep the "".

    token: "YOUR_BOT_TOKEN"
  • databaseUrl - The bot requires a database. It can either be SQLite, MySQL, PostgreSQL or MSSQL.

    Sample SQLite configuration:

    databaseUrl: "sqlite://db.sqlite"

    Sample remote configuration:

    databaseUrl: "postgres://admin:admin@mydomain.com:2345/licensing"

    SQLite

    If you do not know how to configure a database or don't have one, use the SQLite sample.

    The bot creates tables automatically. There is no need to apply any migrations or otherwise create tables manually.

Once you've extracted the contents and configured the bot, navigate to the folder in your terminal and install the dependencies:

npm install

Then, run the following command to start the bot:

npm run start

This will run the index.js file, which will in turn start the bot.

Alternatively, you can run node index.js directly.