The law given to the Levites - the family of priests for the people of Israel - included the proper form and function of worshiping God. The third book of the Bible deals primarily with these laws. Among these is included a law concerning alcohol consumption and entering into the tabernacle . It was pretty simple. Don't drink when going into the tent of meeting because it is your job to distinguish between the holy and the common and alcohol hinders your ability to do so.
"But, this is for priests, not us common folk" you say. Maybe so. Maybe not.