summaryrefslogtreecommitdiff
path: root/Documentation/source/zh_CN/operations.rst
diff options
context:
space:
mode:
authorBertrand Yuan <me@bertyuan.com>2026-04-27 20:52:54 +0800
committerBertrand Yuan <me@bertyuan.com>2026-04-27 20:53:14 +0800
commitdbb5e791f0c228369605d126dd590962ebe1eddc (patch)
tree8c83fc84bd9547630e6733929dec77e102e055a8 /Documentation/source/zh_CN/operations.rst
parent658798b3a2378bb6df16cfbb16d707c6fb719e1e (diff)
docs: add comprehensive documentation for operations
This commit introduces a complete set of documentation files covering various aspects of the project, including environment setup, quality checks, command references, and architecture. The documentation is structured to assist developers and contributors in understanding the project's configuration, workflow, and best practices. Additionally, translations for Simplified and Traditional Chinese have been added to ensure accessibility for a wider audience. This enhances the overall usability and maintainability of the project. Signed-off-by: Bertrand Yuan <github@bertyuan.com>
Diffstat (limited to 'Documentation/source/zh_CN/operations.rst')
-rw-r--r--Documentation/source/zh_CN/operations.rst65
1 files changed, 65 insertions, 0 deletions
diff --git a/Documentation/source/zh_CN/operations.rst b/Documentation/source/zh_CN/operations.rst
new file mode 100644
index 0000000..ddacb09
--- /dev/null
+++ b/Documentation/source/zh_CN/operations.rst
@@ -0,0 +1,65 @@
+运维
+====
+
+环境配置
+--------
+
+关键环境变量在 ``src/env.js`` 中校验:
+
+.. list-table::
+ :header-rows: 1
+ :widths: 34 44
+
+ * - 变量
+ - 用途
+ * - ``DATABASE_URL``
+ - PostgreSQL 连接字符串。
+ * - ``RESEND_API_KEY``
+ - Resend API key。
+ * - ``RESEND_AUDIENCE_ID``
+ - Resend audience ID。
+ * - ``EMAIL_FROM``
+ - 发件邮箱。
+ * - ``BETTER_AUTH_SECRET``
+ - better-auth secret,生产环境必填。
+ * - ``GOOGLE_CLIENT_ID`` / ``GOOGLE_CLIENT_SECRET``
+ - Google OAuth 凭据。
+ * - ``GITHUB_CLIENT_ID`` / ``GITHUB_CLIENT_SECRET``
+ - GitHub OAuth 凭据。
+
+数据库流程
+----------
+
+Payload collection 变更:
+
+.. code-block:: bash
+
+ pnpm payload:migrate:create
+ pnpm payload:migrate
+ pnpm payload:generate
+
+应用 schema 变更:
+
+.. code-block:: bash
+
+ pnpm db:generate
+ pnpm db:migrate
+
+质量检查
+--------
+
+.. code-block:: bash
+
+ pnpm lint
+ pnpm check
+ pnpm test
+ pnpm build
+
+文档构建
+--------
+
+.. code-block:: bash
+
+ make -C Documentation html
+
+生成的 ``Documentation/build`` 不应提交。