Refactor initd for supervisord