diff --git a/website/pages/docs/builders/googlecompute.mdx b/website/pages/docs/builders/googlecompute.mdx index c37da6510..aecd7a22a 100644 --- a/website/pages/docs/builders/googlecompute.mdx +++ b/website/pages/docs/builders/googlecompute.mdx @@ -119,6 +119,9 @@ repackage an existing GCE image. The account_file is obtained in the previous section. If it parses as JSON it is assumed to be the file itself, otherwise, it is assumed to be the path to the file containing the JSON. + + + ```json { "builders": [ @@ -134,6 +137,26 @@ it is assumed to be the path to the file containing the JSON. } ``` + + + +```hcl +source "googlecompute" "basic-example" { + account_file = "account.json" + project_id = "my project" + source_image = "debian-7-wheezy-v20150127" + ssh_username = "packer" + zone = "us-central1-a" +} + +build { + sources = ["sources.googlecompute.basic-example"] +} +``` + + + + ### Windows Example Before you can provision using the winrm communicator, you need to allow