After my first spontaneous pneumothorax in '07 I got bi-lat mechanical pleurodesis. I had another pneumo in '18. Full recoveries. To the suprise of my flight doc, the AF waived me to fly after each--I'd expect it's tougher to get that waived before pilot training, though.
I retired a couple years ago, and have so far failed (to the surprise of my AME) to convinced the FAA to approve a Special Issuance for any class of med certificate. The FAA Aeromedical Certification Division has been much more painful to work with than the military...and that's saying something!
FWIW, the VA rates my pneumothorax history at 0% service-connected disability.