location_nfs
Creates, updates, deletes, gets or lists a location_nfs resource.
Overview
| Name | location_nfs |
| Type | Resource |
| Id | aws.datasync.location_nfs |
Fields
The following fields are returned by SELECT queries:
- describe_location_nfs
| Name | Datatype | Description |
|---|---|---|
creation_time | string (date-time) | The time when the NFS location was created. |
location_arn | string | The ARN of the NFS location. (pattern: <code>^arn:(aws|aws-cn|aws-us-gov|aws-eusc|aws-iso|aws-iso-b):datasync:[a-z-0-9]+:[0-9]{12}:location/loc-[0-9a-z]{17}$</code>) |
location_uri | string | The URI of the NFS location. (pattern: <code>^(efs|nfs|s3|smb|hdfs|fsx[a-z0-9-]+)://[a-zA-Z0-9.:/-]+$</code>) |
mount_options | object | Specifies how DataSync can access a location using the NFS protocol. |
on_prem_config | object | The DataSync agents that can connect to your Network File System (NFS) file server. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_location_nfs | select | region | Provides details about how an DataSync transfer location for a Network File System (NFS) file server is configured. | |
create_location_nfs | insert | region, Subdirectory, ServerHostname, OnPremConfig | Creates a transfer location for a Network File System (NFS) file server. DataSync can use this location as a source or destination for transferring data. Before you begin, make sure that you understand how DataSync accesses NFS file servers. | |
update_location_nfs | update | region, LocationArn | Modifies the following configuration parameters of the Network File System (NFS) transfer location that you're using with DataSync. For more information, see Configuring transfers with an NFS file server. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
region | string | AWS region (default: us-east-1) |
SELECT examples
- describe_location_nfs
Provides details about how an DataSync transfer location for a Network File System (NFS) file server is configured.
SELECT
creation_time,
location_arn,
location_uri,
mount_options,
on_prem_config
FROM aws.datasync.location_nfs
WHERE region = '{{ region }}' -- required
;
INSERT examples
- create_location_nfs
- Manifest
Creates a transfer location for a Network File System (NFS) file server. DataSync can use this location as a source or destination for transferring data. Before you begin, make sure that you understand how DataSync accesses NFS file servers.
INSERT INTO aws.datasync.location_nfs (
Subdirectory,
ServerHostname,
OnPremConfig,
MountOptions,
Tags,
region
)
SELECT
'{{ Subdirectory }}' /* required */,
'{{ ServerHostname }}' /* required */,
'{{ OnPremConfig }}' /* required */,
'{{ MountOptions }}',
'{{ Tags }}',
'{{ region }}'
RETURNING
location_arn
;
# Description fields are for documentation purposes
- name: location_nfs
props:
- name: region
value: "{{ region }}"
description: Required parameter for the location_nfs resource.
- name: Subdirectory
value: "{{ Subdirectory }}"
description: |
Specifies the export path in your NFS file server that you want DataSync to mount. 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.
- name: ServerHostname
value: "{{ ServerHostname }}"
description: |
Specifies the DNS name or IP address (IPv4 or IPv6) of the NFS file server that your DataSync agent connects to.
- name: OnPremConfig
description: |
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.
value:
AgentArns:
- "{{ AgentArns }}"
- name: MountOptions
description: |
Specifies how DataSync can access a location using the NFS protocol.
value:
Version: "{{ Version }}"
- name: Tags
description: |
Specifies labels that help you categorize, filter, and search for your Amazon Web Services resources. We recommend creating at least a name tag for your location.
value:
- Key: "{{ Key }}"
Value: "{{ Value }}"
UPDATE examples
- update_location_nfs
Modifies the following configuration parameters of the Network File System (NFS) transfer location that you're using with DataSync. For more information, see Configuring transfers with an NFS file server.
UPDATE aws.datasync.location_nfs
SET
LocationArn = '{{ LocationArn }}',
Subdirectory = '{{ Subdirectory }}',
ServerHostname = '{{ ServerHostname }}',
OnPremConfig = '{{ OnPremConfig }}',
MountOptions = '{{ MountOptions }}'
WHERE
region = '{{ region }}' --required
AND LocationArn = '{{ LocationArn }}' --required;