Starting automatically DemocracyOS with upstart
In Ancient Greece many citizens had a place where they meet four times a month to engage in discussions concerning all political and public life of the City-State. They met in a particular place named The Agora.
Nowadays we don't have Agoras and even if we do we don't use them because we're too busy earning something to pay the bills or changing the world in other ways.
The folks of DemocracyOS know that and they have done something about it. They have made this platform to bring the Agora to our desks and mobile devices, so we can engage in discussions that will eventually enact laws, all from this online digital platform.
Here is the Wired article featuring it.
At StarterSquad we think the draconian dictatorship model of most corporations is not a good fit for our startup-friendly company culture, so we're running experiments on how the company makes decisions.
So we followed the install instructions here and provisioned a server using prudentia and in less than 10m we have a running DemocracyOS in production.
In this protip, I'm sharing how to make the upstart so DemocracyOS starts automatically in the server:
upstart.conf
description "DemocracyOS on StarterSquad"
author "StarterSquad team"
start on runlevel [2345]
stop on runlevel [016]
respawn
console log
setuid {{ansible_user_id}}
setgid {{ansible_user_id}}
env HOME={{install_dir_server}}
env NODE_PATH=.
exec start-stop-daemon --chdir ${HOME} --start -- pid=/var/run/{{api_upstart_name}}.pid --exec /usr/bin/node -- index.js
Written by sebastian sastre
Related protips
1 Response
Thanks for trying out our software! I hope it meets your expectations :)