I was trying to set up VPC peering in AWS. I got most of it working but the network connectivity didn't work. I narrowed down the difference to the routes.
In my previous working system I had the VPC peering route in the main routing table, but when I terraformed a new system I tried to create a separate routing table with the VPC peering route but that didn't work.
I had to manually go to AWS console to add the route on the main route table for the communications to work.