Skip to content

Commit

Permalink
Update Azure NFS module outputs and cloud init script (#80)
Browse files Browse the repository at this point in the history
Signed-off-by: Jim Enright <[email protected]>
  • Loading branch information
jimright authored Oct 25, 2024
1 parent 255e420 commit 13f041e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
1 change: 1 addition & 0 deletions modules/terraform-azure-nfs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ No modules.

| Name | Description |
|------|-------------|
| <a name="output_nfs_file_share_nfs_domain_url"></a> [nfs\_file\_share\_nfs\_domain\_url](#output\_nfs\_file\_share\_nfs\_domain\_url) | NFS File Share domain with nfs protocol prefix |
| <a name="output_nfs_file_share_url"></a> [nfs\_file\_share\_url](#output\_nfs\_file\_share\_url) | NFS File Share url |
| <a name="output_nfs_storage_account_name"></a> [nfs\_storage\_account\_name](#output\_nfs\_storage\_account\_name) | NFS Storage Account Name |
| <a name="output_nfs_vm_mount_path"></a> [nfs\_vm\_mount\_path](#output\_nfs\_vm\_mount\_path) | Path where NFS is mounted on the VM |
Expand Down
3 changes: 2 additions & 1 deletion modules/terraform-azure-nfs/files/mount_nfs_on_vm.sh.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
apt-get -y update
apt-get -y install nfs-common
mkdir -p /mount/${nfs_storage_account_name}/${nfs_file_share_name}
mount -t nfs ${nfs_storage_account_name}.file.core.windows.net:/${nfs_storage_account_name}/${nfs_file_share_name} /mount/${nfs_storage_account_name}/${nfs_file_share_name} -o vers=4,minorversion=1,sec=sys
mount -t nfs ${nfs_storage_account_name}.file.core.windows.net:/${nfs_storage_account_name}/${nfs_file_share_name} /mount/${nfs_storage_account_name}/${nfs_file_share_name} -o vers=4,minorversion=1,sec=sys
chown 8536:8536 /mount/${nfs_storage_account_name}/${nfs_file_share_name}
7 changes: 7 additions & 0 deletions modules/terraform-azure-nfs/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ output "nfs_file_share_url" {
description = "NFS File Share url"
}

output "nfs_file_share_nfs_domain_url" {
value = "nfs://${var.nfs_storage_account_name}.file.core.windows.net:/${var.nfs_storage_account_name}/${var.nfs_file_share_name}"

description = "NFS File Share domain with nfs protocol prefix"
}


output "nfs_storage_account_name" {
value = azurerm_storage_account.nfs_storage_account.name
description = "NFS Storage Account Name"
Expand Down

0 comments on commit 13f041e

Please sign in to comment.