CloudGuardIaaS icon indicating copy to clipboard operation
CloudGuardIaaS copied to clipboard

Correct image_name values for GCP

Open jeheyer opened this issue 3 years ago • 1 comments

I've been deploying CheckPoint HA clusters in GCP for about 2 years and just learned about the Terraform option. Everything is quite clear except for the 'image_name' variable. The documentation mentions this link:

https://github.com/CheckPointSW/CloudGuardIaaS/blob/master/gcp/deployment-packages/ha-byol/images.py

But I've tried both the key and values from the IMAGES dictionary and get this error:

│ Error: Error in function call
│
│   on locals.tf line 10, in locals:
│   10:   validate_image_name = length(regexall(local.regex_validate_image_name, var.image_name)) > 0 ? 0 : index(split("-", var.image_name), "INVALID IMAGE NAME")
│     ├────────────────
│     │ var.image_name is "check-point-r8040-byol-294-759-v20201202"
│
│ Call to function "index" failed: item not found.

jeheyer avatar Jul 12 '22 21:07 jeheyer

Think I found a workaround: Do manual deployment, open Deployment Manager, click Overview, then click Expanded Config and search for 'Image'. There should be a line similar to this:

 sourceImage: projects/checkpoint-public/global/images/check-point-r8040-gw-byol-cluster-294-904-v20210715

Indeed, setting this in my .tfvars file resulted in a successful Terraform deployment :-)

image_name = "check-point-r8040-gw-byol-cluster-294-904-v20210715"

jeheyer avatar Jul 12 '22 21:07 jeheyer

Hi @jeheyer, Thank you for letting us know. RnD will investigate it and update accordantly.

Thanks, Natanel

chkp-natanelm avatar Oct 23 '22 17:10 chkp-natanelm

Hi @jeheyer,

We fixed the image_name validation. Please pull the new code, and try again.

Thanks, Natanel

chkp-natanelm avatar Jan 04 '23 17:01 chkp-natanelm