It is funny to build a capsule using advanced armor and abandon it near a star (so it can't be broken using a laser gun). When someone walks in, it triggers a logic system that closes a blast door, enables gravity and activates a pusher effect in a loop. It's really important that the star is visible through transparent blocks so the victim can watch the incoming dead.
A safest solution to ensure the victim's dead is to activate a jump drive with the logic, so it will stay in the center of a star.