You have probably checked military records for your ancestor. Don’t forget the “smaller” wars!
I have an ancestor that lived during the Indiana Wars in Arizona. He was not actually fighting in the war. However, he was buried at the Fort Grant. He was inside the fort during one of the raids, and was killed and buried in the cemetery there.
So, just because he didn’t actually fight in the war, don’t think that your ancestor didn’t have anything to do with it!