Also, bonus question: is this actually true? I can find lots of references to these restrictions online but can't find any primary sources.
I’ll take the bonus question first because it’s easiest. The restrictions placed on the flamen Dialis are certainly true. For ancient evidence, the best source is Aulus Gellius (Attic Nights 10.15), who says he got his information from two other texts: a book by an unnamed author called On Public Priests and another by a second century BC writer called Fabius Pictor (probably not the historian of the same name). Gellius is invoking long tradition here, and it seems to be the case that this priesthood was one of the oldest in the city. Gellius goes on to say that, by his time, some of these obligations have been either relaxed or dropped entirely, and it does seem that late republican and early imperial Romans thought the priesthood was too onerous. Indeed, there was no flamen Dialis at all from 87 to 12 BC.
A minor point, but this priesthood wasn’t the head of the Roman state religion – no such position really existed, but if any could claim it, it would be the Pontifex Maximus, not the flamen Dialis.
On to the meat of your question, which is about the paradox between Roman militarism and the restrictions on the flamen Dialis. You’re absolutely right that the Romans were obsessed with warfare. At least in the republican period, the whole political and social system at Rome was geared towards war: prospective politicians had to serve in 10 campaigns before they could stand for election, and fighting in the army was one of the main responsibilities of every citizen. As I discussed in my answer to this question about Roman worship of Mars, the Roman religious calendar was set around the military campaigning season, with celebrations aimed at bestowing divine favour and purification on the army in spring and autumn, when they were either going out and coming back from war. This point strikes right at the heart of your question, the answer to which, at least in my view, concerns Roman understandings of the place of warfare, by which I mean the physical locations of war. For the Romans, there was a very clear demarcation between the territory of the city of Rome and the world outside. The sacred boundary – the pomerium – was especially important in military affairs. The military authority of a general was not valid inside the pomerium, and elections and other civic political business could not happen outside. Therefore, the pomerium marked the boundary between peace and war, between civilians and soldiers, and, because no burials could happen inside the city, between life and death. The ideal situation was that the army would go out of the city, defeat Rome’s enemies and then return in glory, putting down their swords and going back to normal, peaceful life. As I said, it’s right that the Romans were obsessed with war, but war had to be kept in its proper place. That’s why Romans in the late republic and early empire had such a hard time dealing with the civil wars – fighting just wasn’t supposed to happen within Rome, either the physical space of the city itself or, metaphorically speaking, within the citizen body.
Now, the flamen Dialis was quite clearly a civilian priesthood, with responsibilities only inside the boundary of the city. Therefore, it follows that, if a situation arose where he could see the army or participate in any kind of military activity, some serious transgression of the pomerium must have occurred: either the army had come inside the city, or the priest had gone out. Either way, that important line had been crossed, which to the Roman mind meant a terrible inversion of the natural order. It’s worth mentioning the Vestal Virgins here too, as the other major priesthood on which the safety and security of Rome was thought to rest. The Vestals were also heavily restricted in what they could do and where they could go, with the same sense that transgressing these prohibitions would compromise Rome itself.
The answer from u/alkibiades415 on this thread might be useful Who was the last flamen dialis?