How to point an SFTP user to a specific S3 location
Overview
This article covers how to point SFTP users to a specific S3 location.
This is useful if you want to override the default folder structure that is created by SFTP Gateway in S3 (e.g. /users/username
).
Pointing an SFTP user to a custom S3 location involves 3 steps:
- Create a Cloud Connection that points to the S3 location
- Create a Folder that maps to the Cloud Connection
- Point the SFTP user's Home Directory to that Folder.
Step 1: Create a Cloud Connection
First, you want to create a new Cloud Connection. This will let you define a S3 path of your choosing.
For example, here is a Cloud Connection with the following settings:
- Cloud Connection Name:
AWS Cloud Connection
- Bucket Name:
sftpgw-testing-bucket
- Region:
us-east-1
- S3 Encryption Type:
SSE-S3
See this article for more information on how to create a Cloud Connection.
Step 2: Map a Folder
Make a Folder which points to this Cloud Connection.
This Folder acts as a bridge that maps an SFTP user's Home Directory to a Cloud Connection.
In this example, the Folder maps to the AWS Cloud Connection
.
See this article for more information on Folders.
Step 3: Set the SFTP user's Home Directory
Point the SFTP user's Home Directory to the Folder you created earlier.
See this article for more information on setting a Home Directory.