|
18 | 18 | </a>
|
19 | 19 | </div>
|
20 | 20 |
|
21 |
| -A Discord bot that does ~~all~~ most of the things - [atlasbot.xyz](https://atlasbot.xyz) |
| 21 | +Yet another Discord bot that tries to do everything - [atlasbot.xyz](https://atlasbot.xyz) |
22 | 22 |
|
23 | 23 | This is all the code that runs the bot portion of Atlas. The dashboard, API and other secret sauce will remain closed source for now. Contributions are welcome.
|
24 | 24 |
|
25 | 25 | ## Prerequisites
|
26 | 26 |
|
27 | 27 | - [Docker](https://docker.com/)
|
28 | 28 | - [docker-compose](https://docs.docker.com/compose/)
|
29 |
| -- [Node.js](https://nodejs.org/en/) >=10.0.0 (not required for self-hosting) |
| 29 | +- [Node.js](https://nodejs.org/en/) >=10.0.0 \* |
| 30 | + |
| 31 | +\* Required for development. If you're self-hosting, you can skip these requirements. |
30 | 32 |
|
31 | 33 | ## Installation
|
32 | 34 |
|
33 |
| -### Self-hosting |
| 35 | +Linux is recommended, but Docker means macOS, Windows and more or less anything that runs Docker will work. For development, anything that runs Node.js and Docker will work. |
| 36 | + |
| 37 | +#### Self-hosting |
34 | 38 |
|
35 | 39 | 1. Install [Docker](https://docs.docker.com/install/) and [docker-compose](https://docs.docker.com/compose/install/)
|
36 | 40 |
|
37 |
| -2. Clone this repo |
| 41 | +1. Clone this repo |
38 | 42 |
|
39 | 43 | ```bash
|
40 | 44 | git clone https://github.com/atlasbot/bot.git
|
41 | 45 | ```
|
42 | 46 |
|
43 |
| -3. Open a terminal in the cloned folder |
| 47 | +1. Open a terminal in the cloned folder |
| 48 | + |
| 49 | +1. Copy `.env.example` to `.env` and fill in the required env variables. See below for what most do. Google is your friend. |
44 | 50 |
|
45 |
| -4. Copy `.env.example` to `.env` and fill in the required env variables. See below for what most do. Google is your friend. |
| 51 | +1. Start the bot with `docker-compose up -d`. If you did everything right, then congratulations - you now have your own instance of Atlas. |
46 | 52 |
|
47 |
| -5. Start the bot with `docker-compose up -d`. If you did everything right, then congratulations - you now have your own instance of Atlas. |
| 53 | +#### Development |
48 | 54 |
|
49 |
| -### Development |
| 55 | +1. Install [Docker](https://docs.docker.com/install/), [docker-compose](https://docs.docker.com/compose/install/) and [Node.js](https://nodejs.org/en/) |
50 | 56 |
|
51 | 57 | 1. Clone this repo
|
52 | 58 |
|
53 | 59 | ```bash
|
54 | 60 | git clone https://github.com/atlasbot/bot.git
|
55 | 61 | ```
|
56 | 62 |
|
57 |
| -2. Open a terminal in the cloned folder |
| 63 | +1. Open a terminal in the cloned folder |
58 | 64 |
|
59 |
| -3. Run `npm i` to install dependencies |
| 65 | +1. Run `npm install` to install dependencies |
60 | 66 |
|
61 |
| -4. Copy `.env.example` to `.env` and replace any variables you would like. Setting `NODE_ENV` to `development` will enable extra features and help debugging things. Setting `DEBUG=*` may also help if you dont mind reading logs. `DEBUG=package:*` is also acceptable, e.g `DEBUG=monk:*` to listen to database debug messages. |
| 67 | +1. Copy `.env.example` to `.env` and replace any variables you would like. Setting `NODE_ENV` to `development` will enable extra features and help debugging things. Setting `DEBUG=*` may also help if you dont mind reading logs. `DEBUG=package:*` enables debug for specific packages, e.g `DEBUG=monk:*` to listen to database debug messages. |
62 | 68 |
|
63 |
| -5. Start Lavalink, Redis and Mongo via `docker-compose up -d mongo lavalink redis` |
| 69 | +1. Start Lavalink, Redis and Mongo via `docker-compose up -d mongo lavalink redis` |
64 | 70 |
|
65 | 71 | If you are using docker-compose to host these services, you can leave the defaults in `.env.example` for those services and it should be gucci.
|
66 | 72 |
|
67 |
| -6. Start the bot with `npm run dev` |
| 73 | +1. Start the bot with `npm run dev` |
68 | 74 |
|
69 |
| -7. Start breaking things. Once you save a file change, the bot will restart with the changes. Do `npm run start` to start the bot without watching files. |
| 75 | +1. Start breaking things. Once you save a file change, the bot will restart with the changes. Do `npm run start` to start the bot without watching files. |
70 | 76 |
|
71 | 77 | ## Environment Variables
|
72 | 78 |
|
@@ -100,11 +106,11 @@ _\* Optional, but some features may not work without them._
|
100 | 106 |
|
101 | 107 | The `NODE_ENV` environment variable must be set to `development` for these to work.
|
102 | 108 |
|
103 |
| -- To run a filter without it being enabled, include `Atlas:forceFilter:filter` with whatever you want to test. E.g, `Atlas:forceFilter:invites discord.gg/AXXBPM7` will force run the "invites" filter. |
| 109 | +- To run a filter without it being enabled, include `Atlas:forceFilter:filter` with whatever you want to test. E.g, `Atlas:forceFilter:invites discord.gg/AXXBPM7` will the "invites" filter to execute even when it's action type is `0`. |
104 | 110 |
|
105 | 111 | ## Disclaimer / Warning
|
106 | 112 |
|
107 |
| -At the time of writing this, there will be no support if you break anything. We are not responsible for anything you break, and won't help you if you do. If you don't know what you're doing, just use the public instance. |
| 113 | +If you're going to self-host Atlas, you won't get help with setting it up. We may refuse to support you with general issues. You are responsible if you break anything. Seriously, if you don't know what you're doing, just use the public instance. |
108 | 114 |
|
109 | 115 | ## Acknowledgements
|
110 | 116 |
|
|
0 commit comments