A rear admiral stepped down Monday as president of the U.S. Naval War College amid an ethics probe and complaints he kept a margarita machine in his office.

Rear Adm. Jeffrey Harley announced the move after the Navy announced he was being reassigned pending the outcome of an inspector general investigation.

Harley said in an all-campus email that he had decided to step down immediately because of the distractions caused by what he called an "unfounded" article by The Associated Press on Friday.

NAVY PROBES CLAIMS WAR COLLEGE LEADER KEPT MARGARITA MACHINE IN OFFICE, INVITED STUDENTS FOR GAMES OF TWISTER IN HIS OFFICE

Staffers had complained of Harley’s use of a margarita machine, which he declined to address when queried by AP.

“He has invited members of the staff to his office for afternoon drinks, setting his employees up to either comply because he’s the boss or uncomfortably decline his offer because they do not want to drink during the workday,” the staffers said in their complaint, the AP reported last week.

Staffers also complained about eyebrow-raising emails from Harley to students, faculty and staff offering “free hugs” and games of Twister in his office.

NAVY STARTS BUILDING NEW MASSIVE, 50-TON UNDERSEA ATTACK DRONE

The War College, which educates the Navy’s future leaders at its campus in Newport, R.I., announced Harley’s reassignment Monday.

“Lewis M. Duncan, Provost of the Naval War College, has temporarily assumed the duties of the President of the Naval War College,” the college said.

The Associated Press contributed to this report.