Hello BP community!

I'm in the US Army and I live in the Barracks Right now. So my plan is to house hack a duplex while. I understand that I can live in that duplex, but can I live in the barracks and Airbnb my side of the duplex, or do I still need to live there If I use a VA or FHA Loan?