From 8455351e962997b84aac02c53e9f6db4f739cad9 Mon Sep 17 00:00:00 2001 From: Ben Burwell Date: Tue, 13 Aug 2019 14:53:03 -0400 Subject: jq: adopt --- templates/.jq/aws.jq | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 templates/.jq/aws.jq diff --git a/templates/.jq/aws.jq b/templates/.jq/aws.jq new file mode 100644 index 0000000..2a3cd54 --- /dev/null +++ b/templates/.jq/aws.jq @@ -0,0 +1,12 @@ +def gettag(name): .Tags[] | select(.Key == name).Value; + +def getInstanceMetadata: .Reservations[].Instances[] | + [ + .PrivateIpAddress, + .PublicIpAddress // "--", + gettag("Name") // "--", + .InstanceId, + .InstanceType + ] | + join("\t"); + -- cgit v1.2.3