Ensure parent directories are created for base boxes

Fixes #1059