Merge branch 'development' of github.com:clicksminuteper/nucleus into development
diff --git a/README.md b/README.md
index 175654c..3505970 100644
--- a/README.md
+++ b/README.md
@@ -73,4 +73,4 @@
### Self hosting
-Nucleus is fully open source, and you can run your own copy. Read [COPYING.md](https://github.com/ClicksMinutePer/Nucleus/blob/development/COPYING.md) for the legal requirements and a guide for how to configure your own copy.
+Nucleus is fully open source, and you can run your own copy. Read [SELF_HOSTING.md](https://github.com/ClicksMinutePer/Nucleus/blob/development/SELF_HOSTING.md) for the legal requirements and a guide for how to configure your own copy.
diff --git a/SELF HOSTING.md b/SELF_HOSTING.md
similarity index 99%
rename from SELF HOSTING.md
rename to SELF_HOSTING.md
index dfe4882..86f267c 100644
--- a/SELF HOSTING.md
+++ b/SELF_HOSTING.md
@@ -25,6 +25,7 @@
## How to:
We hide the config file with our important data like the bot token. Below you can find a copy of `src/config/main.json`.
+Alternatively, you can run `Installer.js` to generate it for you.
```json
{
@@ -40,6 +41,8 @@
"mongoUrl": "mongodb://your-mongo-ip-and-port",
"baseUrl": "your website url, e.g. https://clicks.codes",
"pastebinApiKey": "your-pastebin-api-key"
+ "pastebinUsername": "your-pastebin-username"
+ "pastebinPassword": "your-pastebin-password"
}
```
diff --git a/src/config/format.js b/src/config/format.js
index 3d4af8d..bdd3fdb 100644
--- a/src/config/format.js
+++ b/src/config/format.js
@@ -3,15 +3,15 @@
import { exec } from 'node:child_process';
const defaultDict = {
- "token": "Your bot token",
- "developmentToken": "Your development bot token",
- "managementGuildID": "Your management guild ID",
+ "developmentToken": "Your development bot token (Used for testing in one server, rather than production)",
"developmentGuildID": "Your development guild ID",
"enableDevelopment": true,
+ "token": "Your bot token",
+ "managementGuildID": "Your management guild ID (Used for running management commands on the bot)",
"owners": [],
- "verifySecret": "If using verify, enter a code here which matches your website if needed",
+ "verifySecret": "If using verify, enter a code here which matches the secret sent back by your website. You can use a random code if you do not have one already. (Optional)",
"mongoUrl": "Your Mongo connection string, e.g. mongodb://127.0.0.1:27017",
- "baseUrl": "Your website where buttons such as Verify will link to, e.g. https://example.com",
+ "baseUrl": "Your website where buttons such as Verify and Role menu will link to, e.g. https://example.com",
"pastebinApiKey": "An API key for pastebin (optional)",
"pastebinUsername": "Your pastebin username (optional)",
"pastebinPassword": "Your pastebin password (optional)",
@@ -78,6 +78,7 @@
else { json[key] = defaultDict[key] }
}
}
+ if (walkthrough && !json.mongoUrl) json.mongoUrl = "mongodb://127.0.0.1:27017"
if (!json.mongoUrl.endsWith("/")) json.mongoUrl += "/";
if (!json.baseUrl.endsWith("/")) json.baseUrl += "/";
let hosts;