Washington (CNN) -- The Afghanistan commander whose career ended after a controversial profile in Rolling Stone magazine joked about his predicament and his post-military life at his retirement ceremony Friday in Washington.
"For those here tonight that feel the need to contradict my memories with the truth, remember I was there, too. I have stories on all of you, photos on many, and I know a Rolling Stone reporter," Gen. Stanley McChrystal said, poking at the reason for his forced retirement.
McChrystal's illustrious career came to an abrupt end when he resigned as the top U.S. commander in Afghanistan after he and his staff were quoted in a Rolling Stone magazine article criticizing and mocking key administration officials.
McChrystal collected his medals and verbal commendations from the top men of the military, White House and the Afghanistan ambassador with a bittersweet smile.
"I left a mission I felt strongly about. I ended a career I love that began over 38 years ago. I left unfulfilled commitments I made to many comrades in the fight -- commitments I hold sacred," he said. "My service did not end as I would have wished."
But, McChrystal said, he and his wife, Annie, will approach the future with "hope and iPhones." He said the couple had spent some years apart but were now reconnected, aided by new technologies like Skype.
The West Point graduate and former Green Beret was a senior official for the chairman of the Joint Chiefs of Staff, Adm. Mike Mullen. Between 2003 and 2008, he was the commander of the highly clandestine Joint Special Operations Command, which oversees the military's most sensitive forces, including the Army's Delta Force.
"We say goodbye to Stan McChrystal today with pride and sadness," Secretary of Defense Robert Gates said at the ceremony. "Pride for the remarkable roster of achievement that he has compiled as a man and a soldier. Sadness that our comrade and his prodigious talents are leaving us."
Said Jawad, ambassador of Afghanistan to the United States, thanked McChrystal for what he had done for his country and said "a number of Afghans would call him a friend."
In 2009, Defense Secretary Robert Gates asked for the resignation of Gen. David D. McKiernan, the former U.S. and NATO commander in Afghanistan. McChrystal would have "fresh eyes on the problem" in Afghanistan, Gates said at the time.
President Barack Obama tapped McChrystal in June 2009 to be the top commander in Afghanistan.
McChrystal was known for his discretion and keeping the media at arms length. That perception was shattered when the infamous Rolling Stone article came out in June.
He did not directly criticize Obama in the article, but reporter Michael Hastings writes that the general and Obama "failed from the outset to connect" after the president took office.
Sources familiar with their first meeting said McChrystal thought Obama looked "uncomfortable and intimidated" by the room full of top military officials, according to the article.
The journalist wrote that an unnamed aide to McChrystal mocked Vice President Joe Biden. McChrystal did not deny the article's accuracy. In a statement, he called the comments "a mistake" and apologized for "poor judgment."
McChrystal said that the relationships developed in his career were the most important to him, which he said he would honor with two beer kegs after the ceremony at Fort McNair. He extended the the invitation to everyone present.