Increase work_mem for postgresql
Decrease the amount of memory elasticsearch can use, we were swapping regularly.