Skip to content

Can't mount root / directory #2040

@dex4er

Description

@dex4er

I can use root directory as a subdirectory in FS tree:

var Module = {};
Module.preRun = function() {
  FS.mkdir('root');
  FS.mount(NODEFS, { root: '/' }, 'root');
  FS.chdir('root/' + process.cwd());
}

but following code breaks on creating fake /dev/* and /tmp:

var Module = {};
Module.preRun = function() {
  FS.mount(NODEFS, { root: '/' }, '/');
}

All I want is to map real filesystem but some special directories like /dev.

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