  We report the discovery of the optical afterglow (OA) of the long-duration
gamma-ray burst GRB 030429, and present a comprehensive optical/near-infrared
dataset used to probe the matter at different distance scales, i.e. in the
burst environment, in the host galaxy and in an intervening absorber. A break
in the afterglow light curve is seen approximately 1 day from the onset of the
burst. The light curve displays a significant deviation from a simple broken
power-law with a bright 1.5 magnitude bump with a duration of 2-3 days. The
optical/near-infrared spectral energy distribution is best fit with a power-law
with index beta = -0.36 +/- 0.12 reddened by an SMC-like extinction law with (a
modest) A_V = 0.34 +/- 0.04. In addition, we present deep spectroscopic
observations obtained with the Very Large Telescope. The redshift measured via
metal absorption lines in the OA is z = 2.658 +/- 0.004. Based on the damped
Ly-alpha absorption line in the OA spectrum we measure the HI column density to
be log N(HI) = 21.6 +/- 0.2. This confirms the trend that GRBs tend to be
located behind very large HI column densities. The resulting dust-to-gas ratio
is consistent with that found in the SMC, indicating a low metallicity and/or a
low dust-to-metal ratio in the burst environment. We find that a neighbouring
galaxy, at a separation of only 1.2", has z = 0.841 +/- 0.001, ruling it out as
the host of GRB 030429. The small impact parameter of this nearby galaxy, which
is responsible for MgII absorption in the OA spectrum, is in contrast to
previous identifications of most QSO absorption-selected galaxy counterparts.
Finally, we demonstrate that the OA was not affected by strong gravitational
lensing via the nearby galaxy.
