greyhound.php
changeset 46 1e58e36b04cd
parent 45 7978f037eab3
child 48 d643bfb862d8
equal deleted inserted replaced
45:7978f037eab3 46:1e58e36b04cd
    26   pcntl_signal(SIGTERM, 'sigterm');
    26   pcntl_signal(SIGTERM, 'sigterm');
    27   pcntl_signal(SIGINT,  'sigterm');
    27   pcntl_signal(SIGINT,  'sigterm');
    28   pcntl_signal(SIGUSR1, 'handle_refresh_signal');
    28   pcntl_signal(SIGUSR1, 'handle_refresh_signal');
    29 }
    29 }
    30 
    30 
    31 //
       
    32 // CONFIGURATION
       
    33 //
       
    34 
       
    35 // Listen on all interfaces. If this is false, it will only listen on
       
    36 // 127.0.0.1 (the loopback interface)
       
    37 $public = true;
       
    38 // Allow control of playback. By default this is turned on but if you
       
    39 // set this to false, it will only display the playlist.
       
    40 $allowcontrol = true;
       
    41 // The default theme. This should be a name of a directory in ./themes.
       
    42 $theme = 'grey';
       
    43 // Allow forking when an HTTP request is received. This has advantages
       
    44 // and disadvantages. If this experimental option is enabled, it will
       
    45 // result in faster responses and load times but more memory usage.
       
    46 $allow_fork = true;
       
    47 // set to true to enable authentication
       
    48 // this uses cookies, so make sure they're enabled in your browser
       
    49 $use_auth = false;
       
    50 // valid users and passwords
       
    51 $auth_data = array(
       
    52     'funky' => 'monkey',
       
    53     'fast' => 'forward'
       
    54   );
       
    55 
       
    56 @ini_set('display_errors', 'on');
    31 @ini_set('display_errors', 'on');
    57 
    32 
    58 // include files
    33 // include files
    59 require('functions.php');
    34 require('functions.php');
    60 
    35 
    61 // get the root
    36 // get the root
    62 define('GREY_ROOT', dirname(__FILE__));
    37 define('GREY_ROOT', dirname(__FILE__));
       
    38 
       
    39 // ignore this, it allows using a different config file when a Mercurial repository
       
    40 // exists in Greyhound's root directory (to allow the devs to have their own config
       
    41 // separate from the default)
       
    42 
       
    43 if ( @is_dir(GREY_ROOT . '/.hg') )
       
    44   require(GREY_ROOT . '/config.dev.php');
       
    45 else
       
    46   require(GREY_ROOT . '/config.php');
    63 
    47 
    64 // create directories
    48 // create directories
    65 @mkdir('./compiled');
    49 @mkdir('./compiled');
    66 
    50 
    67 // what kind of terminal do we have?
    51 // what kind of terminal do we have?