Use family, not name, in image data source.

This commit is contained in:
Paddy Carver 2018-08-14 11:18:39 -07:00
parent 5c9ce55172
commit dd56795f2a
16 changed files with 111 additions and 111 deletions

View File

@ -194,7 +194,7 @@ func testAccCheckDataSourceGoogleComputeInstanceGroup(dataSourceName string) res
func testAccCheckDataSourceGoogleComputeInstanceGroupConfig() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -237,7 +237,7 @@ data "google_compute_instance_group" "test" {
func testAccCheckDataSourceGoogleComputeInstanceGroupConfigWithNamedPort() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -290,7 +290,7 @@ data "google_compute_instance_group" "test" {
func testAccCheckDataSourceGoogleComputeInstanceGroup_fromIGM() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -222,7 +222,7 @@ func testAccCheckComputeAutoscalerUpdated(n string, max int64) resource.TestChec
func testAccComputeAutoscaler_scaffolding(it_name, tp_name, igm_name string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -679,7 +679,7 @@ func testAccComputeBackendService_withBackend(
serviceName, igName, itName, checkName string, timeout int64) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -737,7 +737,7 @@ func testAccComputeBackendService_withBackendAndIAP(
serviceName, igName, itName, checkName string, timeout int64) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -895,7 +895,7 @@ func testAccComputeBackendService_withMaxConnections(
serviceName, igName, itName, checkName string, maxConnections int64) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -953,7 +953,7 @@ func testAccComputeBackendService_withMaxConnectionsPerInstance(
serviceName, igName, itName, checkName string, maxConnectionsPerInstance int64) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -601,7 +601,7 @@ func testAccCheckComputeDiskInstances(n string, disk *compute.Disk) resource.Tes
func testAccComputeDisk_basic(diskName string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -620,7 +620,7 @@ resource "google_compute_disk" "foobar" {
func testAccComputeDisk_timeout() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -639,7 +639,7 @@ resource "google_compute_disk" "foobar" {
func testAccComputeDisk_updated(diskName string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -659,7 +659,7 @@ resource "google_compute_disk" "foobar" {
func testAccComputeDisk_fromSnapshot(projectName, firstDiskName, snapshotName, diskName, ref_selector string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -691,7 +691,7 @@ resource "google_compute_disk" "seconddisk" {
func testAccComputeDisk_encryption(diskName string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -708,7 +708,7 @@ resource "google_compute_disk" "foobar" {
func testAccComputeDisk_encryptionMigrate(diskName string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -727,7 +727,7 @@ resource "google_compute_disk" "foobar" {
func testAccComputeDisk_deleteDetach(instanceName, diskName string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -763,7 +763,7 @@ resource "google_compute_instance" "bar" {
func testAccComputeDisk_deleteDetachIGM(diskName, mgrName string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -322,7 +322,7 @@ resource "google_compute_image" "foobar" {
func testAccComputeImage_basedondisk() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -58,7 +58,7 @@ func testAccCheckComputeInstanceFromTemplateDestroy(s *terraform.State) error {
func testAccComputeInstanceFromTemplate_basic(instance, template string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -693,7 +693,7 @@ func testAccCheckInstanceGroupManagerRollingUpdatePolicy(manager *computeBeta.In
func testAccInstanceGroupManager_basic(template, target, igm1, igm2 string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -752,7 +752,7 @@ func testAccInstanceGroupManager_basic(template, target, igm1, igm2 string) stri
func testAccInstanceGroupManager_targetSizeZero(template, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -794,7 +794,7 @@ func testAccInstanceGroupManager_targetSizeZero(template, igm string) string {
func testAccInstanceGroupManager_update(template, target, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -848,7 +848,7 @@ func testAccInstanceGroupManager_update(template, target, igm string) string {
func testAccInstanceGroupManager_update2(template1, target1, target2, template2, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -939,7 +939,7 @@ func testAccInstanceGroupManager_update2(template1, target1, target2, template2,
func testAccInstanceGroupManager_updateLifecycle(tag, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -984,7 +984,7 @@ func testAccInstanceGroupManager_updateLifecycle(tag, igm string) string {
func testAccInstanceGroupManager_updateStrategy(igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1030,7 +1030,7 @@ func testAccInstanceGroupManager_updateStrategy(igm string) string {
func testAccInstanceGroupManager_rollingUpdatePolicy(igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1083,7 +1083,7 @@ resource "google_compute_instance_group_manager" "igm-rolling-update-policy" {
func testAccInstanceGroupManager_rollingUpdatePolicy2(igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1132,7 +1132,7 @@ resource "google_compute_instance_group_manager" "igm-rolling-update-policy" {
func testAccInstanceGroupManager_separateRegions(igm1, igm2 string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1183,7 +1183,7 @@ func testAccInstanceGroupManager_separateRegions(igm1, igm2 string) string {
func testAccInstanceGroupManager_autoHealingPolicies(template, target, igm, hck string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1240,7 +1240,7 @@ resource "google_compute_http_health_check" "zero" {
func testAccInstanceGroupManager_versions(primaryTemplate string, canaryTemplate string, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1316,7 +1316,7 @@ resource "google_compute_instance_group_manager" "igm-basic" {
func testAccInstanceGroupManager_selfLinkStability(template, target, igm, hck, autoscaler string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -308,7 +308,7 @@ func testAccComputeInstanceGroup_hasCorrectNetwork(nInstanceGroup string, nNetwo
func testAccComputeInstanceGroup_basic(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -362,7 +362,7 @@ func testAccComputeInstanceGroup_basic(instance string) string {
func testAccComputeInstanceGroup_update(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -404,7 +404,7 @@ func testAccComputeInstanceGroup_update(instance string) string {
func testAccComputeInstanceGroup_update2(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -446,7 +446,7 @@ func testAccComputeInstanceGroup_update2(instance string) string {
func testAccComputeInstanceGroup_recreateInstances(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -489,7 +489,7 @@ func testAccComputeInstanceGroup_recreateInstances(instance string) string {
func testAccComputeInstanceGroup_outOfOrderInstances(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -546,7 +546,7 @@ func testAccComputeInstanceGroup_outOfOrderInstances(instance string) string {
func testAccComputeInstanceGroup_network(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -727,7 +727,7 @@ func testAccCheckComputeInstanceTemplateHasMinCpuPlatform(instanceTemplate *comp
func testAccComputeInstanceTemplate_basic() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -769,7 +769,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_preemptible() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -811,7 +811,7 @@ resource "google_compute_address" "foo" {
}
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -840,7 +840,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_networkTier() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -864,7 +864,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_networkIP(networkIP string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -891,7 +891,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_address(address string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -918,7 +918,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_disks() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -960,7 +960,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_subnet_auto(network string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1005,7 +1005,7 @@ resource "google_compute_subnetwork" "subnetwork" {
}
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1081,7 +1081,7 @@ func testAccComputeInstanceTemplate_subnet_xpn(org, billingId, projectName strin
}
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1112,7 +1112,7 @@ func testAccComputeInstanceTemplate_subnet_xpn(org, billingId, projectName strin
func testAccComputeInstanceTemplate_startup_script() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1142,7 +1142,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_primaryAliasIpRange(i string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1186,7 +1186,7 @@ resource "google_compute_subnetwork" "inst-test-subnetwork" {
}
}
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
resource "google_compute_instance_template" "foobar" {
@ -1223,7 +1223,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_guestAccelerator(i string, count uint8) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1257,7 +1257,7 @@ resource "google_compute_instance_template" "foobar" {
func testAccComputeInstanceTemplate_minCpuPlatform(i string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -1540,7 +1540,7 @@ func testAccCheckComputeInstanceHasConfiguredDeletionProtection(instance *comput
func testAccComputeInstance_basic(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1584,7 +1584,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_basic2(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1615,7 +1615,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_basic3(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1646,7 +1646,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_basic4(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1678,7 +1678,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_basic5(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1709,7 +1709,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_basic_deletionProtectionFalse(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1737,7 +1737,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_basic_deletionProtectionTrue(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1767,7 +1767,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_forceNewAndChangeMetadata(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1799,7 +1799,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_update(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1838,7 +1838,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_ip(ip, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1875,7 +1875,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_PTRRecord(record, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1908,7 +1908,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_generateIp(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1941,7 +1941,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_networkTier(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1973,7 +1973,7 @@ func testAccComputeInstance_disks_encryption(bootEncryptionKey string, diskNameT
}
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2061,7 +2061,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_attachedDisk(disk, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2097,7 +2097,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_attachedDisk_sourceUrl(disk, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2133,7 +2133,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_attachedDisk_modeRo(disk, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2170,7 +2170,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_addAttachedDisk(disk, disk2, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2217,7 +2217,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_detachDisk(disk, disk2, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2260,7 +2260,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_updateAttachedDiskEncryptionKey(disk, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2298,7 +2298,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_bootDisk_source(disk, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2327,7 +2327,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_bootDisk_sourceUrl(disk, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2356,7 +2356,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_bootDisk_type(instance string, diskType string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2382,7 +2382,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_scratchDisk(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2416,7 +2416,7 @@ resource "google_compute_instance" "scratch" {
func testAccComputeInstance_service_account(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2449,7 +2449,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_scheduling(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2478,7 +2478,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_subnet_auto(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2511,7 +2511,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_subnet_custom(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2551,7 +2551,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_subnet_xpn(org, billingId, projectName, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2629,7 +2629,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_address_auto(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2665,7 +2665,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_address_custom(instance, address string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2702,7 +2702,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_private_image_family(disk, family, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2743,7 +2743,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_multiNic(instance, network, subnetwork string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2783,7 +2783,7 @@ resource "google_compute_subnetwork" "inst-test-subnetwork" {
func testAccComputeInstance_guestAccelerator(instance string, count uint8) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2817,7 +2817,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_minCpuPlatform(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2843,7 +2843,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_primaryAliasIpRange(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2871,7 +2871,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_secondaryAliasIpRange(network, subnet, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2913,7 +2913,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_secondaryAliasIpRangeUpdate(network, subnet, instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2955,7 +2955,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_stopInstanceToUpdate(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -2992,7 +2992,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_stopInstanceToUpdate2(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -3028,7 +3028,7 @@ resource "google_compute_instance" "foobar" {
func testAccComputeInstance_stopInstanceToUpdate3(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -153,7 +153,7 @@ func testAccCheckComputeRegionAutoscalerUpdated(n string, max int64) resource.Te
func testAccComputeRegionAutoscaler_basic(it_name, tp_name, igm_name, autoscaler_name string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -218,7 +218,7 @@ resource "google_compute_region_autoscaler" "foobar" {
func testAccComputeRegionAutoscaler_update(it_name, tp_name, igm_name, autoscaler_name string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -308,7 +308,7 @@ func testAccComputeRegionBackendService_withBackend(
serviceName, igName, itName, checkName string, timeout int64) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -661,7 +661,7 @@ func testAccCheckRegionInstanceGroupManagerTemplateTags(n string, tags []string)
func testAccRegionInstanceGroupManager_basic(template, target, igm1, igm2 string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -720,7 +720,7 @@ func testAccRegionInstanceGroupManager_basic(template, target, igm1, igm2 string
func testAccRegionInstanceGroupManager_targetSizeZero(template, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -762,7 +762,7 @@ func testAccRegionInstanceGroupManager_targetSizeZero(template, igm string) stri
func testAccRegionInstanceGroupManager_update(template, target, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -816,7 +816,7 @@ func testAccRegionInstanceGroupManager_update(template, target, igm string) stri
func testAccRegionInstanceGroupManager_update2(template1, target1, target2, template2, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -907,7 +907,7 @@ func testAccRegionInstanceGroupManager_update2(template1, target1, target2, temp
func testAccRegionInstanceGroupManager_updateLifecycle(tag, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -952,7 +952,7 @@ func testAccRegionInstanceGroupManager_updateLifecycle(tag, igm string) string {
func testAccRegionInstanceGroupManager_separateRegions(igm1, igm2 string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1003,7 +1003,7 @@ func testAccRegionInstanceGroupManager_separateRegions(igm1, igm2 string) string
func testAccRegionInstanceGroupManager_autoHealingPolicies(template, target, igm, hck string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1059,7 +1059,7 @@ resource "google_compute_http_health_check" "zero" {
func testAccRegionInstanceGroupManager_versions(primaryTemplate string, canaryTemplate string, igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1131,7 +1131,7 @@ resource "google_compute_region_instance_group_manager" "igm-basic" {
func testAccRegionInstanceGroupManager_distributionPolicy(template, igm string, zones []string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1168,7 +1168,7 @@ resource "google_compute_region_instance_group_manager" "igm-basic" {
func testAccRegionInstanceGroupManager_updateStrategy(igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1214,7 +1214,7 @@ resource "google_compute_region_instance_group_manager" "igm-update-strategy" {
func testAccRegionInstanceGroupManager_rollingUpdatePolicy(igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -1270,7 +1270,7 @@ resource "google_compute_region_instance_group_manager" "igm-rolling-update-poli
func testAccRegionInstanceGroupManager_rollingUpdatePolicy2(igm string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -173,7 +173,7 @@ resource "google_compute_route" "foobar" {
func testAccComputeRoute_hopInstance(instanceName, zone string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -211,7 +211,7 @@ func testAccCheckComputeSnapshotExists(n string, snapshot *compute.Snapshot) res
func testAccComputeSnapshot_basic(snapshotName, diskName, labelValue string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}
@ -237,7 +237,7 @@ func testAccComputeSnapshot_encryption(snapshotName string, diskName string) str
return fmt.Sprintf(`
resource "google_compute_disk" "foobar" {
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}

View File

@ -106,7 +106,7 @@ func testAccCheckComputeTargetPoolHealthCheck(targetPool, healthCheck string) re
func testAccComputeTargetPool_basic() string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
name = "debian-9"
family = "debian-9"
project = "debian-cloud"
}