forked from DevOps/deploy.stack
feat(couchdb): 添加 CouchDB 配置文件和生成脚本
- 添加 CouchDB 的 Docker 配置文件和环境变量配置 - 添加用于生成 Obsidian LiveSync 配置的 Python 脚本
This commit is contained in:
38
dbSer/couchdb/etc/couchdb/local.d/local.ini
Normal file
38
dbSer/couchdb/etc/couchdb/local.d/local.ini
Normal file
@@ -0,0 +1,38 @@
|
||||
# CouchDB 配置文件
|
||||
# 此文件包含 Obsidian LiveSync 所需的 CouchDB 配置
|
||||
|
||||
[couchdb]
|
||||
# 单节点模式设置
|
||||
single_node=true
|
||||
# 最大文档大小(字节)
|
||||
max_document_size = 50000000
|
||||
|
||||
[chttpd]
|
||||
# 要求有效用户认证
|
||||
require_valid_user = true
|
||||
# 最大 HTTP 请求大小(字节)
|
||||
max_http_request_size = 4294967296
|
||||
|
||||
[chttpd_auth]
|
||||
# 要求有效用户认证
|
||||
require_valid_user = true
|
||||
# 认证重定向页面
|
||||
authentication_redirect = /_utils/session.html
|
||||
|
||||
[httpd]
|
||||
# 基本认证领域
|
||||
WWW-Authenticate = Basic realm="couchdb"
|
||||
# 启用 CORS
|
||||
enable_cors = true
|
||||
|
||||
[cors]
|
||||
# 允许的源(用逗号分隔)
|
||||
origins = app://obsidian.md,capacitor://localhost,http://localhost
|
||||
# 允许发送认证信息
|
||||
credentials = true
|
||||
# 允许的请求头
|
||||
headers = accept, authorization, content-type, origin, referer
|
||||
# 允许的 HTTP 方法
|
||||
methods = GET, PUT, POST, HEAD, DELETE
|
||||
# CORS 预检请求缓存时间(秒)
|
||||
max_age = 3600
|
||||
Reference in New Issue
Block a user