BEIRUT, Lebanon — For months, the bodies have been piling up in eastern Aleppo as the buildings have come down, pulverized by Syrian and Russian jets, burying residents who could not flee in avalanches of bricks and mortar.

And now it is almost over, not because diplomats reached a deal in Geneva, but because President Bashar al-Assad of Syria and his foreign allies have won the city. Cold, hungry and scarred by the deaths of loved ones, tens of thousands of civilians and fighters are awaiting buses to take them from their homes to uncertain futures.

It is not the first victory that Mr. Assad has secured with overwhelming force in the Syrian conflict. But his subjugation of eastern Aleppo has echoed across the Middle East and beyond, rattling alliances, proving the effectiveness of violence and highlighting the reluctance of many countries, perhaps most notably the United States, to get involved.

President Obama, on Friday at his final news conference of the year, acknowledged that the nearly six-year-old war in Syria had been among the hardest issues he has faced, and that the world was “united in horror” at the butchery in Aleppo. But Mr. Obama — who came into office committed to reducing America’s military entanglements in the Middle East — also defended his decision not to intervene more forcefully.