  We study the orbital evolution and mass growth of protoplanets with masses $M
\in [0.1-8]$~M$_\oplus$ in the vicinity of a dusty ring, using
three-dimensional numerical simulations with a two-fluid model and
nested-meshes. We find two stable, eccentric orbits that lock the planet in the
ring vicinity, thereby inhibiting its migration and allowing it to accrete dust
from the ring. One of these orbits has an eccentricity comparable to the aspect
ratio of the gaseous disc and has its periastron within the ring, enabling
intermittent accretion during each pass. The other orbit has a smaller
eccentricity and an apoastron slightly inside the ring. A planet locked at the
outer orbit efficiently accretes from the ring and can reach the critical mass
for runaway gas accretion on timescales $\gtrsim 10^5$ yr (for a 10~M$_\oplus$
dust ring at 10~au) while a planet locked at the inner orbit has a slower
growth and might not supersede the super-Earth stage over the disc lifetime.
While in our runs a low-mass embryo forming within the ring eventually joins
the outer orbit, it is likely that the path taken depends on the specific
details of the ring. The trapping on the outer orbit arises from an
intermittent, strong thermal force at each passage through the ring, where the
accretion rate spikes. It is insensitive to uncertainties that plague models
considering planets trapped on circular orbits in rings. It is highly robust
and could allow a growing planet to follow an expanding ring over large
distances.
