provider/ec2: break out some of the functionality in to seperate files