mirror of
https://github.com/versia-pub/server.git
synced 2025-12-06 08:28:19 +01:00
fix(config): 🐛 Make some default config values more sensible
This commit is contained in:
parent
f9dcbb1be8
commit
c0805ff125
|
|
@ -31,7 +31,7 @@ enabled = true
|
|||
# Redis instance to be used as a timeline cache
|
||||
# Optional, can be the same as the queue instance
|
||||
host = "localhost"
|
||||
port = 40004
|
||||
port = 6380
|
||||
password = ""
|
||||
database = 1
|
||||
enabled = false
|
||||
|
|
@ -39,7 +39,7 @@ enabled = false
|
|||
[sonic]
|
||||
# If Sonic is not configured, search will not be enabled
|
||||
host = "localhost"
|
||||
port = 40007
|
||||
port = 7700
|
||||
password = ""
|
||||
enabled = true
|
||||
|
||||
|
|
@ -187,17 +187,17 @@ convert_vector = false
|
|||
[validation]
|
||||
# Checks user data
|
||||
# Does not retroactively apply to previously entered data
|
||||
max_displayname_size = 50
|
||||
max_bio_size = 160
|
||||
max_displayname_size = 50 # Character length
|
||||
max_bio_size = 5000
|
||||
max_note_size = 5000
|
||||
max_avatar_size = 5_000_000
|
||||
max_avatar_size = 5_000_000 # Bytes
|
||||
max_header_size = 5_000_000
|
||||
max_media_size = 40_000_000
|
||||
max_media_attachments = 10
|
||||
max_media_description_size = 1000
|
||||
max_poll_options = 20
|
||||
max_poll_option_size = 500
|
||||
min_poll_duration = 60
|
||||
min_poll_duration = 60 # Seconds
|
||||
max_poll_duration = 1893456000
|
||||
max_username_size = 30
|
||||
max_field_count = 10
|
||||
|
|
@ -205,8 +205,7 @@ max_field_name_size = 1000
|
|||
max_field_value_size = 1000
|
||||
# Forbidden usernames, defaults are from Akkoma
|
||||
username_blacklist = [
|
||||
".well-known",
|
||||
"~",
|
||||
"well-known",
|
||||
"about",
|
||||
"activities",
|
||||
"api",
|
||||
|
|
@ -293,7 +292,7 @@ placeholder_style = "thumbs"
|
|||
[federation]
|
||||
# This is a list of domain names, such as "mastodon.social" or "pleroma.site"
|
||||
# These changes will not retroactively apply to existing data before they were changed
|
||||
# For that, please use the CLI
|
||||
# For that, please use the CLI (in a later release)
|
||||
|
||||
# These instances will not be federated with
|
||||
blocked = []
|
||||
|
|
|
|||
|
|
@ -578,7 +578,7 @@
|
|||
},
|
||||
"max_bio_size": {
|
||||
"type": "integer",
|
||||
"default": 160
|
||||
"default": 5000
|
||||
},
|
||||
"max_note_size": {
|
||||
"type": "integer",
|
||||
|
|
@ -642,8 +642,7 @@
|
|||
"type": "string"
|
||||
},
|
||||
"default": [
|
||||
".well-known",
|
||||
"~",
|
||||
"well-known",
|
||||
"about",
|
||||
"activities",
|
||||
"api",
|
||||
|
|
@ -1932,7 +1931,7 @@
|
|||
"additionalProperties": false,
|
||||
"default": {
|
||||
"max_displayname_size": 50,
|
||||
"max_bio_size": 160,
|
||||
"max_bio_size": 5000,
|
||||
"max_note_size": 5000,
|
||||
"max_avatar_size": 5000000,
|
||||
"max_header_size": 5000000,
|
||||
|
|
@ -1948,8 +1947,7 @@
|
|||
"max_field_name_size": 1000,
|
||||
"max_field_value_size": 1000,
|
||||
"username_blacklist": [
|
||||
".well-known",
|
||||
"~",
|
||||
"well-known",
|
||||
"about",
|
||||
"activities",
|
||||
"api",
|
||||
|
|
|
|||
|
|
@ -283,7 +283,7 @@ export const configValidator = z.object({
|
|||
validation: z
|
||||
.object({
|
||||
max_displayname_size: z.number().int().default(50),
|
||||
max_bio_size: z.number().int().default(160),
|
||||
max_bio_size: z.number().int().default(5000),
|
||||
max_note_size: z.number().int().default(5000),
|
||||
max_avatar_size: z.number().int().default(5000000),
|
||||
max_header_size: z.number().int().default(5000000),
|
||||
|
|
@ -301,8 +301,7 @@ export const configValidator = z.object({
|
|||
username_blacklist: z
|
||||
.array(z.string())
|
||||
.default([
|
||||
".well-known",
|
||||
"~",
|
||||
"well-known",
|
||||
"about",
|
||||
"activities",
|
||||
"api",
|
||||
|
|
@ -371,7 +370,7 @@ export const configValidator = z.object({
|
|||
})
|
||||
.default({
|
||||
max_displayname_size: 50,
|
||||
max_bio_size: 160,
|
||||
max_bio_size: 5000,
|
||||
max_note_size: 5000,
|
||||
max_avatar_size: 5000000,
|
||||
max_header_size: 5000000,
|
||||
|
|
@ -387,8 +386,7 @@ export const configValidator = z.object({
|
|||
max_field_name_size: 1000,
|
||||
max_field_value_size: 1000,
|
||||
username_blacklist: [
|
||||
".well-known",
|
||||
"~",
|
||||
"well-known",
|
||||
"about",
|
||||
"activities",
|
||||
"api",
|
||||
|
|
|
|||
Loading…
Reference in a new issue