nanobox-io/nanobox-engine-php

Do not create ".composer" at app root

mbrodala opened this issue · 5 comments

Whenever I run nanobox dev run, I end up with a .composer directory within my app root. This should not happen of course and the process should use ~/.composer instead.

It seems like this was added with this commit but I cannot see a clear requirement for this location.

@notxarb This is something I've put some thought into as well. @mbrodala just for a bit of background on this, those empty directories are the lib_dirs. Nanobox transparently mounts directories from inside of nanobox for lib_dirs. Unfortunately, in order to mount, the directory needs to exist.

@notxarb I've been thinking about an alternative because I agree with @mbrodala that this feels weird. I wonder if instead we could put lib_dirs in /data/var/lib_dirs for linking things that would normally go in $HOME.

Another option is to split up the lib_dirs into categories depending on if they need to be mounted relative to the app or runtime. We discussed making the user's home directory a symlink to a folder in the build. Or just create the user with the home directory in the build, something like /data/var/home/gonano.

The home folder has been moved to a location that gets bundled up in the build process. This issue is now resolved.

Thanks a lot. :-)