src: refactor bootstrap to use bootstrap object
This refactors bootstrap to use an ephemeral bootstrap object rather than deleting and
overwriting properties on process
during startup.
This was originally part of https://github.com/nodejs/node/pull/20879 but has been extracted out to make that PR smaller.
/cc @addaleax
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
commit message follows commit guidelines