-
Notifications
You must be signed in to change notification settings - Fork 11.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: 添加注册登录&同步聊天数据 #589
feat: 添加注册登录&同步聊天数据 #589
Conversation
|
GitGuardian id | Secret | Commit | Filename | |
---|---|---|---|---|
- | SMTP credentials | 0cccd04 | docker-compose/docker-compose.yml | View secret |
- | SMTP credentials | 7bd68a3 | docker-compose/docker-compose.yml | View secret |
🛠 Guidelines to remediate hardcoded secrets
- Understand the implications of revoking this secret by investigating where it is used in your code.
- Replace and store your secrets safely. Learn here the best practices.
- Revoke and rotate these secrets.
- If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.
To avoid such incidents in the future consider
- following these best practices for managing and storing secrets including API keys and other credentials
- install secret detection on pre-commit to catch secret before it leaves your machine and ease remediation.
🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.
Our GitHub checks need improvements? Share your feedbacks!
works great, thank you! |
感谢你的贡献,但是登录注册这种应该由自己的后端去开发,因为涉及数据库,很多人其实用不到。可以的话你可以在自己项目扩展分支,我可以链接过去,再次感谢,抱歉。 |
嗯嗯,没事,也是给有需要的人 |
@luckywangxi 看报错是 docker-compose/nginx 目录下的 conf 文件减少了, 确实我也不知道为啥,我之前合并主分支跑也是这样,少了这个文件你自己新建一下贴上 配置 https://github.com/Chanzhaoyu/chatgpt-web/blob/main/docker-compose/nginx/nginx.conf |
|
我想请问一下有没有打包好可以部署的docker镜像和docker-compose的yaml文件? |
@luckywangxi 这看不出 右键 f12 看下 |
参考如下 version: '3'
services:
app:
image: kerwin1202/chatgpt-web # 总是使用latest,更新时重新pull该tag镜像即可
ports:
- 13002:3002
depends_on:
- database
environment:
# 二选一
OPENAI_API_KEY: xxx
# 访问jwt加密参数,可选 不为空则允许登录 同时需要设置 MONGODB_URL
AUTH_SECRET_KEY: xxx
# 超时,单位毫秒,可选
TIMEOUT_MS: 60000
# mongodb 的连接字符串
MONGODB_URL: 'mongodb://chatgpt:xxxx@database:27017'
# 网站是否开启注册
REGISTER_ENABLED: true
# 开启注册之后 网站注册允许的邮箱后缀 如果空 则允许任意后缀
REGISTER_MAILS: '@qq.com,@sina.com,@163.com'
# 开启注册之后 密码加密的盐
PASSWORD_MD5_SALT: xxx
# 开启注册之后 超级管理邮箱
ROOT_USER: xxx
# 开启注册之后 网站域名 不含 / 注册的时候发送验证邮箱使用
SITE_DOMAIN: http://127.0.0.1:13002
# 开启注册之后 发送验证邮箱配置
SMTP_HOST: smtp.exmail.qq.com
SMTP_PORT: 465
SMTP_TSL: true
SMTP_USERNAME: xxx
SMTP_PASSWORD: xxx
links:
- database
database:
image: mongo
ports:
- '27017:27017'
expose:
- '27017'
volumes:
- mongodb:/data/db
environment:
MONGO_INITDB_ROOT_USERNAME: chatgpt
MONGO_INITDB_ROOT_PASSWORD: xxxx
MONGO_INITDB_DATABASE: chatgpt
volumes:
mongodb: {}
|
如果后台有开启/关闭注册的开关就比较方便了 |
docker compose文件里面可以选择开关 |
docker 自带数据库 |
@1589138103 我没说你的是因为密码啊,你的平台不对. 但是我win10 64 也可以跑 试试这个
|
@1589138103 如果是root_user是没有验证码的,这些配置是其他用户才需要,注册之后直接可以登录。 这个 site_domain 不影响发邮件,至于自己掉了需要日志看看 |
您好,请问一下MONGODB_URL怎么设置的? mongodb://chatgpt:xxxx@database:27017 mongodb://chatgpt:xxxx@database:27017/chatgpt |
@Kerwin1202 这里应该是3002 |
需要具体 docker 日志 |
正常是 3002 但是具体看你docker配置的端口 就是网页访问的 |
只要支持 smtp 都可以 |
这个就不好说了 https://www.smtper.net/ (我没试过) 可以这种试试看,记得测完改密码,类似的第三方邮件 foxmail 等也可以试试加不能加 |
fix: 多层代理导致ip获取错误,限流失效
feat: 实现用户登录权限相关接口的限流(登录、注册、发送邮件等等)
Update max_token for 16k
fix: Failed to resolve component NButton
fix: remove unused fetchChatAPI
不知道如何添加反爬虫,能不能具体点,群晖docker部署的。 |
冲突太多 重新改了下 关联 原 pr #417 左下角支持了退出
开启登录