Good order and discipline should require active duty officers to keep their opinions to themselves. But once they are out of uniform then the restriction is off and they should be free to express their opinion, same as every other American.
Unless they are “gay”....
Then they can march in uniform in a “pride” parade....
Not political at all, I guess.