Skip to content
Docs
CFTools Discord Bot
Starting the application

Starting the application

Docker (preferred)

The quickest and easiest way to host/start this application is by deploying it inside a Docker (opens in a new tab) container.

💡
A docker-compose (opens in a new tab) file is included for your convenience
The tag and name option values can be anything you want, this is just an example

Build the project

Run docker build --tag my-cftools-discord-bot . to create your docker build

Start the bot

Start the bot with docker run -it --env-file .env --name my-cftools-discord-bot

NodeJS

Start the application using any of the following approaches, in preferred order:

  • npm run pm2:start to keep the process alive with PM2 (opens in a new tab), suitable for production environments. (npm i -g pm2 to install)
  • Use the node . command (stops the bot if you close the command prompt)
  • npm run start:dev if you have nodemon installed for automatic restarts on changes, suitable for development environments