I would like to setup a simple SFTP server using AWS Transfer Family. I use AWS CDK (typescript) to set it up. I would like to use Custom Hostname (Route53 sub-domain) while creating SFTP server.
I tried following options...
Adding tags from CDK does not work, aws:transfer:route53HostedZoneId and aws:transfer:customHostname. I don't know how to get the SFTP endpoint url inside CDK. Was anyone able to fetch it?
Adding tags from CLI works but I don't want to write a followup script for this. And there is also a challenge to find the SFTP server that is created as part of CDK execution. This solution does not fit in my use case.
Has anyone faced this issue?
So, I want to setup AWS Transfer SFTP server, use it to transfer files and tear it down. However, I would like to keep the SFTP url same (Route53 url).
Thanks in advance!
Yes, it is possible. This is done through tags from the CDK
SFTPServer: Type: 'AWS::Transfer::Server' Properties: Tags: - Key: "aws:transfer:customHostname" Value: !Ref CustomHostname - Key: "aws:transfer:route53HostedZoneId" Value: !Join [ '/', [ "/hostedzone", !Ref HostedZoneID] ]
It will be something like this: