Skip to content

Commit

Permalink
Fixed bug in libnss-resolver DNS resolution (#116)
Browse files Browse the repository at this point in the history
* messing with ldflags

* tweaking CGO

* tweaking some build flags

* Transitioned to different go base to try to head off problems with dynamically linked go binaries

* Added rpm to build, well, rpms

* allow easier overrides of GOOS/GOARCH for compile

* Fixed libnss-resolver config

* reverted ealrier go build tweaking
  • Loading branch information
febbraro authored Nov 10, 2017
1 parent b52afd6 commit 06d43b5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
4 changes: 0 additions & 4 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@ project_name: outrigger-cli
builds:
- binary: rig
main: ./cmd/main.go
# ldflags: -d -s -w -X main.build={{.Version}}
# flags: -tags netgo -installsuffix netgo
# env:
# - CGO_ENABLED=0
goos:
- windows
- darwin
Expand Down
2 changes: 1 addition & 1 deletion commands/dns.go
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ func (cmd *DNS) configureLinuxResolver() error {
// Is libnss-resolver in use
if _, err := os.Stat("/etc/resolver"); err == nil {
// Install for libnss-resolver connection to dnsdock
exec.Command("bash", "-c", fmt.Sprintf("echo 'nameserver %s' | sudo tee /etc/resolver/vm", bridgeIP)).Run()
exec.Command("bash", "-c", fmt.Sprintf("echo 'nameserver %s:53' | sudo tee /etc/resolver/vm", bridgeIP)).Run()
}

return nil
Expand Down
6 changes: 3 additions & 3 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ services:
# Build rig, dropping off a working binary in build/darwin/rig.
compile:
extends: base
command: go build -o build/darwin/rig cmd/main.go
command: go build -o build/${GOOS:-darwin}/rig cmd/main.go
environment:
- GOOS=darwin
- GOARCH=amd64
GOOS: ${GOOS:-darwin}
GOARCH: ${GOARCH:-amd64}

# Install project dependencies.
install:
Expand Down

0 comments on commit 06d43b5

Please sign in to comment.