[docs/zh] Update zh docs: synced to 6c879186 (#4117)

# Description

This PR updates the Chinese documentation to 6c879186 (the latest commit at present).

It also fixed a small typo in the original docs. Since the change is so minor, I didn't make a separate PR.

Last docs/zh update PR: #3884

## Checklist

Please put an x inside each checkbox to indicate that you've read and followed it: `[ ]` -> `[x]`

If this is a documentation change, only the first checkbox must be filled (you can delete the others if you want).

- [x] I/we have read the [GoToSocial contribution guidelines](https://codeberg.org/superseriousbusiness/gotosocial/src/branch/main/CONTRIBUTING.md).

Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4117
Co-authored-by: cdn0x12 <git@cdn0x12.dev>
Co-committed-by: cdn0x12 <git@cdn0x12.dev>
This commit is contained in:
cdn0x12 2025-05-03 09:28:16 +00:00 committed by tobi
commit 4d6408015b
18 changed files with 817 additions and 115 deletions

View file

@ -149,4 +149,21 @@ advanced-csp-extra-uris: []
# 选项: ["block", "allow", ""]
# 默认: ""
advanced-header-filter-mode: ""
# 布尔值。启用基于工作量证明的爬虫威慑机制,
# 作用于账户页和贴文页面。这将为每个 HTTP 客户端生成一个唯一确定
# 的质询,需要由客户端在访问上述端点时完成。
# 完成后,客户端会获得一个 Cookie允许其在 1 小时窗口内免验证访问。
#
# 这样做的结果是,它理论上使得对这些端点的抓取在经济上变得不可行,
# 同时对你自己的实例的性能影响可以忽略不计。
#
# 缺点是它要求客户端启用 JavaScript。
#
# 更多详情请查阅文档:
# https://docs.gotosocial.org/zh-cn/latest/admin/scraper_deterrence
#
# 选项: [true, false]
# 默认值: true
advanced-scraper-deterrence: false
```

View file

@ -42,6 +42,13 @@ create user gotosocial with password 'some_really_good_password';
grant all privileges on database gotosocial to gotosocial;
```
如果开始使用时你使用的是 Postgres 14 或更高版本,或者遇到 `error executing command: error creating dbservice: db migration error: ERROR: permission denied for schema public`,你应当授予你的 db 用户 `CREATE` 权限 *(这 **必须** 在连接到 gotosocial 数据库的 postgres shell 中执行)*:
```psql
GRANT CREATE ON SCHEMA public TO gotosocial;
SELECT has_schema_privilege('gotosocial', 'public', 'CREATE'); -- should return t
```
GoToSocial 使用 ULIDs全局唯一且按字典顺序可排序的标识符这在非英文排序环境中不起作用。因此创建数据库时使用 `C.UTF-8` 地区设置很重要。在已经使用非 C 地区初始化的系统上,必须使用 `template0` 原始数据库模板才能进行。
如果你希望使用特定选项连接到 Postgres可以使用 `db-postgres-connection-string` 定义连接字符串。如果 `db-postgres-connection-string` 已定义,则所有其他与数据库相关的配置字段将被忽略。例如,可以使用 `db-postgres-connection-string` 连接到 `mySchema`,用户名为 `myUser`,密码为 `myPass`,在 `localhost` 上,数据库名称为 `db`