New York, New Jersey, Illinois and Florida this week instituted mandatory confinement for certain people exposed to ebola.
Is it legal for a state (or the federal) government to detain and quarantine you against your will for health reasons? Yes. Has this sort of thing been done before? Yes. Will it be effective? No. Is it just a political ploy to garner votes from a panicked public? Oh my yes.