Merge pull request #7359 from Adezandee/gce-export-network

googlecompute-export: set network project id to builder
This commit is contained in:
Megan Marsh 2019-03-01 10:28:48 -08:00 committed by GitHub
commit 34a0edccbb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -125,6 +125,7 @@ func (p *PostProcessor) PostProcess(ui packer.Ui, artifact packer.Artifact) (pac
MachineType: p.config.MachineType,
Metadata: exporterMetadata,
Network: p.config.Network,
NetworkProjectId: builderProjectId,
RawStateTimeout: "5m",
SourceImageFamily: "debian-9-worker",
SourceImageProjectId: "compute-image-tools",

View File

@ -54,7 +54,7 @@ permissions to the GCS `paths`.
- `network` (string) - The Google Compute network id or URL to use for the
export instance. Defaults to `"default"`. If the value is not a URL, it
will be interpolated to
`projects/((network_project_id))/global/networks/((network))`. This value
`projects/((builder_project_id))/global/networks/((network))`. This value
is not required if a `subnet` is specified.
- `subnetwork` (string) - The Google Compute subnetwork id or URL to use for
@ -62,7 +62,7 @@ permissions to the GCS `paths`.
custom subnetting. Note, the region of the subnetwork must match the
`zone` in which the VM is launched. If the value is not a URL,
it will be interpolated to
`projects/((network_project_id))/regions/((region))/subnetworks/((subnetwork))`
`projects/((builder_project_id))/regions/((region))/subnetworks/((subnetwork))`
- `zone` (string) - The zone in which to launch the export instance. Defaults
to `googlecompute` builder zone. Example: `"us-central1-a"`