(ב) לֹֽא־תִהְיֶ֥ה אַחֲרֵֽי־רַבִּ֖ים לְרָעֹ֑ת וְלֹא־תַעֲנֶ֣ה עַל־רִ֗ב לִנְטֹ֛ת אַחֲרֵ֥י רַבִּ֖ים לְהַטֹּֽת׃
(2) You shall neither side with the mighty to do wrong—you shall not give perverse testimony in a dispute so as to pervert it in favor of the mighty—
(יח) שֹׁפְטִ֣ים וְשֹֽׁטְרִ֗ים תִּֽתֶּן־לְךָ֙ בְּכׇל־שְׁעָרֶ֔יךָ אֲשֶׁ֨ר יְהֹוָ֧ה אֱלֹהֶ֛יךָ נֹתֵ֥ן לְךָ֖ לִשְׁבָטֶ֑יךָ וְשָׁפְט֥וּ אֶת־הָעָ֖ם מִשְׁפַּט־צֶֽדֶק׃
(18) You shall appoint magistrates and officials for your tribes, in all the settlements that your God יהוה is giving you, and they shall govern the people with due justice.
(ג) וַ֠יָּבֹ֠אוּ כׇּל־זִקְנֵ֨י יִשְׂרָאֵ֤ל אֶל־הַמֶּ֙לֶךְ֙ חֶבְר֔וֹנָה וַיִּכְרֹ֣ת לָהֶם֩ הַמֶּ֨לֶךְ דָּוִ֥ד בְּרִ֛ית בְּחֶבְר֖וֹן לִפְנֵ֣י יְהֹוָ֑ה וַיִּמְשְׁח֧וּ אֶת־דָּוִ֛ד לְמֶ֖לֶךְ עַל־יִשְׂרָאֵֽל׃ {ס}
(3) All the elders of Israel came to the king at Hebron, and King David made a pact with them in Hebron before the LORD. And they anointed David king over Israel.
(לט) וַיִּקַּח֩ צָד֨וֹק הַכֹּהֵ֜ן אֶת־קֶ֤רֶן הַשֶּׁ֙מֶן֙ מִן־הָאֹ֔הֶל וַיִּמְשַׁ֖ח אֶת־שְׁלֹמֹ֑ה וַֽיִּתְקְעוּ֙ בַּשּׁוֹפָ֔ר וַיֹּֽאמְרוּ֙ כׇּל־הָעָ֔ם יְחִ֖י הַמֶּ֥לֶךְ שְׁלֹמֹֽה׃
(39) The priest Zadok took the horn of oil from the Tent and anointed Solomon. They sounded the horn and all the people shouted, “Long live King Solomon!”

(ד) הִלֵּל אוֹמֵר, אַל תִּפְרֹשׁ מִן הַצִּבּוּר

(4) Hillel said: do not separate yourself from the community,

