Preheat the oven to 350 degrees F (175 degrees C).
Generously season tenderloin with salt and pepper. Set aside. In a small mixing bowl, whisk together mustard, brown sugar, and thyme.
Place a large sheet of aluminum foil onto a baking sheet. Place onion slices in the center of the foil, in a single layer. Place pork over onions and brush with 1/2 of mustard mixture.
Bring up foil sides. Double fold top and ends to seal packet, leaving room for heat circulation inside. Bake for 40 to 45 minutes or until the internal temperature reads 130 degrees F (55 degrees C).
Remove from the oven. Open packet carefully by cutting along top fold with a sharp knife, allowing steam to escape. When uncovered, brush with remaining mustard mixture. Leaving the packet open, broil for about 1 minute or until a nice crust forms on top. Remove from the oven and allow tenderloin to rest for 10 to 15 minutes before slicing and serving.