“A king should never fall into the power of anger. Rather, let him control his anger, for neither a person’s interests or duty thrive when one is angry… When a dispute arises, he should pay equal attention to both parties, hear the arguments of each and then decide according to what is right. He should not act out of favouritism, hatred, fear or foolishness, but should hear the arguments of both sides and then decide according to what is right… While keeping an eye on state affairs, a king should dispense happiness to all. He should prevent all from committing violence and show that it is righteousness which brings reward. As in the days of former kings, large numbers of immigrants came together to be admitted into the realm, so should you admit them. Always show favour to the poor but also protect the rich who are your subjects…Do not foster hostility towards neighbouring kings. Whoever hates, will be repaid with hatred by his enemies. Cultivate ties of friendship with your neighbours, for others honour those who are steadfast in friendship. Do not talk at great length on all sorts of subjects, but give your judgement at the appropriate time and keep it to the point…Always protect those who live justly. For the wheel of power turns in dependence on the wheel of justice…Do not appoint as headmen of villages or provinces even your own sons or brothers if they are unscrupulous, violent or base…A foolish or greedy minister is of no value to either ruler or realm. Therefore, appoint as your ministers men who are not greedy but prudent and devoted in counsel and who can guide the realm. Your eyes are not as good as those of an informer, nor is your policy. Therefore, you should employ an informer in all your affairs.”
DN 16, Mahaparanibbana Sutta.
“What have you heard, Ananda: do the Vajjis duly protect and guard the arahats, so that those who have not come to the realm yet might do so, and those who have already come might live there in peace?”
“I have heard, Lord, that they do.”
“So long, Ananda, as this is the case, the growth of the Vajjis is to be expected, not their decline”.
As you can see violence can sometimes be justified for LAY people, not for monks. Also read the lion’s roar sutta
Thank you.
Please take a look at this too: en.m.wikipedia.org/wiki/Buddhist_kingship