awslabs / web-client-for-aws-transfer-family

This solution creates a web portal for your customers to access your corporate Secure Shell File Transfer Protocol (SFTP) environment. It combines the benefits of using AWS Transfer for SFTP with an intuitive web browser interface for your non-technical users.
https://aws.amazon.com/solutions/implementations/web-client-for-aws-transfer-family/?did=sl_card&trk=sl_card
Apache License 2.0
73 stars 41 forks source link

SFTP Endpoint Stack Create failures #7

Closed michaewahl closed 2 years ago

michaewahl commented 2 years ago

03- sftp-endpoint.template

SFTPCustomAuthLambda | CREATE_FAILED | Properties validation failed for resource SFTPCustomAuthLambda with message: #/Code/S3Bucket: failed validation constraint for keyword [pattern]


AWSTemplateFormatVersion: "2010-09-09" Description: (SO0103-sftpendpoint) %%SOLUTION_NAME%% - This template creates Lambda-backed API Gateway for integrating with custom identity provider in AWS Transfer Family with SFTP.

Parameters:

AWSTransferForSFTPS3Bucket: Type: String Description : The name of the S3 bucket used for the SFTP server

TODO: what are requirements? Just create it instead of relying on default sg.

AWSTransferVPCSecGroup: Type: AWS::EC2::SecurityGroup::Id Description: Default Security Group for the VPC identified before

VPCResourceStack: Type: String MinLength: 1 MaxLength: 255 AllowedPattern: "^[a-zA-Z][-a-zA-Z0-9]*$" Default: sftp-vpc-stack

CognitoResourceStack: Type: String MinLength: 1 MaxLength: 255 AllowedPattern: "^[a-zA-Z][-a-zA-Z0-9]*$" Default: sftp-cognito-stack

Mappings: SourceCode: General: S3Bucket: "%%BUCKET_NAME%%" KeyPrefix: "%%SOLUTION_NAME%%/%%VERSION%%"

Resources:

TransferSFTPCloudWatchLogsWriteLogs: Description: Allows AWS Transfer Family to write CloudWatchLogs Type: AWS::IAM::Role Properties: AssumeRolePolicyDocument: Version: "2012-10-17" Statement:

Outputs: StackArn: Value: Ref: AWS::StackId TransferIdentityProviderUrl: Description: URL to pass to AWS Transfer CreateServer call as part of optional IdentityProviderDetails Value: Fn::Join:

rahmansamia commented 2 years ago

@michaewahl Please make sure you created the dist folder by using below command. ./build-dist.sh solutions web-client-for-aws-transfer-family v1.0.0

After that upload the 'sftp-endpoint.template' template from dist/deployment folder. If you upload the template from initial folder that was created after clone it will fail.

michaewahl commented 2 years ago

@rahmansamia Thank you, I will look into that suggestion today.