changes to make it work on ec2