Actually, that's a little misleading. Overall, the bulk of the military, active duty and retired, are conservative. At the upper ranks, however, more of the senior officers tend to support the Dems because the upper echelon of the military is more political than anything else. And, it's pretty much always been that way.
Historically, DOD members (Military and civilian) and defense contractors tend to be mostly conservative, but the political appointees and top generals promoted by this administration are trying their very best to change that.