hashicorp / hashicorp/packer-plugin-googlecompute
v1.1.7 or later fails when building images in parallel
- Dominant language
- Go
- Stars
- 33
- Forks
- 72
- Avg merge
- 6h 47m
- Merged PRs (30d)
- 3
Description
#### Overview of the Issue
Ever since v1.1.7, some of our windows builds have been failing with the error
"Error creating windows password: time out while waiting for the password to be created"
On a hunch, instead of having packer use oslogin to create the packer user we created the packer user in a startup script. We then started getting the error
"errored after 12 seconds 726 milliseconds: Error importing SSH public key for OSLogin: googleapi: Error 409: Multiple concurrent mutations were attempted. Please retry the request."
Reverting back to v1.1.6 of the plugin avoids all these errors.
#### Reproduction Steps
Run this template provided
### Plugin and Packer version
1.12.0 or later
### Simplified Packer Buildfile
```
packer {
required_plugins {
googlecompute = {
source = "github.com/hashicorp/googlecompute"
version = "~> 1.0"
}
}
}
source "googlecompute" "windows" {
project_id = var.project_id
ssh_username = "packer"
zone = "us-central1-a"
subnetwork = var.subnetwork
network_project_id = var.project_id
use_internal_ip = true
enable_secure_boot = true
omit_external_ip = true
use_iap = false
image_labels = {}
disk_size = 50
machine_type = "n2d-standard-2"
tags = ["packer", "allow-internet-egress"]
metadata = {
windows-startup-script-cmd = <
Contributor guide
Assessment
This issue has not been assessed yet.