And here's where the trouble lies. How does a soldier determine which orders or assignments are lawful?
Ah, I see. The soldier doesn't determine which orders or assignments are lawful.
Which kind of undermines your premise of "as long as they are lawful".
Let's be plain; and just call a soldier a zombie, then?
But maybe I'm being unfair here. To be exact you've said that a soldier doesn't determine the definition of a lawful order. This would seem more reasonable. So are soldiers issued with a check list (the rules of engagement?) of what constitutes lawful action?
Are they issued with clear rules on what constitutes insane order-issuing behaviour on the part of their superior officers and exact procedures formutinyputting said officer(s) under restraint?
Yes soldiers are given a manual (at least in the US Army) clearly explaining what is and is not a lawful action or order in combat. It is called "The Law of Land Warfare". This manual draws from the Geneva Conventions and other international treaties, as well as United States federal law to explain how soldiers should conduct themselves on the battlefield and how to properly refuse unlawful orders and relieve the commanding officer who issued the order of his/her command.
But it is clearly stated when you join the Army, that only orders that fit that manual's definition of an unlawful order can be refused. If any other order is refused, at best the soldier will be given a general discharge and at worst they will serve prison time with a dishonorable discharge after completion of their prison term. I agree with such harsh punishment, because if you allow soldiers to start questioning completely lawful orders simply because it conflicts with their personal morality, then that army becomes completely ineffective on the battlefield. In combat, when a commander issues orders to his/her soldiers, they need to be obeyed immediately and with out question to ensure success. If the commander has to take time to explain themselves, that could give the enemy the precious seconds they need to react or defend themselves, thus putting the objective and soldiers' lives in even greater danger.