Initial commit: X-Server Mobile enterprise tool system
- Frontend: React 18 + TypeScript + Vite + Ant Design Mobile - Backend: PHP 8.5 + Webman 2.x + MySQL + Redis - i18n support: Chinese, English, Russian, Spanish, French - Approval workflow engine - Docker development environment - Feishu integration Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
# frpc 开发环境配置
|
||||
# 使用方法: frpc -c frpc-dev.ini
|
||||
|
||||
[common]
|
||||
# ======== 请修改以下配置 ========
|
||||
server_addr = your-frp-server.com
|
||||
server_port = 7000
|
||||
token = your-frp-token
|
||||
# ================================
|
||||
|
||||
# 开发环境 API 代理
|
||||
[x-server-api-dev]
|
||||
type = http
|
||||
local_ip = 127.0.0.1
|
||||
local_port = 8080
|
||||
custom_domains = api-dev.x-server.your-domain.com
|
||||
|
||||
# 启用加密和压缩
|
||||
use_encryption = true
|
||||
use_compression = true
|
||||
|
||||
# 健康检查
|
||||
health_check_type = http
|
||||
health_check_url = /health
|
||||
health_check_interval_s = 30
|
||||
health_check_max_failed = 3
|
||||
|
||||
# ========================================
|
||||
# 配置说明
|
||||
# ========================================
|
||||
#
|
||||
# 1. 修改 server_addr 为你的 frp 服务器地址
|
||||
# 2. 修改 token 为你的 frp 服务器 token
|
||||
# 3. 修改 custom_domains 为你的开发域名
|
||||
# 4. 确保 local_port (8080) 与 OpenResty 配置一致
|
||||
# 5. 将 api-dev.x-server.your-domain.com 的 DNS 指向 frp 服务器
|
||||
#
|
||||
# 启动命令:
|
||||
# frpc -c frpc-dev.ini
|
||||
#
|
||||
# 后台运行:
|
||||
# nohup frpc -c frpc-dev.ini > /dev/null 2>&1 &
|
||||
#
|
||||
# 使用 systemd 管理 (推荐):
|
||||
# sudo cp frpc-dev.service /etc/systemd/system/
|
||||
# sudo systemctl enable frpc-dev
|
||||
# sudo systemctl start frpc-dev
|
||||
@@ -0,0 +1,49 @@
|
||||
[Unit]
|
||||
Description=FRP Client for X-Server Development
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=YOUR_USERNAME
|
||||
Group=YOUR_GROUP
|
||||
WorkingDirectory=/path/to/x-server-mobile/frpc
|
||||
ExecStart=/usr/local/bin/frpc -c /path/to/x-server-mobile/frpc/frpc-dev.ini
|
||||
Restart=on-failure
|
||||
RestartSec=5s
|
||||
|
||||
# 日志
|
||||
StandardOutput=journal
|
||||
StandardError=journal
|
||||
SyslogIdentifier=frpc-dev
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
# ========================================
|
||||
# 安装说明
|
||||
# ========================================
|
||||
#
|
||||
# 1. 修改以下配置:
|
||||
# - User: 你的用户名
|
||||
# - Group: 你的组名
|
||||
# - WorkingDirectory: 项目 frpc 目录的绝对路径
|
||||
# - ExecStart: frpc-dev.ini 的绝对路径
|
||||
#
|
||||
# 2. 安装服务:
|
||||
# sudo cp frpc-dev.service /etc/systemd/system/
|
||||
# sudo systemctl daemon-reload
|
||||
#
|
||||
# 3. 启用并启动服务:
|
||||
# sudo systemctl enable frpc-dev
|
||||
# sudo systemctl start frpc-dev
|
||||
#
|
||||
# 4. 查看状态:
|
||||
# sudo systemctl status frpc-dev
|
||||
#
|
||||
# 5. 查看日志:
|
||||
# sudo journalctl -u frpc-dev -f
|
||||
#
|
||||
# 6. 停止服务:
|
||||
# sudo systemctl stop frpc-dev
|
||||
#
|
||||
# 注意: 生产环境不应该使用 frpc,只在开发调试时使用
|
||||
@@ -0,0 +1,35 @@
|
||||
# frpc 配置文件 - 用于将本地服务暴露到公网
|
||||
# 使用方法: frpc -c frpc.ini
|
||||
|
||||
[common]
|
||||
# frp 服务器地址(需要替换为你的 frp 服务器地址)
|
||||
server_addr = your-frp-server.com
|
||||
server_port = 7000
|
||||
|
||||
# 认证令牌(需要替换为你的 frp 服务器 token)
|
||||
token = your-frp-token
|
||||
|
||||
# API 服务代理
|
||||
[x-server-api]
|
||||
type = http
|
||||
local_ip = 127.0.0.1
|
||||
local_port = 8787
|
||||
custom_domains = api.x-server.your-domain.com
|
||||
|
||||
# 如果使用 HTTPS,可以启用以下配置
|
||||
# use_encryption = true
|
||||
# use_compression = true
|
||||
|
||||
# 可选:配置 HTTP 基本认证
|
||||
# http_user = your-username
|
||||
# http_pwd = your-password
|
||||
|
||||
# V2ray/WebSocket 等其他协议可以添加更多配置
|
||||
|
||||
# ========================================
|
||||
# 配置说明
|
||||
# ========================================
|
||||
# 1. 需要先将 api.x-server.your-domain.com 的 DNS 解析指向 frp 服务器
|
||||
# 2. frp 服务器需要配置域名白名单或使用泛域名
|
||||
# 3. 本地需要安装 OpenResty/Nginx 并配置反向代理
|
||||
# 4. 飞书回调 URL 格式: https://api.x-server.your-domain.com/api/v1/auth/feishu-login
|
||||
Reference in New Issue
Block a user