A potential government shutdown loomed, threatening to disrupt the holiday season for federal workers and the public.