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

[Feature] 如何更改配置文件后,可以热更新,不要重启服务 #4236

Open
6 tasks done
djwIlo opened this issue Dec 17, 2024 · 4 comments
Open
6 tasks done
Labels
enhancement New feature or request

Comments

@djwIlo
Copy link

djwIlo commented Dec 17, 2024

Verify Steps

  • Tracker 我已经在 Issue Tracker 中找过我要提出的问题
  • Latest 我已经使用最新 Dev 版本查看过,并不包含该功能特性或者还不完善
  • Relevant 我知道 OpenClash 与 内核(Core)、控制面板(Dashboard)、在线订阅转换(Subconverter)等项目之间无直接关系,仅相互调用
  • Definite 这确实是 OpenClash 应包含的特性
  • Contributors 我有能力协助 OpenClash 开发或完善此功能特性
  • Meaningless 我提交的是无意义的催促更新或修复请求

Describe the Feature

比如更改了某个ip的代理ip规则,我想直接热更新使用这条规则,而不是每次都需要重启openclash服务,如何可以做到

Describe Alternatives

我想问openclash有没有这样的功能

@djwIlo djwIlo added the enhancement New feature or request label Dec 17, 2024
@vernesong
Copy link
Owner

暂时不会支持,嫌启动慢可以试试dev的版本

@giveup
Copy link

giveup commented Dec 18, 2024

内核使用自定义的RULE-SET。

rule-providers:
  MyProxy:
    format: 'yaml'
    behavior: classical
    interval: 86400
    path: "./rule_provider/MyProxy.yaml"
    type: file 
rules:
  - RULE-SET,MyProxy,PROXY

当yaml文件被更改时,内核会热加载而无需重启。(记得先去面板把已经建立的连接关闭,这样新建立的连接就会按规则配置去建立)

@fejeIaqbhbv
Copy link

其实可以自己写api
但难度高

@dqbpqdpb
Copy link

自定义RULE-SET就好了啊···规则都是立刻生效的,已经连上的要先断开旧链接。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants