Magrathea locking for cloud jobs