  This paper considers the Cram\'er-Lundberg model, with the additional feature
that the number of clients can fluctuate over time. Clients arrive according to
a Poisson process, where the times they spend in the system form a sequence of
independent and identically distributed non-negative random variables. While in
the system, every client generates claims and pays premiums. In order to
describe the model's rare-event behaviour, we establish a sample-path
large-deviation principle. This describes the joint rare-event behaviour of the
reserve-level process and the client-population size process. The
large-deviation principle can be used to determine the decay rate of the
time-dependent ruin probability as well as the most likely path to ruin. Our
results allow us to determine whether the chance of ruin is greater with more
or with fewer clients and, more generally, to determine to what extent a large
deviation in the reserve-level process can be attributed to an unusual outcome
of the client-population size process.
