Prepare gluten-free pasta per package instructions, drain and set aside.
Add olive oil to large stock pot and bring to medium heat.
Add shallots and garlic and cook until fragrant, about 2 minutes.
Add carrots, tomatoes, salt, pepper and fresh thyme, and cook, stirring frequently, until carrots are soft, about 5 minutes.
Stir in tomato sauce, then white wine and cook until the wine evaporates, about 3 minutes.
Add cubed ham, cannellini beans and spinach and stir to combine.
Pour enough water into the pot to just cover the ingredients. Stir.
Bring to a boil, then reduce heat and allow to simmer for about 15 minutes. You may need to add more water if too much evaporates.
Taste and season with more salt and pepper if desired.
Spoon the soup into bowls, top with gluten-free pasta, and serve.