A two-level medium, described by the Maxwell-Bloch (MB) system, is engraved by establishing a standing cavity wave with a linearly polarized electromagnetic field that drives the medium on both ends. A light pulse, polarized along the other direction, then scatters the medium and couples to the cavity standing wave by means of the population inversion density variations. We demonstrate that control of the applied amplitudes of the grating field allows to stop the light pulse and to make it move backward (eventually to drive it freely). A simplified limit model of the MB system with variable boundary driving is obtained as a discrete nonlinear Schroedinger equation with tunable external potential. It reproduces qualitatively the dynamics of the driven light pulse.