I won't defend US incompetence wrt infrastructure. But I will observe that "spending more" hardly seems to be the problem, as we seem to do plenty of that already. It's that (lack of) stuff we get in return that's the problem.
As far as global "peace", it is certainly true there is still conflict, but from the bigger picture perspective it's been a relatively peaceful half century.
Again I'll point to this chart: https://ourworldindata.org/war-and-peace. Consider that the y-axis is log scale, and contemplate the WWI and WWII bubbles at the top.
But say what if US had reduced military spending after the collapse of Soviet Union by let's say half, would the world be much worse than it's today? From statistical perspective while it seems that there's causation between US military superiority and the lack of conflicts compared to prior decades, it might be as well that the world has just become less warlike. Sure it would suck if WW3 happened though. Anyway, it's not a reason not to fix your infrastructure :).
Sure it's hard to assess how much military spending is the "right" amount and how much US prevents unrest on global scale. But let's not kid ourselves, we'd all be better off if we didn't have to spend money on keeping armies. They produce next to nothing on economic growth or scientific progress. We'd be having colonies on Mars if US had spent a part of that money on NASA.