From b6632d8940dce47c350a540d6cc1ddaaee683194 Mon Sep 17 00:00:00 2001 From: Robert Willard Date: Tue, 16 Jun 2015 16:31:39 -0700 Subject: [PATCH] added defaults --- aws.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/aws.go b/aws.go index 636807f..9b1f641 100644 --- a/aws.go +++ b/aws.go @@ -21,6 +21,10 @@ func getEC2Instances(config map[string]string) (instances Instances) { config["region"] = "us-east-1" } + if _, ok := config["output_format"]; !ok { + config["output_format"] = "Cloud: {cloud} \tMatched by: {tag_name} = {tag_value} \tAddr: {addr}" + } + auth := aws.Auth{AccessKey: config["access_key"], SecretKey: config["secret_key"]} e := ec2.New(auth, aws.Regions[config["region"]])