C++, 51 bytes
#include<os>
void Service::start(){OS::shutdown();}
Only works in IncludeOS (v0.10.0-rc.1)
Test:
$ pwd
/home/simon/IncludeOS/examples/demo_service
$ cat service.cpp
#include<os>
void Service::start(){OS::shutdown();}
$ mkdir build && cd build && cmake .. && make && cd ..
[...]
$ boot build/IncludeOS_example
[...]
================================================================================
================================================================================
IncludeOS v0.10.0-rc.1-dirty
+--> Running [ IncludeOS minimal example ]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$