Copy file or file content to EC2 without using remote-exec or file provisioner

I am provisioning AWS EC2 instances with terraform scripts and have to copy some files to it. Unfortunately, SSH login is not allowed in EC2’s in that VPC.

So is there any way to copy files from my local to remote EC2?

I found remote-exec and file provisioners, but both required SSH connections to copy files.