enigma-bbs/docs/config.md

129 lines
3.0 KiB
Markdown
Raw Normal View History

2016-03-29 04:58:06 +00:00
# Configuration
Configuration files in ENiGMA½ are simple UTF-8 encoded [HJSON](http://hjson.org/) files. HJSON is just like JSON but simplified and much more resilient to human error.
2017-02-10 03:48:44 +00:00
## System Configuration
2015-11-20 16:43:10 +00:00
The main system configuration file, `config.hjson` both overrides defaults and provides additional configuration such as message areas. The default path is `~/.config/enigma-bbs/config.hjson` though you can override this with the `--config` parameter when invoking `main.js`. Values found in core/config.js may be overridden by simply providing the object members you wish replace.
2017-02-10 04:08:23 +00:00
**Windows note**: **~** resolves to *C:\Users\YOURLOGINNAME\* on modern Windows installations, e.g. `C:\Users\NuSkooler\.config\enigma-bbs\config.hjson`
2016-07-02 20:16:01 +00:00
### oputil.js
Please see `oputil.js config` for configuration generation options.
2016-03-29 04:58:06 +00:00
### Example: System Name
`core/config.js` provides the default system name as follows:
```javascript
general : {
boardName : 'Another Fine ENiGMA½ System'
}
```
To override this for your own board, in `config.hjson`:
```hjson
general: {
boardName: Super Fancy BBS
}
```
2017-02-10 03:48:44 +00:00
(Note the very slightly different syntax. **You can use standard JSON if you wish**)
2016-03-29 04:58:06 +00:00
### Specific Areas of Interest
* [Menu System](menu_system.md)
* [Message Conferences](msg_conf_area.md)
* [Message Networks](msg_networks.md)
2017-02-10 03:48:44 +00:00
* [File Base](file_base.md)
* [File Archives & Archivers](archives.md)
2017-02-10 03:48:44 +00:00
* [Doors](doors.md)
* [MCI Codes](mci.md)
* [Web Server](web_server.md)
...and other stuff [in the /docs directory](./)
2016-03-29 04:58:06 +00:00
### A Sample Configuration
Below is a **sample** `config.hjson` illustrating various (but certainly not all!) elements that can be configured / tweaked.
**This is for illustration purposes! Do not cut & paste this configuration!**
```hjson
{
general: {
boardName: A Sample BBS
}
defaults: {
theme: super-fancy-theme
}
preLoginTheme: luciano_blocktronics
messageConferences: {
local_general: {
name: Local
desc: Local Discussions
default: true
areas: {
local_enigma_dev: {
name: ENiGMA 1/2 Development
desc: Discussion related to development and features of ENiGMA 1/2!
default: true
}
}
}
agoranet: {
name: Agoranet
desc: This network is for blatant exploitation of the greatest BBS scene art group ever.. ACiD.
areas: {
agoranet_bbs: {
name: BBS Discussion
desc: Discussion related to BBSs
}
}
}
}
messageNetworks: {
ftn: {
areas: {
agoranet_bbs: { /* hey kids, this matches above! */
// oh oh oh, and this one pairs up with a network below
network: agoranet
tag: AGN_BBS
uplinks: "46:1/100"
}
}
networks: {
agoranet: {
localAddress: "46:3/102"
}
}
}
}
scannerTossers: {
ftn_bso: {
schedule: {
import: every 1 hours or @watch:/home/enigma/bink/watchfile.txt
export: every 1 hours or @immediate
}
defaultZone: 46
defaultNetwork: agoranet
nodes: {
"46:*": {
archiveType: ZIP
encoding: utf8
}
}
}
}
}
```
2016-03-29 04:58:06 +00:00
## Menus
2017-02-10 03:48:44 +00:00
See [the menu system docs](menu_system.md)