The House passed a budget bill Thursday that will reverse some automatic cuts and set spending levels for the next two years in an effort to prevent another embarrassing government shutdown.

The legislation passed the House 332-94, with 62 Republicans bucking House leadership and opposing the deal. The Senate will likely pass the bill and President Obama is expected to sign it.

The bill, which raises discretionary spending and replaces $63 billion that would have been otherwise automatically cut from the budget with more targeted cuts and fees, is the most significant budget agreement since the Republicans won control of the House in 2010. Although Democrats are upset that unemployment benefits will not be extended in the deal, the agreement drafted by Rep. Paul Ryan (R-Wisconsin) and Sen. Patty Murray (D-Washington) drew bipartisan support in a fiercely divided Congress.

The bill reduces the deficit by about $23 billion over 10 years, doesn’t raise taxes, protects military spending and allows Congress to return to its usual budget appropriations process. It’s also a significant departure from the brinksmanship that has consumed Congress the last few years and prompted the government shutdown.

Some Democrats oppose the bill because it doesn’t extend unemployment insurance for the 1.3 million Americans whose benefits will expire on Dec. 28. Some conservatives oppose the higher spending numbers, but House leaders were determined to push the bill through. “You can’t spend your time making perfect the enemy of the good,” Rep. Tom Cole (R-Okla.) said Wednesday.

“This agreement will stop Washington’s lurch from crisis to crisis,” Ryan said in a statement after the bill was passed. “It will bring stability to the budget process and show both parties can work together.”

“I am disappointed that Republicans refused to allow us to extend support for workers fighting to get back on the job in this budget deal. But I am going to keep fighting for that outside this deal,” Murray said after the vote. “And I know it would have been far more devastating to working families if the certainty of Congress lurching towards either another government shutdown or continued sequestration was added to the uncertainty surrounding their unemployment insurance.”

The President called the bill’s passage a “positive step forward for the nation and our economy,” but said he would have liked the bill to extend unemployment insurance. Still, he said in a statement, “it marks an important moment of bipartisan cooperation and shows Washington can and should stop governing by crisis and both sides can work together to get things done.”