The doctor and nurse treating Gomer Pyle in the sick bay (medical facility) are U.S. Navy officers.
The Marine Corps does not have medical personnel. The medical personnel; doctors, nurses, corpsmen (medics), etc, are provided by the United States Navy.