mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-05-06 21:52:54 +08:00
89 lines
2.3 KiB
Go
89 lines
2.3 KiB
Go
// Copyright 2019 Yunion
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
|
|
package main
|
|
|
|
import (
|
|
"github.com/coredns/coredns/core/dnsserver"
|
|
"github.com/coredns/coredns/coremain"
|
|
_ "github.com/coredns/coredns/plugin/acl"
|
|
_ "github.com/coredns/coredns/plugin/bind"
|
|
_ "github.com/coredns/coredns/plugin/bufsize"
|
|
_ "github.com/coredns/coredns/plugin/cache"
|
|
_ "github.com/coredns/coredns/plugin/cancel"
|
|
_ "github.com/coredns/coredns/plugin/chaos"
|
|
_ "github.com/coredns/coredns/plugin/debug"
|
|
_ "github.com/coredns/coredns/plugin/errors"
|
|
_ "github.com/coredns/coredns/plugin/file"
|
|
_ "github.com/coredns/coredns/plugin/forward"
|
|
_ "github.com/coredns/coredns/plugin/health"
|
|
_ "github.com/coredns/coredns/plugin/hosts"
|
|
_ "github.com/coredns/coredns/plugin/loadbalance"
|
|
_ "github.com/coredns/coredns/plugin/local"
|
|
_ "github.com/coredns/coredns/plugin/log"
|
|
_ "github.com/coredns/coredns/plugin/loop"
|
|
_ "github.com/coredns/coredns/plugin/metrics" // prometheus
|
|
_ "github.com/coredns/coredns/plugin/nsid"
|
|
_ "github.com/coredns/coredns/plugin/ready"
|
|
_ "github.com/coredns/coredns/plugin/reload"
|
|
_ "github.com/coredns/coredns/plugin/rewrite"
|
|
_ "github.com/coredns/coredns/plugin/timeouts"
|
|
_ "github.com/coredns/coredns/plugin/trace"
|
|
_ "github.com/coredns/coredns/plugin/whoami"
|
|
_ "github.com/mholt/caddy/startupshutdown"
|
|
|
|
_ "yunion.io/x/onecloud/pkg/dns"
|
|
"yunion.io/x/onecloud/pkg/util/atexit"
|
|
)
|
|
|
|
var directives = []string{
|
|
"cancel",
|
|
"timeouts",
|
|
"reload",
|
|
"nsid",
|
|
"bufsize",
|
|
"bind",
|
|
"debug",
|
|
"trace",
|
|
"ready",
|
|
"health",
|
|
"prometheus",
|
|
"errors",
|
|
"log",
|
|
"local",
|
|
"chaos",
|
|
"loadbalance",
|
|
"cache",
|
|
"rewrite",
|
|
"acl",
|
|
"yunion",
|
|
"hosts",
|
|
"file",
|
|
"loop",
|
|
"forward",
|
|
"whoami",
|
|
"startup",
|
|
"shutdown",
|
|
}
|
|
|
|
func init() {
|
|
dnsserver.Directives = directives
|
|
}
|
|
|
|
func main() {
|
|
defer atexit.Handle()
|
|
|
|
coremain.Run()
|
|
}
|