Skip to content

Commit 775e73d

Browse files
author
nichollri
committed
Still working on getting intercluster LIFs to work, I can get svm data LIFs
1 parent d25b88c commit 775e73d

File tree

2 files changed

+35
-16
lines changed

2 files changed

+35
-16
lines changed

Terraform/fsxn-replicate/main.tf

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ resource "netapp-ontap_storage_volume_resource" "volloop" {
120120
}
121121
nas = {
122122
export_policy_name = "default"
123-
security_style = "unix"
123+
# security_style = "unix"
124124
# junction_path = join("", ["/",each.value.name])
125125
}
126126
}
@@ -133,7 +133,8 @@ data "netapp-ontap_networking_ip_interfaces_data_source" "primary_intercluster_l
133133
cx_profile_name = "primary_clus"
134134
filter = {
135135
svm_name = var.prime_svm
136-
name = "inter*" # Filter to only get intercluster LIFs
136+
# svm_name = "FsxId020de2687bd98ccf7"
137+
name = "iscsi_*" # Filter to only get intercluster LIFs
137138
}
138139
}
139140

@@ -149,21 +150,21 @@ data "netapp-ontap_networking_ip_interfaces_data_source" "dr_intercluster_lifs"
149150

150151
# Now udse the LIF names and IP addresses to peer the clusters
151152

152-
resource "netapp-ontap_cluster_peers_resource" "cluster_peer" {
153-
cx_profile_name = "primary_clus" # Source cluster profile
154-
peer_cx_profile_name = "dr_clus" # Destination (peer) cluster profile
153+
# resource "netapp-ontap_cluster_peers_resource" "cluster_peer" {
154+
# cx_profile_name = "primary_clus" # Source cluster profile
155+
# peer_cx_profile_name = "dr_clus" # Destination (peer) cluster profile
156+
#
157+
# remote = {
158+
# # Destination cluster (DR) intercluster LIF IPs
159+
# ip_addresses = [for lif in data.netapp-ontap_networking_ip_interfaces_data_source.dr_intercluster_lifs.ip_interfaces : lif.ip_address]
160+
# }
155161

156-
remote = {
157-
# Destination cluster (DR) intercluster LIF IPs
158-
ip_addresses = [for lif in data.netapp-ontap_networking_ip_interfaces_data_source.dr_intercluster_lifs.ip_interfaces : lif.ip_address]
159-
}
160-
161-
source_details = {
162-
# Source cluster (primary) intercluster LIF IPs
163-
ip_addresses = [for lif in data.netapp-ontap_networking_ip_interfaces_data_source.primary_intercluster_lifs.ip_interfaces : lif.ip_address]
164-
}
162+
# source_details = {
163+
# Source cluster (primary) intercluster LIF IPs
164+
# ip_addresses = [for lif in data.netapp-ontap_networking_ip_interfaces_data_source.primary_intercluster_lifs.ip_interfaces : lif.ip_address]
165+
# }
165166

166167
# Optional: Add authentication, passphrase or any other required settings
167168
# passphrase = var.cluster_peer_passphrase # Optional, if you use passphrase for peering
168-
peer_applications = ["snapmirror"]
169-
}
169+
# peer_applications = ["snapmirror"]
170+
#}

Terraform/fsxn-replicate/output.tf

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,21 @@ output "volume_details" {
88
}
99
description = "Details of the volumes including name, type, size, and size unit"
1010
}
11+
12+
#output "lifs" {
13+
# value = {
14+
# for key, lif in data.netapp-ontap_networking_ip_interfaces_data_source.primary_intercluster_lifs : key => {
15+
# name = lif.ip_interfaces.name
16+
# ip_address = lif.ip_interfaces.ip.ip_address
17+
# }
18+
# }
19+
# description = "Details of source intercluster LIFs"
20+
#}
21+
22+
output "primary_intercluster_lifs_details" {
23+
value = {
24+
for lif in data.netapp-ontap_networking_ip_interfaces_data_source.primary_intercluster_lifs.ip_interfaces : lif.name => lif.ip.address
25+
}
26+
description = "Intercluster LIF names and IP addresses for the primary existing cluster"
27+
}
28+

0 commit comments

Comments
 (0)