Also when Bajor was going to join the Federation it was stated that the military was going to be absorbed into Starfleet.
I'd have to see it again and hear the language to be sure, but I think they said that the Bajorian forces would have to be integrated/coordinationed in some fashion with Starfleet. Not quite the same thing as absorbed. When a new member joins NATO, one of the things they have to do is change their military command and supply structure so that there can be coordination in the event of combined NATO military actions, but their forces aren't actually absorbed.
My impression of the Earth government is that it's more an internal governance structure and doesn't have power over Starfleet military issues.
I believe the question at hand is could Starfleet put troops in the streets, without the Earth government's permission. Especially given that there would appear to have been time to do it.
It would make sense that there would have had to be some coordination with Earth military and police forces. In American today there are about 830,000 police. There's no way that a few thousand Starfleet personnel could guard the entire planet without some help from "the natives."