Now this is what you are to do: A third of you priests and Levites who are going on duty on the Sabbath are to keep watch at the doors
a third of you at the royal palace and a third at the Foundation Gate, and all the other men are to be in the courtyards of the temple of the LORD.
No one is to enter the temple of the LORD except the priests and Levites on duty; they may enter because they are consecrated, but all the other men are to guard1 what the LORD has assigned to them.
References for 2 Chronicles 23:6
The Levites are to station themselves around the king, each man with his weapons in his hand. Anyone who enters the temple must be put to death. Stay close to the king wherever he goes."
The Levites and all the men of Judah did just as Jehoiada the priest ordered.2 Each one took his men--those who were going on duty on the Sabbath and those who were going off duty--for Jehoiada the priest had not released any of the divisions.3
References for 2 Chronicles 23:8
Then he gave the commanders of units of a hundred the spears and the large and small shields that had belonged to King David and that were in the temple of God.
He stationed all the men, each with his weapon in his hand, around the king--near the altar and the temple, from the south side to the north side of the temple.