It's the Trolley Problem. Many people finding themselves in that problem would say, "Of course I flip the switch, one person is less than five people".
But if you take a step back it's reasonable to ask, "WHY did I suddenly find myself in this Trolley Problem? Trolleys don't spring into existence fully formed like Athena springing from Zeus' forehead. They are designed and built, piece by piece. The switch was setup by the agency of someone. People were kidnapped and tied down by force. I was placed here on purpose."
So given that realization it's also reasonable when told you must choose to say, "Why? You designed this system. You tied the people down. You could have done it differently and instead deliberately did THIS. I had nothing to do with it and I refuse the premise that I must participate in your fucked up game. No matter what happens the blood is on your hands and I refuse to share in your guilt."
That's the essential argument. There's the realpolitik decision to do "less harm", but you can also reject the fucked up premise.
When my sibling first started teaching high school, decades ago, none of the public schools were hiring because of America's perpetual budget crisis in public education (tons of vacancies, but zero openings). The only option was a Yeshiva. We're not Jewish, or even religious, but the rabbis didn't care. Every other private school was Christian, and they all required every employee to sign a "loyalty oath" affirming all kinds of shit that would otherwise be illegal but somehow isn't because of their status as a "religious institute".
So this has been happening for a long time. It all worked out though and fortunately my sibling never had to subject themselves to such a place.