That's not true.
Military is only for war.
US Army guarding Negro students during 1960s desegragation.
View attachment 682395
US elite 101st Airborne Division guarding young Black students at Little Rock.
View attachment 682396
US Corp of Engineers as well as building dams, river engineering works, highways and in picture below converting to hospitals during coronvirus pandemic.
View attachment 682398
National Guardsmen on streets during recent Black Lives protest. They look better rigged then Pakistan Army sokdiers.
View attachment 682399
Yes, sure military is ONLY for war.
Most of them are National Guard units. There are strict constitutional safeguards about deploying US military units on American soil. Most important thing is that US military does not interfere in domestic poilitics in spite of the fact they prefer and vote for Republican policies and leaders