updated to allow use on ec2