You can use VMware Tanzu Application Service for VMs (TAS for VMs) to deploy NFS or SMB volume services.
A volume service gives apps access to a persistent filesystem, such as NFS or SMB. By performing the procedures in this topic, you can add a volume service to the Marketplace that provides an NFS filesystem or an SMB share. For more information about adding a volume service to the Marketplace, see Services.
Developers can then use the Cloud Foundry Command Line Interface (cf CLI) to create service instances of the volume service and bind them to their apps. For more information, see Using an External File System (Volume Services).
You must have a running NFS or SMB server to test NFS or SMB volume services. TAS for VMs packages the necessary software to provide app connectivity to remote network-attached storage (NAS), but does not supply the NAS itself.
To activate NFS volume services in TAS for VMs:
Go to the Tanzu Operations Manager Installation Dashboard.
Click the TAS for VMs tile.
Select App Containers.
Under NFSv3 volume services, select Allow.
Note In a clean install, NFS volume services are activated by default. In an upgrade, NFS volume services match the setting of the previous deployment.
(Optional) To configure LDAP for NFS volume services:
If you already use an LDAP server with your network-attached storage (NAS) file server, enter the information in the following fields. This ensures that the identities known to the file server match those checked by the NFS driver.
For LDAP user search base, enter the location in the LDAP directory tree from which any LDAP user search begins. The typical LDAP search base matches your domain name. For example, a domain named cloud.example.com
typically uses the following LDAP user search base: ou=Users,dc=example,dc=com
.
Additionally, your LDAP user records must be configured with an attribute objectClass: User
, which is used by the NFS driver to identify records as user records. They must also have uidNumber
and gidNumber
fields, which are used to establish the correct UID for a named user.
Click Save.
Return to the Tanzu Operations Manager Installation Dashboard, click Review Pending Changes, and click Apply Changes to redeploy.
Using the cf CLI, activate access to the service by running:
cf enable-service-access nfs
To limit access to a specific org, use the -o
flag, followed by the name of the org where you want to activate access. For more information, see Access Control.
(Optional) Activate access to the nfs-legacy
service by running:
cf enable-service-access nfs-legacy
For details about the differences between the two nfs
services, see the NFS Volume Service section of the Using an External File System (Volume Services) topic.
After completing these steps, developers can use the cf CLI to create service instances of the nfs
service and bind them to their apps.
You can use ASGs and LDAP to secure your NFS server against traffic apps running on TAS for VMs:
App Security Groups (ASGs): Prevent apps from sending traffic directly to your NFS ports. Apps must never need to use NFS ports directly. VMware recommends defining an ASG that blocks direct access to your NFS server IP, especially ports 111 and 2049. For more information on setting up ASGs, see App Security Groups.
LDAP: In addition to ASGs, secures the NFS volume service so that app developers cannot bind to the service using an arbitrary UID. App developers also cannot gain access to sensitive data. With LDAP support activated, app developers must provide credentials for any user they want to bind as.
The Diego Cells running on TAS for VMs must be able to reach your LDAP server on the port you use for connections, which are typically 389 or 636. You cannot limit which Diego Cells have access to your NFS or LDAP servers.
In a clean install, SMB volume services are activated by default. In an upgrade, SMB volume services match the setting of the previous deployment.
To activate SMB volume services in TAS for VMs:
Go to the Tanzu Operations Manager Installation Dashboard.
Click the TAS for VMs tile.
Select App Containers.
Select the Allow SMB volume services check box.
Click Save.
Select Errands.
Set the SMB Broker Errand to On.
Click Save.
Return to the Tanzu Operations Manager Installation Dashboard, click Review Pending Changes, and click Apply Changes to redeploy.
Using the cf CLI, activate access to the service by running:
cf enable-service-access smb
To limit access to a specific org, use the -o
flag, followed by the name of the org where you want to enable access. For more information, see Access Control.
After you complete these steps, developers can use the cf CLI to create service instances of the smb
service and bind them to their apps.