szurubooru/config.yaml.dist

114 lines
3.6 KiB
Text
Raw Normal View History

# rather than editing this file, it is strongly suggested to create config.yaml
2016-04-06 20:38:45 +02:00
# and override only what you need.
name: szurubooru
debug: 0 # generate source maps for JS debugging?
transpile: 1 # generate bigger JS to support older browsers?
2016-04-06 20:38:45 +02:00
secret: change
api_url: # where frontend connects to, example: http://api.example.com/
2016-04-09 21:41:10 +02:00
base_url: # used to form links to frontend, example: http://example.com/
data_url: # used to form links to posts and avatars, example: http://example.com/data/
data_dir: # absolute path for posts and avatars storage, example: /srv/www/booru/client/public/data/
2016-04-06 20:38:45 +02:00
2016-04-09 21:41:10 +02:00
thumbnails:
avatar_width: 300
avatar_height: 300
post_width: 300
post_height: 300
2016-04-06 22:34:21 +02:00
2016-04-06 20:38:45 +02:00
database:
schema: postgres
host: # example: localhost
port: # example: 5432
user: # example: szuru
pass: # example: dog
name: # example: szuru
# used to send password reminders
smtp:
host: # example: localhost
port: # example: 25
user: # example: bot
pass: # example: groovy123
limits:
users_per_page: 20
posts_per_page: 40
max_comment_length: 5000
2016-04-15 23:02:30 +02:00
tag_name_regex: ^:?[a-zA-Z0-9_-]+$
2016-04-06 20:38:45 +02:00
# changing ranks after deployment may require manual tweaks to the database.
ranks:
- anonymous
- regular_user
- power_user
- mod
- admin
- nobody
2016-04-06 22:34:21 +02:00
rank_names:
anonymous: 'Anonymous user'
regular_user: 'Regular user'
power_user: 'Power user'
mod: 'Moderator'
admin: 'Administrator'
nobody: 'God'
2016-04-06 20:38:45 +02:00
default_rank: regular_user
# don't change these, unless you want to annoy people. if you do customize
# them though, make sure to update the instructions in the registration form
# template as well.
password_regex: '^.{5,}$'
user_name_regex: '^[a-zA-Z0-9_-]{1,32}$'
privileges:
'users:create': anonymous
'users:list': regular_user
'users:view': regular_user
'users:edit:any:name': mod
'users:edit:any:pass': mod
'users:edit:any:email': mod
'users:edit:any:avatar': mod
'users:edit:any:rank': mod
'users:edit:self:name': regular_user
'users:edit:self:pass': regular_user
'users:edit:self:email': regular_user
'users:edit:self:avatar': regular_user
'users:edit:self:rank': mod # one can't promote themselves or anyone to upper rank than their own.
'users:delete:any': admin
'users:delete:self': regular_user
'posts:create:anonymous': regular_user
'posts:create:identified': regular_user
'posts:list': anonymous
'posts:view': anonymous
'posts:edit:content': power_user
'posts:edit:flags': regular_user
'posts:edit:notes': regular_user
'posts:edit:relations': regular_user
'posts:edit:safety': power_user
'posts:edit:source': regular_user
'posts:edit:tags': regular_user
'posts:edit:thumbnail': power_user
'posts:feature': mod
'posts:delete': mod
'tags:create': regular_user
2016-04-15 23:02:30 +02:00
'tags:edit:names': power_user
2016-04-06 20:38:45 +02:00
'tags:edit:category': power_user
'tags:edit:implications': power_user
'tags:edit:suggestions': power_user
'tags:list': regular_user
'tags:masstag': power_user
'tags:merge': mod
'tags:delete': mod
'comments:create': regular_user
'comments:delete:any': mod
'comments:delete:own': regular_user
'comments:edit:any': mod
'comments:edit:own': regular_user
'comments:list': regular_user
'history:view': power_user