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

Fix messenger address in container #38

Merged
merged 2 commits into from
Dec 10, 2015

Conversation

gengmao
Copy link
Contributor

@gengmao gengmao commented Dec 8, 2015

A small fix for the issue I hit - #36.

Still no idea why nslookup inside container returns two adresses in one line, but this fix works for me.

@@ -1,7 +1,7 @@
#!/bin/sh

lookup_host() {
nslookup "$1" | awk -v HOST="$1" '{ if ($2 == HOST) { getline; gsub(/^.*: /, ""); print; } }'
nslookup "$1" | awk -v HOST="$1" '{ if ($2 == HOST) { getline; gsub(/^.*: /, ""); split($0, a, " ", seps); print a[1]; } }'
Copy link
Collaborator

Choose a reason for hiding this comment

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

print $1 should do the same thing. Would you mind testing if that works for you?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes it works and simpler!

@keis
Copy link
Collaborator

keis commented Dec 10, 2015

LGTM

keis added a commit that referenced this pull request Dec 10, 2015
@keis keis merged commit 522d4d6 into eremetic-framework:master Dec 10, 2015
@keis keis mentioned this pull request Dec 10, 2015
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.

2 participants