<commit_before>`srnd.ini`
==========

`srnd.ini` is the configuration file for your NNTPChan node. Some configuration can be done initially through the web-interface (for now hopefully) but there is more that can be done by tweaking your `srnd.ini` file.

Below is the default state of the file. We will explain each section below.

````
[nntp]
instance_name=test.srndv2.tld
bind=127.0.0.1:1199
sync_on_start=1
allow_anon=0
allow_anon_attachments=0
allow_attachments=1
require_tls=1
anon_nntp=0
feeds=/etc/nntpchan/feeds.d
archive=0

[pprof]
enable=0
bind=127.0.0.1:17000

[crypto]
tls-keyname=overchan
tls-hostname=!!put-hostname-or-ip-of-server-here
tls-trust-dir=certs

[articles]
store_dir=articles
incoming_dir=/tmp/articles
attachments_dir=webroot/img
thumbs_dir=webroot/thm
convert_bin=/usr/bin/convert
ffmpegthumbnailer_bin=/usr/bin/ffmpeg
sox_bin=/usr/bin/sox
compression=0

[database]
type=redis
schema=single
host=localhost
port=6379
user
password

[cache]
type=file

[frontend]
enable=1
allow_files=1
regen_on_start=0
regen_threads=1
bind=[::]:18000
name=web.srndv2.test
webroot=webroot
prefix=/
static_files=contrib
templates=contrib/templates/default
translations=contrib/translations
locale=en
domain=localhost
json-api=0
json-api-username=fucking-change-this-value
json-api-password=<PASSWORD>
api-secret=RTZP5JZ2XGYCY===
````

##`[nntp]`

All NNTP server-related settings.

####instance_name

This is the name for your NNTP server. I don't really know what the point of it is, but hey its there (FIXME).

####bind

This is where you put the address and port that you would like the NNTP server to run on where `x` is the address and `y` is the port in `bind=x:y`.

####sync_on_start

* When this is set to `1` your NNTP server will sync articles with its peers on startup.
* When this is set to `0` then no syncing will take place on statup.

####allow_anon

* When this is set to `1` bluh.
* When this is set to `0` bluh.

####allow_anon_attachments

* When this is set to `1` bluh.
* When this is set to `0` bluh.

####allow_attachments

* When this is set to `1` posters may attach images to their posts.
* When this is set to `0` posters may not attach images to their posts.
<commit_msg>update definitions for allow_anon*<commit_after>`srnd.ini`
==========

`srnd.ini` is the configuration file for your NNTPChan node. Some configuration can be done initially through the web-interface (for now hopefully) but there is more that can be done by tweaking your `srnd.ini` file.

Below is the default state of the file. We will explain each section below.

````
[nntp]
instance_name=test.srndv2.tld
bind=127.0.0.1:1199
sync_on_start=1
allow_anon=0
allow_anon_attachments=0
allow_attachments=1
require_tls=1
anon_nntp=0
feeds=/etc/nntpchan/feeds.d
archive=0

[pprof]
enable=0
bind=127.0.0.1:17000

[crypto]
tls-keyname=overchan
tls-hostname=!!put-hostname-or-ip-of-server-here
tls-trust-dir=certs

[articles]
store_dir=articles
incoming_dir=/tmp/articles
attachments_dir=webroot/img
thumbs_dir=webroot/thm
convert_bin=/usr/bin/convert
ffmpegthumbnailer_bin=/usr/bin/ffmpeg
sox_bin=/usr/bin/sox
compression=0

[database]
type=redis
schema=single
host=localhost
port=6379
user
password

[cache]
type=file

[frontend]
enable=1
allow_files=1
regen_on_start=0
regen_threads=1
bind=[::]:18000
name=web.srndv2.test
webroot=webroot
prefix=/
static_files=contrib
templates=contrib/templates/default
translations=contrib/translations
locale=en
domain=localhost
json-api=0
json-api-username=<PASSWORD>-this-value
json-api-password=<PASSWORD>
api-secret=<KEY>===
````

##`[nntp]`

All NNTP server-related settings.

####instance_name

This is the name for your NNTP server. I don't really know what the point of it is, but hey its there (FIXME).

####bind

This is where you put the address and port that you would like the NNTP server to run on where `x` is the address and `y` is the port in `bind=x:y`.

####sync_on_start

* When this is set to `1` your NNTP server will sync articles with its peers on startup.
* When this is set to `0` then no syncing will take place on startup.

####allow_anon

* When this is set to `1`, posts made from anonymizing networks will be synced from peers.
* When this is set to `0`, posts made from anonymizing networks will not be synced from peers.

####allow_anon_attachments

* When this is set to `1`, attachments posted from anonymizing networks will be syncdd from peers.
* When this is set to `0`, attachments posted from anonymizing networks will not be synced from peers.

Nodes with `allow_anon_attachments` disabled will not receive threads with images posted from anonymizing networks. Likewise, the thread replies will not sync. In the case where an anonymized user posts an image reply and the node has `allow_anon_attachments` disabled, text posts without attachments replying to the non-synced image post will appear to be "ghosted".

####allow_attachments

* When this is set to `1` posters may attach images to their posts.
* When this is set to `0` posters may not attach images to their posts.

{'fraction_non_alphanumeric': 0.09847735811746094, 'fraction_numerical': 0.02175202689341507, 'mean_word_length': 5.19094247246022, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 4, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1814081', 'n_tokens_mistral': 1783, 'n_tokens_neox': 1708, 'n_words': 602}