Combine the brown sugar, chili powder, garlic powder, dry mustard, ketchup, onions, and vinegar in a baking dish and mix well; add in the chicken and coat it with the mixture. Cover tightly with foil. Cook for 25 minutes to an internal temperature of 160 degrees using a thermometer. Remove the baking dish from the oven and set aside for 5 minutes.