Israel's ruling Labor party today selected Defense Minister Shimon Peres by an overwhelming majority to replace Yitzhak Rabin as its candidate for prime minister in next month's general election.

The result was a foregone conclusion after Foreign Minister Yigal Allon's decision yesterday not to challenge Peres for the job.

Prime Minister Rabin resigned last Thursday following the attorney general's decision to prosecute Rabin's wife for an illegal joint bank account that the couple held in a Washington bank.

As head of a caretaker government, Rabin cannot legally resign his post until a new government is formed. But it is expected that, at a Cabinet meeting Tuesday, he will be granted an extended leave of absence. A replacement, probably Peres, will be named to take over the duties of prime minister.

Under a deal worked out between Allon and Peres early today, Allon will be the No. 2 candidate on the party's list. If Labor wins, Allon can have any Cabinet post he wishes. Allon said today that he would chose to be minister of defense. Former Foreign Minister Abba Eban will probably be named foreign minister again if Labor wins the election.

The next hurdle that Labor must face is to persuade the Mapam Party, which for the last 10 years has run its candidates on the same list with Labor, to join the Labor alignment. The dovish and left of center Mapam said earlier that if Peres was chosen as Labor's candidate for prime minister it would quit the alignment.

Today Peres, Allon and Eban met with Mapam's leaders in an effort to persuade them that the new labor team was not hawkish and that their wishes would be considered in a new Labor government.

Peres told reporters that despite the change in leadership "there won't be any substantial change in the policy of Israel. We shall continue to strive for meaningful negotiations with our Arab neighbors in order to achieve a real and complete peace in the Middle East."

Mapam accounts for only six out of 120 seats in the Knessett, Israel's Parliament, but Mapam has considerable influence over Israel's dovish left and in a close election even six seats might be cracial. Peres tried to convince Mapam that he was against the unauthorized Jewish settlements in the West Bank, which Mapam thinks are an obstacle to peace.

Peres expressed his willingness to make concessions on allfronts for a real peace, including the West Bank, and in a speech before the party's Central Committee he said that as far as negotiations were concerned, Israel had two aspirations:

"That negotiations will not fail and that we will not fail with negotiations - meaning that in the name of peace we will not create a situation that will lead to another war." Above all, he said, Israel should not encourage the Arabs to attack by letting them think Israel was disunited.

At the Central Committee meeting, Rabin sat in a front row seat as Peres hailed his service to the country.

"Twice we competed and twice you won," said peres, turning to Rabin. "And even though I wanted to succeed, I didn't want events to turn out this way." Meanwhile, Rabin's wife Leah, whose illegal Bank account in Washington caused all the trouble in the first place, told a reporter today that in the last four years since returning from Washington she had gone back to the United States 15 times on various missions.

She said she used the Washington bank account for this as well as for gifts buying for her friends in the United States with whom she stayed, and for her children.

"When you are abroad the money just flows," she told an interviewer.