From the Amazon VPC menu, choose Endpoints.
Click the name of newly created endpoint: s3-interface-endpoint. Click details and save the regional DNS name of the endpoint (the first one) to your text-editor for later use.
Navigate to Session manager by typing “session manager” in the search box
Click Start Session, and select the EC2 instance named Test-Interface-Endpoint. This EC2 instance is running in “VPC On-prem” and will be used to test connectivty to Amazon S3 through the Interface endpoint we just created. Session Manager will open a new browser tab with a shell prompt: sh-4.2 $
Change to the ssm-user’s home directory with command “cd ~”
Create a file named testfile2.xyz
fallocate -l 1G testfile2.xyz
aws s3 cp --endpoint-url https://bucket.<Regional-DNS-Name> testfile2.xyz s3://<your-bucket-name>
Now the file has been added to your S3 bucket. Let check your S3 bucket in the next step.