summaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
authorSadie Powell <sadie@witchery.services>2025-03-13 11:34:16 +0000
committerSadie Powell <sadie@witchery.services>2025-03-26 09:08:55 +0000
commitc60477384ca2dc47cc356a9a80925aed854c9d2f (patch)
tree66207fe5c2e572f36f2cc60485c45ecdf41fd50e /data
parent25c3fd51b7febfd754fa9718ab625a95bfd52c2b (diff)
Add the db_json module.
Diffstat (limited to 'data')
-rw-r--r--data/anope.example.conf52
1 files changed, 52 insertions, 0 deletions
diff --git a/data/anope.example.conf b/data/anope.example.conf
index 62f13b6a4..21f245272 100644
--- a/data/anope.example.conf
+++ b/data/anope.example.conf
@@ -1130,6 +1130,58 @@ module
}
/*
+ * db_json
+ *
+ * Stores your data in a JSON file. This is currently experimental and has not
+ * been fully tested so make sure you have db_flatfile loaded as a secondary
+ * database module if you use this.
+ */
+#module
+{
+ name = "db_json"
+
+ /*
+ * The file that db_json will write your main database to.
+ *
+ * This is relative to your data directory.
+ */
+ database = "anope.json"
+
+ /*
+ * The file that db_json will write third-party databases to.
+ *
+ * {name} will be replaced with the name of the module.
+ *
+ * This is relative to your data directory.
+ */
+ module_database = "{name}.module.json"
+
+ /*
+ * Sets how many days worth of backups should be kept.
+ *
+ * It is recommended that at the very least you keep one backup. Failure to
+ * do so may result in total data loss if you ever run out of disk space or
+ * have a power failure during a database write. However, if you're *REALLY*
+ * sure this won't happen you can disable backups by setting this to 0.
+ */
+ backups = 14
+
+ /*
+ * The directory in which backups are kept.
+ *
+ * This is relative to your data directory.
+ */
+ backup_directory = "backups"
+
+ /*
+ * Allows Anope to continue writing the database even if the original can
+ * not be backed up. This is not recommended as it may result in total data
+ * loss during the circumstances described above.
+ */
+ #ignore_backup_failure = yes
+}
+
+/*
* db_sql and db_sql_live
*
* db_sql module allows saving and loading databases using one of the SQL engines.