The Sephardi ultra-Orthodox Shas, the third-biggest party, with 17 seats, came on board after weeks of on-again, off-again bargaining. Two smaller religious parties, United Torah Judaism and the National Religious Party, have also joined, although all three of them campaigned for Mr Netanyahu in the election.
Some egos remain to be massaged but Mr Barak may command a majority as big as 77 out of 120 seats. In the best circumstances he will be supported by eight parties, five from the secular left and centre. On the diplomatic front he will enjoy the support of 10 Arab party MPs.
Despite differences between them, the former army chief of staff will have a solid base for completing the peace process with the Palestinians and the Syrians, enabling him to fulfil his pledge to get Israeli troops out of Lebanon within a year.
The religious parties have had to swallow the kind of compromises - on settlements, military service for yeshiva seminarists and the distribution of major portfolios - that they would never have accepted during Mr Netanyahu's rule.
They no longer have the power to bring down the government if it adopts policies they do not like. Shas was Mr Barak's most contentious candidate, but its spiritual leader, Rabbi Ovadia Yosef, was desperate to take the party into the coalition.
He admitted in a broadcast sermon that Shas's educational network, the basis of its appeal to its constituency, was deep in debt. The only way to avert bankruptcy was to be in government, with access to state funds. Rabbi Yosef bowed to a left-wing ultimatum and jettisoned the party's charismatic political leader, Aryeh Deri, who was sentenced to four years in prison for bribe-taking and fraud.
Shas also relinquished the key Interior Ministry, which it had controlled for most of the past two decades. This portfolio, which includes immigration, personal status and local government, has been allocated to Natan Sharansky, leader of the Russian immigrants' Yisrael B'aliyah party and a graduate of the Siberian gulag.
Mr Barak's main partner from the centre-left will be Meretz, which won 10 seats (including the first Arab female MP). Its leader, Yossi Sarid, will serve as Education Minister, another crucial post which has been wrested from the religious parties.
The Centre Party, whose candidate for prime minister withdrew on the eve of poll, was still arguing over cabinet posts last night.
It won only five seats, which entitled it to no more than one minister and one deputy minister. But there is no doubt that it will join the team.
After that, Mr Barak's most delicate task will be to find places for his own ambitious Labour colleagues. As many as 11 are vying for six places in a cabinet that is limited by law to 18 ministries.
A Likud defector, David Levy, is tipped to return to his old job at the Foreign Ministry. Mr Barak has indicated that he will double as Defence Minister. Shimon Peres, the Nobel Prize-winning former prime minister, is expected to head a new ministry of regional economic cooperation. The rest is wide open.Reuse content