Roasted Apples and Onions with Thyme and Bacon