Some modifications so it works on AWS