Beispiel #1
0
function getVirtualHosts(callback) {
    apacheconf(CONFIG.apache.root + CONFIG.apache.vhost_path, function(err, config, parser){
        var hosts = [];
        if (! err) {
            _.each(config.VirtualHost, function(vhost){
                hosts.push(vhost);
            });
        }
        callback(err, hosts);
    });
}
walker.on('file', function(root, stat, next) {
  var file = root + stat.name;

  apacheconf(file, function(error, conf, parser) {
    if (error) throw error;

    ports.push(parseInt(conf.Listen[0]));

    next();
  });

});