mirror of
https://github.com/coredns/coredns.git
synced 2025-10-28 16:54:15 -04:00
mw/kubernetes: warn about deprecating cidr (#858)
Add log statement pointing to replacement. remove cidr from README and use replacement syntax. Fixes #851
This commit is contained in:
@@ -3,6 +3,7 @@ package kubernetes
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"log"
|
||||
"net"
|
||||
"strconv"
|
||||
"strings"
|
||||
@@ -95,6 +96,10 @@ func kubernetesParse(c *caddy.Controller) (*Kubernetes, error) {
|
||||
for c.NextBlock() {
|
||||
switch c.Val() {
|
||||
case "cidrs":
|
||||
|
||||
// DEPRECATION WARNING
|
||||
log.Printf("[WARNING] \"cidrs\" will be removed for CoreDNS soon. See https://coredns.io/2017/07/23/corefile-explained#reverse-zones for the replacement")
|
||||
|
||||
args := c.RemainingArgs()
|
||||
if len(args) > 0 {
|
||||
for _, cidrStr := range args {
|
||||
|
||||
Reference in New Issue
Block a user