Heat the oil in a sauce pan set over medium. Add the onion and cook, stirring frequently, until softened, about 7 minutes. Add the garlic and cook, stirring constantly, until fragrant, 30 seconds. Add the ketchup and stir to incorporate. Add the molasses, brown sugar, vinegar, and chipotle chile. Bring the mixture to a boil, then reduce the heat to low and simmer, stirring frequently, until it has thickened slightly, 10 to 15 minutes.