From ec224771857d187f91da97d1279175eedc919fde Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Tue, 4 Jun 2013 13:12:04 -0700 Subject: [PATCH] builder/amazonebs: Use unix timestamps --- builder/amazonebs/step_create_ami.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/builder/amazonebs/step_create_ami.go b/builder/amazonebs/step_create_ami.go index 81a9a2cbd..f088e8fc6 100644 --- a/builder/amazonebs/step_create_ami.go +++ b/builder/amazonebs/step_create_ami.go @@ -6,6 +6,7 @@ import ( "github.com/mitchellh/goamz/ec2" "github.com/mitchellh/multistep" "github.com/mitchellh/packer/packer" + "strconv" "text/template" "time" ) @@ -25,7 +26,7 @@ func (s *stepCreateAMI) Run(state map[string]interface{}) multistep.StepAction { // Parse the name of the AMI amiNameBuf := new(bytes.Buffer) tData := amiNameData{ - time.Now().UTC().String(), + strconv.FormatInt(time.Now().UTC().Unix(), 10), } t := template.Must(template.New("ami").Parse(config.AMIName))