You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Terraform cloud-init is ignored when are_legacy_imds_endpoints_disabled = true is used

Situation:

I am provisioning compute instances in OCI with Linux and Windows images, different versions. In cloud-init script, users are created, OS settings are changed. According security requirements of the company, the metadata version has to be set to 2 only now. But when disabling metadata V1 in Terraform code, the cloud-init block is ignored.

Code Block:

The metadata and instance_options block are set, but cloud-init is ignored when are_legacy_imds_endpoints_disabled is set to true.

verify availability domain -------------------------------------------------
data "oci_identity_availability_domains" "ads" {
compartment_id = var.compartment_id
} Oracle Linux instance according image OCID resource "oci_core_instance" "compute_instance" {

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!