Pharmacist pleads guilty to illegal pill distribution