MARIUPOL, Ukraine — Fighting broke out Wednesday between separatist forces and Ukrainian soldiers on the outskirts of Donetsk, in eastern Ukraine, killing at least 19 people, officials from both sides said, and threatening an already fragile cease-fire.

Through the day, a seesaw battle was waged with tanks and rocket launchers for control of two small towns, Maryinka and Krasnohorivka, held by the government. Medics reported Ukrainian forces reeling in bloody and chaotic street fighting, and Ukrainian television said 25 soldiers had been wounded.

Under a peace accord known as the Minsk II agreement, for the city in Belarus where it was signed in February, heavy weapons like tanks and launchers were supposed to have been pulled back from the front. The cease-fire, one element of that deal, has proved to be shaky, with low-grade fighting flaring up sporadically in contested areas.