From 0da1f2d8c69e03c67660d357bdcceb70f0ac8608 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Sat, 26 Apr 2014 11:02:25 -0700 Subject: [PATCH] builder/googlecompute: template process instance name --- builder/googlecompute/config.go | 1 + website/source/docs/builders/googlecompute.markdown | 3 +++ 2 files changed, 4 insertions(+) diff --git a/builder/googlecompute/config.go b/builder/googlecompute/config.go index 795de6d69..593dfdf32 100644 --- a/builder/googlecompute/config.go +++ b/builder/googlecompute/config.go @@ -102,6 +102,7 @@ func NewConfig(raws ...interface{}) (*Config, []string, error) { "client_secrets_file": &c.ClientSecretsFile, "image_name": &c.ImageName, "image_description": &c.ImageDescription, + "instance_name": &c.InstanceName, "machine_type": &c.MachineType, "network": &c.Network, "passphrase": &c.Passphrase, diff --git a/website/source/docs/builders/googlecompute.markdown b/website/source/docs/builders/googlecompute.markdown index 9aba9b5cd..bab2ffce3 100644 --- a/website/source/docs/builders/googlecompute.markdown +++ b/website/source/docs/builders/googlecompute.markdown @@ -96,6 +96,9 @@ Optional: * `image_description` (string) - The description of the resulting image. +* `instance_name` (string) - A name to give the launched instance. Beware + that this must be unique. Defaults to "packer-{{uuid}}". + * `machine_type` (string) - The machine type. Defaults to `n1-standard-1`. * `network` (string) - The Google Compute network to use for the launched