Skip to content
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

对配置文件面向开发者做的可读性,便利性处理 #278

Open
wants to merge 12 commits into
base: master
Choose a base branch
from

Conversation

Linlccc
Copy link
Contributor

@Linlccc Linlccc commented May 5, 2022

1.让配置文件更具可读性,根据功能等信息分类
2.直接配置需要加入的自定义配置文件夹,自动完成配置合并
3.支持绝对路径文件夹,为某些秘钥配置提供便利 (将秘钥配置文件存放在项目之外,push 源代码时就不会上传了,生成时会自动生成到项目输出目录)

Linlccc and others added 7 commits March 2, 2022 15:01
1.优化 program 可读性
2.移除无用的 appsettings 静态方法的注入

修改
1.让配置文件更具可读性,根据功能等信息分类;不同环境配置更加清晰
2.直接配置需要加入的自定义配置文件夹,自动完成配置添加
3.不同环境时只需配置一次appsettings.[EnvironmentName].json文件即可,不用频繁的在不同环境中修改大量的配置信息
@anjoy8
Copy link
Owner

anjoy8 commented May 7, 2022

你好,感谢提交pr,还是之前那个问题:
配置文件分解很多,好处当然是很清晰,直观明了。
但是有个很迫切的问题,就是支持一个总和的json配置文件么?

比如在docker容器化部署的时候,需要docker -v 挂载配置文件,
因为一个镜像,可能对应不通的环境,比如dev、uat、prod等等,
那这样的化,就需要每个配置文件都挂载,至少十个了。

@Linlccc
Copy link
Contributor Author

Linlccc commented May 7, 2022

做处理了,分解的配置只是针对开发者,在发布时一个环境只会有一个json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants