  We consider a partially overdetermined problem in a sector-like domain
$\Omega$ in a cone $\Sigma$ in $\mathbb{R}^N$, $N\geq 2$, and prove a rigidity
result of Serrin type by showing that the existence of a solution implies that
$\Omega$ is a spherical sector, under a convexity assumption on the cone. We
also consider the related question of characterizing constant mean curvature
compact surfaces $\Gamma$ with boundary which satisfy a "gluing" condition with
respect to the cone $\Sigma$. We prove that if either the cone is convex or the
surface is a radial graph then $\Gamma$ must be a spherical cap. Finally we
show that, under the condition that the relative boundary of the domain or the
surface intersects orthogonally the cone, no other assumptions are needed.
