Keeping them in containment while they have access to their powers could be impossible on the long term. Their ability to bend their surroundings and to manipulate the minds of their guards makes a classic prison scenario impossible.
So, instead of keeping them inside some jail, a much better approach could be to make sure that there is no place for them to escape to. Jedis, after all, are biological beings, they cannot survive in really harsh environments. Dedicating a prison planet for them, or even better, creating a jail in space, with no possible access to a space ship should keep them pinned for a long time.
Petty jedi criminals guilty of using a lightsaber for inappropriate purposes could be sentenced on prison planets, survivor style, with no guards or spaceports whatsoever. Extracting them after their sentence has expired should prove to be difficult because means of getting to the surface and then back to space have to be solved somehow (food and supplies can be dropped from orbit). Another big disadvantage of prison planets is that it is a great way for power-hungry jedis to start their carreer and start building their relationships. The planet has to be blockaded by a sizeable military force at all times, of course. You don't want someone to just go there, land, and save their evil buddies.
For dark and scary Jedis the solution could be more simple, as there are fewer of them. I, for one, would simply build a nice habitat in space, surrounded by thick automated defenses and put him inside. Organize monthly food drops in form of packages without their own propulsion systems (for example by shooting them directly into some input port of the habitat). The zone around the habitat would be restricted at all times, so that no human being is allowed to get closer than a couple of kms, or whatever the range of the bad guy's powers is. As an extra layer of defense by manned patrol ships could be organized to take care of whoever is trying to sneak past the automated defenses, but having something like this could turn to be a security problem, especially if someone wants to make a Hollywood-style movie about the escape of a dark lord.