Cook pasta according to package directions, al dente. Drain when ready and set aside.
Meanwhile, heat up the olive oil in a large skillet. Add the onion, and saute for 3 minutes until the onions have softened and are translucent. Add the garlic and cook for an additional minute until fragrant.
Add the ham to the pan and saute it for about a minute. Add the crushed tomatoes, Italian seasoning, and pesto sauce, mix and bring to a simmer. Reduce the heat to medium-low and simmer the sauce for 10 minutes.
Once the sauce is ready, add the pasta and ricotta cheese, and combine the ingredients. Turn off the heat and transfer the hot pasta mixture into a 9 x 13-inch baking dish.
Distribute the mozzarella cheese over the top and then sprinkle it with parmesan cheese on top.
Position the oven rack in the top ⅓ of the oven, place the baking dish inside, and BROIL on HIGH for 2 minutes until the top cheese layer is melted and golden.
Remove from the oven and serve immediately.
Notes
You can also use boneless, skinless chicken thighs for this recipe.