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

Feat: DNS hosts support multiple addresses #884

Merged
merged 1 commit into from Apr 10, 2021
Merged

Feat: DNS hosts support multiple addresses #884

merged 1 commit into from Apr 10, 2021

Conversation

Loyalsoldier
Copy link
Contributor

@Loyalsoldier Loyalsoldier commented Apr 10, 2021

Now you can set hosts in dns section like this:

{
  "dns": {
    "hosts": {
      "ad.example.com": "127.0.0.1",
      "ads.example.com": ["127.0.0.1", "::1"],
      "geosite:category-ads": "127.0.0.1",
      "geosite:category-ads-all": ["127.0.0.1", "::1"]
    }
  }
}

If set IPs together with domains, only the first proxied domain one.example.com will be returned and all IPs will be ignored:

{
  "dns": {
    "hosts": {
      "ads.example.com": ["127.0.0.1", "::1", "one.example.com", "two.example.com"]
    }
  }
}

Copy link
Contributor

@xiaokangwang xiaokangwang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issue discovered, we can merge this after we have release a stable version of v4.37.

@kslr kslr merged commit bada0e4 into v2fly:master Apr 10, 2021
@Loyalsoldier Loyalsoldier deleted the dns-hosts-multi-address branch April 10, 2021 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants