Nope. I would have not done it. Period. End of discussion.
And we inculcate the officers and enlisted men in OUR armed forces to not do it where each one of them is instructed that they have the duty to disobey an unConstitutional order. And this is why you did not see the levels of atrocities committed by the Americans and British as you did like that committed by the average rank and file German soldier.
This is opposed to the German/Prussian military tradition where – as in the case of WW2 – the soldiers swore a blood oath to obey the Fuhrer and where average Heer troops willingly took part in war crimes throughout Europe; not just against those pesky sub-human slavs in Russia and Poland whom the Germans hoped to enslave (like actual chattel slavery) but war crimes committed against the Dutch in the Netherlands, in France, Greece, Yugoslavia and even against their Italian allies.