If the officer was ordered by POTUS to support DEI policies and carried out that lawful order, that should not be a fireable offense (unless they then refuse the order to return to a more traditional military.)
For example, in 1948 Truman issued an EO that integrated the military and abolished discrimination "on the basis of race, color, religion or national origin"... That order was carried out. If Eisenhower was elected 4 years later and rescinded that EO, should the generals that carried out the lawful order to integrate the military have been fired?
https://www.msn.com/en-us/news/politics/generals-senior-officers-at-dod-could-soon-be-fired-us-officials/ar-AA1zolMO?ocid=hpmsn&cvid=f06e1cc948b84a13bfa9415770829f9c&ei=421