Magnetic flux tubes or flux ropes in plasmas are important in nature and the laboratory. Axial boundary conditions strongly affect flux rope behavior, but this has never been systematically investigated. We experimentally demonstrate for the first time axial boundary conditions that are continuously varied between ideal magnetohydrodynamic (MHD) line-tied (fixed) and non-line-tied (free). In contrast with the usual interpretation that mechanical plasma motion is MHD line-tied to a conducting boundary, we constrain boundary plasma motion to cause the line-tied condition.