Melt the butter and olive oil over medium heat, add the onions and salt, stir, cover, and cook 5 minutes.
Uncover, reduce to medium-low, and stir for about 40 minutes until the onions are glossy and dark brown, scraping the pot with 2 tablespoons of water as needed.
Stir in the garlic for 30 seconds, then the flour for 2 minutes, add the vinegar, then the warm broth, thyme, bay leaves, and pepper.
Simmer partly covered over medium-low heat for 20 minutes, remove the thyme stems and bay leaves, and salt to taste.
Brush the baguette rounds with olive oil and bake at 400°F for 8 minutes, flipping once, until crisp.
Switch the oven to broil, set oven-safe bowls on a rimmed baking sheet, fill with soup, and top each with 2 toasts and shredded Gruyère.
Broil 3 to 5 minutes until the cheese is bubbling and flecked with brown, then rest 3 minutes before serving.