Merge pull request #1046 from erikwilson/fix-dns

Go DNS lookup order hack
This commit is contained in:
Erik Wilson 2019-11-13 02:02:46 -07:00 committed by GitHub
commit 4afc14df0c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 1 deletions

View File

@ -2,6 +2,7 @@ package cmds
import (
"fmt"
"os"
"github.com/rancher/k3s/pkg/version"
"github.com/sirupsen/logrus"
@ -12,6 +13,13 @@ var (
debug bool
)
func init() {
// hack - force "file,dns" lookup order if go dns is used
if os.Getenv("RES_OPTIONS") == "" {
os.Setenv("RES_OPTIONS", " ")
}
}
func NewApp() *cli.App {
app := cli.NewApp()
app.Name = appName

View File

@ -33,7 +33,7 @@ fi
STATIC_SQLITE="
-extldflags '-static -lm -ldl -lz -lpthread $DQLITE_STATIC_SQLITE'
"
TAGS="ctrd apparmor seccomp no_btrfs netgo osusergo providerless $DQLITE_TAGS"
TAGS="ctrd apparmor seccomp no_btrfs netcgo osusergo providerless $DQLITE_TAGS"
if [ "$STATIC_BUILD" != "true" ]; then
STATIC="