What is an OS?
#include <os>
#include <net/inet4>
#include <math.h>
#include <iostream>
#include <sstream>
#include <net/dhcp/dh4client.hpp>
using namespace std::chrono;
std::unique_ptr<net::Inet4<VirtioNet> > inet;
void Service::start() {
Nic<VirtioNet>& eth0 = Dev::eth<0,VirtioNet>();
inet = std::make_unique<net::Inet4<VirtioNet> >(eth0);
inet->network_config( {{ 10,0,0,42 }}, // IP
{{ 255,255,255,0 }}, // Netmask
{{ 10,0,0,1 }}, // Gateway
{{ 8,8,8,8 }} ); // DNS
var runtime = require('runtimejs')
console.log('Hello world!')
# install dependencies
npm install runtimejs
npm install runtimeify -g
npm install runtime-tools -g
# bundle up ramdisk image
runtimeify index.js -o initrd
# make sure you have QEMU installed
brew install qemu # OSX
sudo apt-get install qemu # Ubuntu
# run it in QEMU
runtime-qemu ./initr
July, 2015