The public health community learned a hard lesson from this mentality with the HPV vaccine. Many young girls did not get the vaccine because they (or their parents) insisted they were not and would not be sexually active. The CDC recommendations for who should get the vaccine (which controls whether insurance covers it and whether military members are eligible to receive it) expanded from young girls to all people under 27, then to all people under 45.
Regarding HIV, why not get vaccinated if you have easy access to it? What is the harm in being immune to HIV?
OP asks about what's required, not what makes sense. Everyone needs to be required to get vaccines like measles and Covid because the vaccine doesn't work on everyone so we need herd immunity to ensure safety. HIV does not require herd immunity in the same way as there is no way to get it if you are in a monogamous relationship/not sexually active and don't share needles. Therefore the vaccine isn't required to ensure the safety of everyone that desires it.
> ...there is no way to get it if you are in a monogamous relationship...
People are frequently unfaithful without their partner's knowledge. Healthcare workers/Dentists are at an elevated risk of infection, and by association so are their partners. As are law enforcement, and their partners. If you routinely interact with the homeless professionally or as a volunteer, you're at an elevated risk.
This is the same mentality that was so tragically wrong and disproven by the data numerous times, no? Girls grow up and eventually have sex, right? Sex is a very human thing, and proclamations about monogamy or abstinence tend to be more religious/cultural signaling than reflections of people's actual behavior or the real need for people to get vaccinated.