-
Notifications
You must be signed in to change notification settings - Fork 5
/
datasources.tf
38 lines (32 loc) · 1.38 KB
/
datasources.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
data "oci_core_vnic_attachments" "CCCWebserver_VNIC1_attach" {
count = var.NumberOfNodes
availability_domain = lookup(data.oci_identity_availability_domains.ADs.availability_domains[0], "name")
compartment_id = oci_identity_compartment.CCCCompartment.id
instance_id = oci_core_instance.CCCWebserver[count.index].id
}
data "oci_core_vnic" "CCCWebserver_VNIC1" {
count = var.NumberOfNodes
vnic_id = data.oci_core_vnic_attachments.CCCWebserver_VNIC1_attach[count.index].vnic_attachments.0.vnic_id
}
data "oci_core_vnic_attachments" "CCCBastionServer_VNIC1_attach" {
availability_domain = lookup(data.oci_identity_availability_domains.ADs.availability_domains[0], "name")
compartment_id = oci_identity_compartment.CCCCompartment.id
instance_id = oci_core_instance.CCCBastionServer.id
}
data "oci_core_vnic" "CCCBastionServer_VNIC1" {
vnic_id = data.oci_core_vnic_attachments.CCCBastionServer_VNIC1_attach.vnic_attachments.0.vnic_id
}
data "oci_core_images" "InstanceImageOCID" {
compartment_id = var.compartment_ocid
operating_system = var.instance_os
operating_system_version = var.linux_os_version
filter {
name = "display_name"
values = ["^.*Oracle[^G]*$"]
regex = true
}
}
# Gets a list of Availability Domains
data "oci_identity_availability_domains" "ADs" {
compartment_id = var.tenancy_ocid
}