A common misconception about the Old Testament is that it’s laws were meant for everyone. This is not so. The laws of the Old Testament were always handed down in the context of a covenant or treaty. The rules were always articulated in the context of a relationship. Outside of that covenant, that treaty, that relationship, they were null and void.
Now in some instances the relationship in view was that between God and the whole of humanity, as was the case when Noah and the other survivors with him made their covenant with God, but this was more the exception than the rule. More often the relationship in view was far more immediate, such as God’s relationship with the twelve tribes of Israel, or God’s relationship with the tribe of Levi, or God’s relationship with the priests from the tribe of Levi, or God’s relationship with the high priest. Such laws were NOT universal. Rules handed down to the high priest were applicable to no one other than the high priest.
This is why it is foolish to cherry pick laws out of the Old Testament and apply them indiscriminately. If you don’t know the context you can’t know who it was supposed to apply to.
Consider how, even in our society, there are different rules and responsibilities for emergency services than for the general public. Police officers are exempted from some rules in order to fulfill higher duties but have additional responsibilities placed on them for the same reason. When they err and have to front up to court they are not judged as anyone in the street would be but are judged by a higher standard as befitting of a professional. The situation here is not exactly equivalent but neither is it entirely different. According to the scriptures God had a special relationship with Israel and held Israel to a higher standard as a consequence. It was never intended that the laws of Moses be applied to non-Israelites, especially beyond the borders of Israel, unless it was specifically stated or merely reiterated a more general law already instituted elsewhere in more generalised situations.
We should be very wary, therefore, of formulating a universal ethic or public policy from an indiscriminately application of Old Testament law. We need to be a lot more discriminating about what’s a valid application of Old Testament law and what is not.