You can use a VPC endpoint to create a private connection between your VPC and Amazon ECR without requiring access over the internet or through a NAT device, a VPN connection, or AWS Direct Connect.
https://docs.aws.amazon.com/AmazonECR/latest/userguide/vpc-endpoints.html