The strike that brought South Africa’s gold mining industry to its knees when 80,000 workers walked off the job last week has ended with mine workers accepting an 8% pay increase. The stoppage at 16 of 23 mines at sub-Saharan Africa’s No. 1 gold mining nation cost its industry $35 million per day, according to government figures.

“The majority have accepted the offer,” said Frans Baleni, general secretary of the National Union of Mineworkers (NUM), which ordered last Tuesday’s peaceful strike and represents 64% of the country’s 120,000 gold miners, according to South African media reports.

Initially NUM officials rejected the 6.5% increase forwarded by the Chamber of Mines, which represents top gold miners such as Harmony Gold, Sibanye Gold, AngloGold Ashanti and Gold Fields. The final agreement, said NUM reps, included inflation-linked increases from Q3 2014 and a 30% housing allowance increase.

Elize Strydom, the chamber’s chief negotiator said the agreement “helped us prevent a longer period of damaging industrial action” and was a “reasonably balanced outcome in affordability and jobs preservation.”

Harmony Gold Chief Executive Graham Briggs said the workers’ and industry’s “long-term industrial relations stability” was a priority, according to Agence France-Presse, adding that “continued industrial action will make this increase unaffordable, and place the future viability of some of our operations under threat; this, in turn, could have an impact on jobs.”

These legal strikes contrasted with the illegal stoppages that brought turmoil to Africa’s biggest economy—and the top platinum producer—in 2012.