Skip to content

Commit 19b85d3

Browse files
committed
Automation Toolkit Release v11.1
1 parent 82f8505 commit 19b85d3

File tree

3 files changed

+36
-4
lines changed

3 files changed

+36
-4
lines changed

cd3_automation_toolkit/Release-Notes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ CD3 Automation Toolkit Tag v11.1
55
2. Python code cleanup
66
3. Sheet name fix for NLB in CD3-Blank-template.xlsx
77
4. SDDC template fix
8+
5. Support for VPN along with CD3 docker container
89

910
-----------------------------------
1011
CD3 Automation Toolkit Tag v11

cd3_automation_toolkit/user-scripts/terraform/modules/compute/instance/data.tf

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -127,10 +127,10 @@ data "oci_marketplace_listing_packages" "listing_packages" {
127127
}
128128

129129
data "oci_marketplace_listings" "listings" {
130-
count = length(regexall("ocid1.image.oc1*", var.source_image_id)) > 0 || length(regexall("ocid1.bootvolume.oc1*", var.source_image_id)) > 0 || var.source_image_id == null ? 0 : 1
131-
name = [var.source_image_id]
132-
is_featured = true # Comment this line for GovCloud
133-
compartment_id = var.compartment_id
130+
count = length(regexall("ocid1.image.oc1*", var.source_image_id)) > 0 || length(regexall("ocid1.bootvolume.oc1*", var.source_image_id)) > 0 || var.source_image_id == null ? 0 : 1
131+
name = [var.source_image_id]
132+
#is_featured = true # Comment this line for GovCloud
133+
compartment_id = var.compartment_id
134134
}
135135

136136
data "oci_marketplace_listing" "listing" {
@@ -139,6 +139,11 @@ data "oci_marketplace_listing" "listing" {
139139
compartment_id = var.compartment_id
140140
}
141141

142+
data "oci_core_app_catalog_listing_resource_versions" "app_catalog_listing_resource_versions" {
143+
count = length(regexall("ocid1.image.oc1*", var.source_image_id)) > 0 || length(regexall("ocid1.bootvolume.oc1*", var.source_image_id)) > 0 || var.source_image_id == null ? 0 : 1
144+
listing_id = data.oci_marketplace_listing_package.listing_package.0.app_catalog_listing_id
145+
}
146+
142147
data "oci_core_app_catalog_listing_resource_version" "catalog_listing" {
143148
count = length(regexall("ocid1.image.oc1*", var.source_image_id)) > 0 || length(regexall("ocid1.bootvolume.oc1*", var.source_image_id)) > 0 || var.source_image_id == null ? 0 : 1
144149
listing_id = data.oci_marketplace_listing_package.listing_package.0.app_catalog_listing_id

cd3_automation_toolkit/user-scripts/terraform/modules/compute/instance/main.tf

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,4 +237,30 @@ resource "oci_marketplace_listing_package_agreement" "listing_package_agreement"
237237
agreement_id = data.oci_marketplace_listing_package_agreements.listing_package_agreements.0.agreements[0].id
238238
listing_id = data.oci_marketplace_listing.listing.0.id
239239
package_version = data.oci_marketplace_listing.listing.0.default_package_version
240+
}
241+
242+
#------ Get Image Agreement
243+
resource "oci_core_app_catalog_listing_resource_version_agreement" "mp_image_agreement" {
244+
count = length(regexall("ocid1.image.oc1*", var.source_image_id)) > 0 || length(regexall("ocid1.bootvolume.oc1*", var.source_image_id)) > 0 || var.source_image_id == null ? 0 : 1
245+
listing_id = data.oci_marketplace_listing_package.listing_package.0.app_catalog_listing_id
246+
#listing_resource_version = data.oci_marketplace_listing_package.listing_package.0.app_catalog_listing_resource_version
247+
listing_resource_version = data.oci_core_app_catalog_listing_resource_versions.app_catalog_listing_resource_versions.0.app_catalog_listing_resource_versions[0].listing_resource_version
248+
}
249+
250+
251+
252+
# ------ Accept Terms and Subscribe to the image, placing the image in a particular compartment
253+
resource "oci_core_app_catalog_subscription" "mp_image_subscription" {
254+
count = length(regexall("ocid1.image.oc1*", var.source_image_id)) > 0 || length(regexall("ocid1.bootvolume.oc1*", var.source_image_id)) > 0 || var.source_image_id == null ? 0 : 1
255+
compartment_id = var.compartment_id
256+
eula_link = oci_core_app_catalog_listing_resource_version_agreement.mp_image_agreement[0].eula_link
257+
listing_id = oci_core_app_catalog_listing_resource_version_agreement.mp_image_agreement[0].listing_id
258+
listing_resource_version = oci_core_app_catalog_listing_resource_version_agreement.mp_image_agreement[0].listing_resource_version
259+
oracle_terms_of_use_link = oci_core_app_catalog_listing_resource_version_agreement.mp_image_agreement[0].oracle_terms_of_use_link
260+
signature = oci_core_app_catalog_listing_resource_version_agreement.mp_image_agreement[0].signature
261+
time_retrieved = oci_core_app_catalog_listing_resource_version_agreement.mp_image_agreement[0].time_retrieved
262+
263+
timeouts {
264+
create = "20m"
265+
}
240266
}

0 commit comments

Comments
 (0)