Lock layers to coordinate simultaneous pulls

Signed-off-by: Jonathan Rudenberg <jonathan@titanous.com>