CfnLocationNFSProps Struct
Properties for defining a CfnLocationNFS.
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_datasync as datasync } from 'aws-cdk-lib';
const cfnLocationNFSProps: datasync.CfnLocationNFSProps = {
onPremConfig: {
agentArns: ['agentArns'],
},
// the properties below are optional
mountOptions: {
version: 'version',
},
serverHostname: 'serverHostname',
subdirectory: 'subdirectory',
tags: [{
key: 'key',
value: 'value',
}],
};
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_datasync as datasync
cfn_location_nfs_props = datasync.CfnLocationNFSProps(
on_prem_config=datasync.CfnLocationNFS.OnPremConfigProperty(
agent_arns=["agentArns"]
),
# the properties below are optional
mount_options=datasync.CfnLocationNFS.MountOptionsProperty(
version="version"
),
server_hostname="serverHostname",
subdirectory="subdirectory",
tags=[CfnTag(
key="key",
value="value"
)]
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.datasync.*;
CfnLocationNFSProps cfnLocationNFSProps = CfnLocationNFSProps.builder()
.onPremConfig(OnPremConfigProperty.builder()
.agentArns(List.of("agentArns"))
.build())
// the properties below are optional
.mountOptions(MountOptionsProperty.builder()
.version("version")
.build())
.serverHostname("serverHostname")
.subdirectory("subdirectory")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.DataSync;
var cfnLocationNFSProps = new CfnLocationNFSProps {
OnPremConfig = new OnPremConfigProperty {
AgentArns = new [] { "agentArns" }
},
// the properties below are optional
MountOptions = new MountOptionsProperty {
Version = "version"
},
ServerHostname = "serverHostname",
Subdirectory = "subdirectory",
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
cfnLocationNFSProps := &CfnLocationNFSProps{
OnPremConfig: &OnPremConfigProperty{
AgentArns: []*string{
jsii.String("agentArns"),
},
},
// the properties below are optional
MountOptions: &MountOptionsProperty{
Version: jsii.String("version"),
},
ServerHostname: jsii.String("serverHostname"),
Subdirectory: jsii.String("subdirectory"),
Tags: []CfnTag{
&CfnTag{
Key: jsii.String("key"),
Value: jsii.String("value"),
},
},
}
Properties
mountOptionsoptionalIResolvable | CfnLocationNFS.MountOptionsPropertymount_optionsoptionaltyping.Union[IResolvable, MountOptionsProperty]mountOptionsoptionalIResolvableMountOptionsoptionalIResolvableMountOptionsoptionalinterface{}#Specifies the options that DataSync can use to mount your NFS file server.
onPremConfigIResolvable | CfnLocationNFS.OnPremConfigPropertyon_prem_configtyping.Union[IResolvable, OnPremConfigProperty]onPremConfigIResolvableOnPremConfigIResolvableOnPremConfiginterface{}required#Specifies the Amazon Resource Name (ARN) of the DataSync agent that can connect to your NFS file server.
You can specify more than one agent. For more information, see Using multiple DataSync agents .
serverHostnameoptionalstringserver_hostnameoptionalstrserverHostnameoptionalStringServerHostnameoptionalstringServerHostnameoptional*string#Specifies the DNS name or IP address (IPv4 or IPv6) of the NFS file server that your DataSync agent connects to.
subdirectoryoptionalstringsubdirectoryoptionalstrsubdirectoryoptionalStringSubdirectoryoptionalstringSubdirectoryoptional*string#Specifies the export path in your NFS file server that you want DataSync to mount.
notes
This path (or a subdirectory of the path) is where DataSync transfers data to or from. For information on configuring an export for DataSync, see Accessing NFS file servers .