Support both empty and non-empty context path (non-empty requires an additional mkdir/rmdir)