Lightweight operating system using Node.js as userspace.
NodeOS is an operating system build entirely in Javascript and managed by npm. Any package in npm is a NodeOS package, which at last count was 106,713 packages. The goal of NodeOS is to provide just enough to let npm provide the rest. Since anyone can contribute to npm, anyone can create NodeOS packages. Roadmap
- Web: please use github issues for discussion
- IRC: join
#node-oson Freenode
NodeOS is a Node.js based operating system, built-off of the Linux kernel. The eventual goal of NodeOS is to produce images that can be run on
- real hardware like desktop PCs, servers or Raspberry Pi
- cloud providers like Joyent, Amazon or Rackspace
- virtual machines like QEmu, VirtualBox, VMWare and KVM
- PaaS providers like Heroku or Joyent's Manta
- container providers like Docker
Core development is being done in layers. There could be some differences to adjust better to each target platform, but the general structure is:
- barebones custom Linux kernel with an initramfs that boots to a Node.js REPL
- initramfs Basic NodeOS environment to mount a root filesystem partition
- rootfs NodeOS global services, C/C++ compiler and libraries
- usersfs multi-user environment with the same behaviour of traditional OSes
All the layers except kernel are bootable, leading both initramfs and rootfs to a Node.js REPL prompt by default.
If you are hacking on NodeOS as a somewhat production server, you are likely building usersfs images since each user is isolated of others, but you can be able to customize all layers. For example, you could be able to modify rootfs to craft a single-user environment or also dedicate a full NodeOS instance to a single application.
Requires genext2fs. Install with sudo apt-get install genext2fs
-
Download the project source code and build NodeOS for QEmu.
git clone [email protected]:NodeOS/NodeOS.git cd NodeOS PLATFORM=qemu_32 npm install
To build for 64 bits, use PLATFORM=qemu_64 npm install
-
Pick some microwave pop-corn and go to see a movie. No, really, do it.
-
Exec your fresh compiled NodeOS image
npm start
If you encounter an error when building NodeOS, take a look at this page
There are some NodeOS images on Docker Hub, but they can be outdated, so it's recomended to build from source code.
-
One Liner
sudo docker run -t -i nodeos/nodeos
or learn how to make a Custom Build
Warning: the build process is hairy, it probably won't work the first time. I'm working on that.
git clone [email protected]:NodeOS/Docker-NodeOS.git
cd Docker-NodeOS
./build
