oci_file_storage_mount_target

This resource provides the Mount Target resource in Oracle Cloud Infrastructure File Storage service.

Creates a new mount target in the specified compartment and subnet. You can associate a file system with a mount target only when they exist in the same availability domain. Instances can connect to mount targets in another availablity domain, but you might see higher latency than with instances in the same availability domain as the mount target.

Mount targets have one or more private IP addresses that you can provide as the host portion of remote target parameters in client mount commands. These private IP addresses are listed in the privateIpIds property of the mount target and are highly available. Mount targets also consume additional IP addresses in their subnet. Do not use /30 or smaller subnets for mount target creation because they do not have sufficient available IP addresses. Allow at least three IP addresses for each mount target.

For information about access control and compartments, see Overview of the IAM Service.

For information about availability domains, see Regions and Availability Domains. To get a list of availability domains, use the ListAvailabilityDomains operation in the Identity and Access Management Service API.

All Oracle Cloud Infrastructure Services resources, including mount targets, get an Oracle-assigned, unique ID called an Oracle Cloud Identifier (OCID). When you create a resource, you can find its OCID in the response. You can also retrieve a resource’s OCID by using a List API operation on that resource type, or by viewing the resource in the Console.

Example Usage

resource "oci_file_storage_mount_target" "test_mount_target" {
	#Required
	availability_domain = var.mount_target_availability_domain
	compartment_id = var.compartment_id
	subnet_id = oci_core_subnet.test_subnet.id

	#Optional
	defined_tags = {"Operations.CostCenter"= "42"}
	display_name = var.mount_target_display_name
	freeform_tags = {"Department"= "Finance"}
	hostname_label = var.mount_target_hostname_label
	idmap_type = var.mount_target_idmap_type
	ip_address = var.mount_target_ip_address
	kerberos {
		#Required
		kerberos_realm = var.mount_target_kerberos_kerberos_realm

		#Optional
		backup_key_tab_secret_version = var.mount_target_kerberos_backup_key_tab_secret_version
		current_key_tab_secret_version = var.mount_target_kerberos_current_key_tab_secret_version
		is_kerberos_enabled = var.mount_target_kerberos_is_kerberos_enabled
		key_tab_secret_id = oci_vault_secret.test_secret.id
	}
	ldap_idmap {

		#Optional
		cache_lifetime_seconds = var.mount_target_ldap_idmap_cache_lifetime_seconds
		cache_refresh_interval_seconds = var.mount_target_ldap_idmap_cache_refresh_interval_seconds
		group_search_base = var.mount_target_ldap_idmap_group_search_base
		negative_cache_lifetime_seconds = var.mount_target_ldap_idmap_negative_cache_lifetime_seconds
		outbound_connector1id = oci_file_storage_outbound_connector1.test_outbound_connector1.id
		outbound_connector2id = oci_file_storage_outbound_connector2.test_outbound_connector2.id
		schema_type = var.mount_target_ldap_idmap_schema_type
		user_search_base = var.mount_target_ldap_idmap_user_search_base
	}
	nsg_ids = var.mount_target_nsg_ids
}

Argument Reference

The following arguments are supported:

** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

Attributes Reference

The following attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain operations: * create - (Defaults to 20 minutes), when creating the Mount Target * update - (Defaults to 20 minutes), when updating the Mount Target * delete - (Defaults to 20 minutes), when destroying the Mount Target

Import

MountTargets can be imported using the id, e.g.

$ terraform import oci_file_storage_mount_target.test_mount_target "id"