Write metadata for directories not on S3.