אָמַר רַבִּי יִצְחָק: אֵין מַעֲמִידִין פַּרְנָס עַל הַצִּבּוּר אֶלָּא אִם כֵּן נִמְלָכִים בַּצִּבּוּר, שֶׁנֶּאֱמַר: ״רְאוּ קָרָא ה׳ בְּשֵׁם בְּצַלְאֵל״, אָמַר לוֹ הַקָּדוֹשׁ בָּרוּךְ הוּא לְמֹשֶׁה: מֹשֶׁה, הָגוּן עָלֶיךָ בְּצַלְאֵל? אָמַר לוֹ: רִבּוֹנוֹ שֶׁל עוֹלָם, אִם לְפָנֶיךָ הָגוּן — לְפָנַי לֹא כׇּל שֶׁכֵּן! אָמַר לוֹ: אַף עַל פִּי כֵן, לֵךְ אֱמוֹר לָהֶם. הָלַךְ וְאָמַר לָהֶם לְיִשְׂרָאֵל: הָגוּן עֲלֵיכֶם בְּצַלְאֵל? אָמְרוּ לוֹ: אִם לִפְנֵי הַקָּדוֹשׁ בָּרוּךְ הוּא וּלְפָנֶיךָ הוּא הָגוּן, לְפָנֵינוּ לֹא כׇּל שֶׁכֵּן!
With regard to Bezalel’s appointment, Rabbi Yitzḥak said: One may only appoint a leader over a community if he consults with the community and they agree to the appointment, as it is stated: “And Moses said unto the children of Israel: See, the Lord has called by name Bezalel, son of Uri, son of Hur, of the tribe of Judah” (Exodus 35:30). The Lord said to Moses: Moses, is Bezalel a suitable appointment in your eyes? Moses said to Him: Master of the universe, if he is a suitable appointment in Your eyes, then all the more so in my eyes. The Holy One, Blessed be He, said to him: Nevertheless, go and tell Israel and ask their opinion. Moses went and said to Israel: Is Bezalel suitable in your eyes? They said to him: If he is suitable in the eyes of the Holy One, Blessed be He, and in your eyes, all the more so he is suitable in our eyes.
אֲמַר לֵיהּ אַבָּיֵי לְרַב יוֹסֵף מִי אָמַר שְׁמוּאֵל הָכִי וְהָאָמַר שְׁמוּאֵל דִּינָא דְמַלְכוּתָא דִּינָא וּמַלְכָּא אָמַר לָא לִיקְנֵי אַרְעָא אֶלָּא בְּאִיגַּרְתָּא אֲמַר לֵיהּ אֲנָא לָא יָדַעְנָא עוֹבָדָא הֲוָה בְּדוּרָא דְרָעֲוָתָא בְּיִשְׂרָאֵל דִּזְבַן אַרְעָא מִגּוֹי וַאֲתָא יִשְׂרָאֵל אַחֲרִינָא רָפֵיק בָּהּ פּוּרְתָּא אֲתָא לְקַמֵּיהּ דְּרַב יְהוּדָה אוֹקְמַהּ בִּידָא דְּשֵׁנִי

Abaye said to Rav Yosef: Did Shmuel actually say this? But doesn’t Shmuel say that the law of the kingdom is the law, i.e., the halakha obligates Jews to observe the laws of the locale in which they reside, and the king said that land may not be acquired without a document? Therefore, taking possession should not be effective for acquisition. Rav Yosef said to him: I do not know how to reconcile this contradiction, but there was an incident in the village of Dura that was founded by shepherds, where there was a Jew who purchased land from a gentile by giving money, and in the interim another Jew came and plowed it a bit. The two Jews came before Rav Yehuda for a ruling, and he established the property in the possession of the second individual. This accords with the ruling of Shmuel that the property is ownerless until a Jew performs an act of acquisition.

דבר אחר מה דגים שבים כל הגדול מחבירו בולע את חבירו אף בני אדם אלמלא מוראה של מלכות כל הגדול מחבירו בולע את חבירו והיינו דתנן רבי חנינא סגן הכהנים אומר הוי מתפלל בשלומה של מלכות שאלמלא מוראה של מלכות איש את רעהו חיים בלעו
Alternatively, just as in the case of fish of the sea, any fish that is bigger than another swallows the other, so too in the case of people, were it not for the fear of the ruling government, anyone who is bigger than another would swallow the other. And this is as we learned in a mishna (Avot 3:2) that Rabbi Ḥanina, the deputy High Priest, says: One should pray for the continued welfare of the government, as were it not for the fear of the government, every man would swallow his neighbor alive.

(יד) וְכֵיצַד מְצֻוִּין הֵן עַל הַדִּינִין. חַיָּבִין לְהוֹשִׁיב דַּיָּנִין וְשׁוֹפְטִים בְּכָל פֶּלֶךְ וּפֶלֶךְ לָדוּן בְּשֵׁשׁ מִצְוֹת אֵלּוּ. וּלְהַזְהִיר אֶת הָעָם

(14) How must the Noachides fulfill the commandment to establish laws and courts? They are obligated to set up judges and magistrates in every major city to render judgement concerning these six mitzvot and to admonish the people regarding their observance.