hashicorp / packer-plugin-googlecompute

Packer plugin for Google Compute Builder
https://www.packer.io/docs/builders/googlecompute
Mozilla Public License 2.0
24 stars 54 forks source link

Rocky linux image is not found #67

Closed mo36924 closed 2 years ago

mo36924 commented 2 years ago

Creating a custom image from rocky linux results in the following error: Error getting source image for instance creation: Could not find image, rocky-linux-8-v20211105.

Setting source_image to centos-8-v20211105 causes no error.

Plugin and Packer version

packer --version 1.7.8 hashicorp/packer-plugin-googlecompute 1.0.7

Packer Buildfile

packer {
  required_plugins {
    googlecompute = {
      version = ">= 1.0.7"
      source  = "github.com/hashicorp/googlecompute"
    }
  }
}

variable "project_id"{
  type = string
}

source "googlecompute" "test" {
  project_id   = var.project_id
  zone = "us-central1-a"
  source_image = "rocky-linux-8-v20211105"
  ssh_username = "test"
  image_name   = "test-rocky-1"
  image_family = "test-rocky"
}

build {
  sources = [
    "source.googlecompute.test"
  ]
  provisioner "shell" {
    inline = ["echo foo"]
  }
}