President Obama says farewell to Leon Panetta during the Secretary of Defense's farewell at Joint Base Myer-Henderson Hall in Arlington, Va. Watch Obama and Panetta's speeches.

Bidding an official farewell to outgoing Secretary of Defense Leon Panetta, President Barack Obama called on Congress to ensure that Panetta’s successor did not inherit massive budget cuts slated to hit the defense budget in March.

Highlighting Panetta’s accomplishments at the Pentagon, Obama praised Panetta for preparing the military for the future of warfare, including on the cyber front. He then urged Congress not to interfere with that preparation by allowing indiscriminate cuts to the Pentagon budget to go through as a result of the $1.2 trillion so-called “sequester” -- cuts that were supposed to be so odious that Washington would have to work together to find alternative spending reductions.

“Keeping us prepared will be the mission of my nominee to be the next secretary of defense, a combat veteran with the experience, judgment and vision that our troops deserve, Chuck Hagel. And since we are now just weeks away from deep automatic cuts to federal spending, including defense, let me say this: There is no reason -- no reason for that to happen,” he said to a hall full of Panetta’s colleagues, friends and family at Joint Base Myers-Henderson in Arlington, Virginia.

“So here today, for the sake of our prosperity, for the sake of all these men and women in uniform and all their brothers and sisters in uniform that they represent, now's the time to act, for Democrats and Republicans to come together in the same spirit that Leon Panetta always brought to public service, solving problems, not trying to score points,” he continued.

In his speech, Obama also thanked Panetta for his return to public service, when Obama pulled him out of retirement at his Monterey walnut farm to serve first as CIA director and then as secretary of defense.

Obama described Panetta’s reluctance to return to Washington with more than a hint of sarcasm: “Now, Leon will deny it, but I hear he was growing restless; he wanted less time on the tractor and enjoying good weather and more time in the office; less time in California, more time in Washington interacting with the West Wing and members of Congress. Who wouldn't?”

But now, Panetta said, taking the stage after the president introduced him, he was ready to return to the farm for good.

Thanking his wife of 50 years, Sylvia, for her “constant love and support,” Panetta said that “her valentine gift is both of us going home together.”