Second, people joining the military are of that age range where they are looking for a partner (if they aren't married already). Many don't marry, but there are those that do. If you deny that to them, they will quit or will marry in secret. Period. The Marines found that out a few years ago when they decreed that no one below a certain rank would be allowed to marry.
Third, the general "goings-on" around military bases assumes that military families live on base. Most families do not. I never have. Those places are for the single guys and for the people looking to take their money.
Fourth, people work long hours in many jobs outside of the military. Does that mean they shouldn't marry? There are also dangerous jobs outside of the military, such as police and firefighting, not to mention construction, running liquor stores and convenience marts in certain areas, etc. Should those people also avoid marriage., just because their wives may become widows?
Futhermore, the pay is not the same as it was in the 80s. Being married and raising a family is a viable option. But as in other careers, you cannot outbreed your paycheck. You cannot raise a family of six on an E-4's salary any more than you could on a McDonald's salary.
Deny a soldier his rights, and he won't care if you have any. Deny a man to marry because of his occupation, and he'll either defy you and marry anyway or find a different occupation.