Spell Ruling: Tiny Hut
"Creatures and objects within the dome when you cast this spell can move through it freely."There is no limitation on this, if they are within the hut when the spell is cast they don't need any permission to leave the hut. The spell does not trap them inside.
"The spell ends if you leave its area... Spells and other magical effects can’t extend through the dome or be cast through it. "Any spell can be cast by anyone within the dome to affect anyone within the dome only. However, no spell can be cast from within that can affect anyone outside.
There is no way the caster of Tiny Hut can maintain the dome and cast a spell to affect others outside. If the caster is within the dome, spells can't extend though, if the caster is outside the dome, the dome ends. He can't be 1/2 in and 1/2 out.