No, the President is the one who must sign bills into law (except in the case of a veto overide, which takes more votes than they have). It's the President whose lawful orders the military must obey.
If he's not the President, but just a usurper resident of the White House, then the laws are void, unless passed again when we get a real President, and the military, rather than obeying his orders, are bound to "convince" him to leave that residence, unless he leaves on his own.
the military oath is to the USA Constitution....not to the POTUS
do solemnly swear (or affirm) that I will support and defend the Constitution of the United States against all enemies, foreign and domestic; that I will bear true faith and allegiance to the same; and that I will obey the orders of the President of the United States and the orders of the officers appointed over me, according to regulations and the Uniform Code of Military Justice.
....against all enemies, foreign &domestic.....hmmmm