- Add the Discord bot to the server, if you haven't already.
- Install
node
on your machine, if you haven't already. - Install mysql, start your mysql server, and create a database for the bot.
- Create an
ormconfig.json
file like the following in the root of the project, including the configuration for the database you just created:
// ormconfig.json
{
"type": "mysql",
"host": "localhost",
"port": 3306,
"username": "<your mysql username>",
"password": "<your mysql password>",
"database": "<name of the database you just created>",
"synchronize": true,
"logging": false,
"entities": ["build/bot/database/entities/*.js"],
"migrations": ["build/bot/database/migrations/*.js"],
"subscribers": ["build/bot/database/subscribers/*.js"],
"cli": {
"entitiesDir": "build/bot/database/entities",
"migrationsDir": "build/bot/database/migrations",
"subscribersDir": "build/bot/database/subscribers"
}
}
- Create
private.ts
under thelib/bot/config/
directory, and populate it with these constants:
// private.ts
export const adminDiscordIds = ['<a discord ID you want monthly updates sent to>', ...];
export const databasePassword = '<password of the mysql database>';
export const discordBotId = '<the ID of your Discord bot's application>';
- Run
npm i
to install yournode_modules
. - Run
npm start
. - That's it!