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

添加CloudFlare支持+一个小feature #20

Merged
merged 2 commits into from
Jul 21, 2018
Merged

添加CloudFlare支持+一个小feature #20

merged 2 commits into from
Jul 21, 2018

Conversation

tongyifan
Copy link
Contributor

添加CloudFlare支持,照葫芦画瓢写了一下(因为我个人是用CloudFlare的,之前自己写了一个很不优雅的DDNS程序(嗯现在还在我的仓库里,然后觉得大佬好厉害,所以就直接搬到这里来了23333

在config的index4/6中添加‘none’选项,这个是因为现在如果想要禁用ipv4或ipv6的解析更新,就必须把config中的ipv4/ipv6那项中的域名全部删除,否则就会报网络不可达错误。对于用户(其实是我23333)来说,一个禁用选项比删除掉所有域名更方便

@NewFuture
Copy link
Owner

NewFuture commented Jul 20, 2018 via email

@NewFuture NewFuture added the NewDNSProvider 增加新的DNS服务商支持 label Jul 21, 2018
@NewFuture
Copy link
Owner

@tongyifan
这个"禁用"配置参数,感觉有两个问题

  1. 本来设置了域名,却又不解析是否有矛盾?
  2. 占用字符串配置,个人感觉会影响后续扩展

@tongyifan
Copy link
Contributor Author

呃,其实有这个想法是因为,我在学校是有ipv6网络的,我会把ipv6地址ddns,但是当我回家时就没有了ipv6,所以就需要把那个禁用掉,而阅读了readme也没有写出怎么禁用,看了代码才知道把域名删除掉就可以禁用了。

设置了域名代表了这个程序将要修改哪些域名的dns解析,而‘禁用’配置参数则代表了是否要进行修改,这个本身我觉得不是很矛盾

后续扩展方面我的确有点欠考虑了,只是想到在index这里判断是最方便的,就写到了那里,事实上它应该单拿出来,但是那样又改的太多了((

所以说仔细一想的确是有些问题的,如果不接受这个‘禁用’的配置参数,也建议在readme中写明如何禁用解析,方便用户使用

具体如何您来定夺即可,感谢!

@NewFuture NewFuture merged commit e0ca09a into NewFuture:master Jul 21, 2018
NewFuture added a commit that referenced this pull request Jul 21, 2018
add CloudFlare API and "disable" configuration #20
@NewFuture
Copy link
Owner

这里改成了false来关闭更新

@NewFuture
Copy link
Owner

@tongyifan 有空帮忙测试一下这个release的CloudFlare
https://github.com/NewFuture/DDNS/releases/tag/v2.4.2

@tongyifan
Copy link
Contributor Author

@NewFuture 测试了,windows和linux都没有问题,赞!

@NewFuture
Copy link
Owner

谢谢,更新了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NewDNSProvider 增加新的DNS服务商支持
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants