Skip to content
This repository was archived by the owner on Aug 11, 2022. It is now read-only.
This repository was archived by the owner on Aug 11, 2022. It is now read-only.

npm unconditionally creates $prefix/etc #11486

@jbergstroem

Description

@jbergstroem

I found an issue while updating the ebuild (how gentoo packages works) for nodejs -- we had a sandbox violation -- meaning the package tried to install files or create directories that weren't expected. The sandbox violation pointed to /usr/etc which I was able to point to how config is instantiated in npm which we found since we generate the bash completion during the packaging phase.

It looks like the code in question does so intentionally, but I'd argue that this might not be the best of behaviour. In gentoo's case, this would imply npm creating /usr/etc on first run, only to look for configs.

I think the proper way forward here is to not assume that the directory have to exist.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions