1
1
mirror of https://github.com/adammck/terraform-inventory synced 2024-11-23 00:12:13 +01:00

Match host command by Address, not Name

This commit is contained in:
Adam Mckaig 2015-12-09 23:34:25 -05:00
parent 7276f41f50
commit aa1c5d4b19

2
cli.go

@ -30,7 +30,7 @@ func cmdList(stdout io.Writer, stderr io.Writer, s *state) int {
func cmdHost(stdout io.Writer, stderr io.Writer, s *state, hostname string) int {
for _, res := range s.resources() {
if hostname == res.Name {
if hostname == res.Address() {
return output(stdout, stderr, res.Attributes())
}
}