Sifrei Mitzvot sur Les Nombres 18:5

וּשְׁמַרְתֶּ֗ם אֵ֚ת מִשְׁמֶ֣רֶת הַקֹּ֔דֶשׁ וְאֵ֖ת מִשְׁמֶ֣רֶת הַמִּזְבֵּ֑חַ וְלֹֽא־יִהְיֶ֥ה ע֛וֹד קֶ֖צֶף עַל־בְּנֵ֥י יִשְׂרָאֵֽל׃

Vous garderez ainsi l’observance du sanctuaire et celle de l’autel, et les enfants d’Israël ne seront plus exposés à ma colère.

Sefer HaMitzvot

That He prohibited us from being lethargic in guarding the Temple and constantly walking around it the whole night. And that is His, may He be exalted, saying, "And you shall keep the charge of the sanctuary" (Deuteronomy 18:5). And it has already been explained in Commandment 22 of the Positive Commandments that guarding the Temple and walking around it is a positive commandment; and we are now likewise explaining that its negation is a negative commandment. And the language of the Mekhilta is, "'And they shall keep the charge of the Tent of Meeting' (Deuteronomy 18:4) - I only have a positive commandment. From where [do we know] that it is [also] a negative commandment? [Hence] we learn to say, 'And you shall keep the charge of the sanctuary.'" And the regulations of this law have already been explained at the beginning of Tamid and Middot. (See Parashat Korach; Mishneh Torah, The Chosen Temple 8.)