4 // here we load a config if we can find it
5 // there are two sides to every class, the fwd side
6 // and the web page site (command line is web for all intents)
12 $this->config_file = null;
13 if(file_exists("../var/fw.conf")) {
14 $this->config_file = realpath("../var/fw.conf");
16 if(file_exists("/var/lib/fwd/fw.conf")) {
17 $this->config_file = "/var/lib/fwd/fw.conf";
20 if($this->config_file == null) {
21 $this->config["status"] = "noconf";
22 if(is_dir("/var/lib/fwd/")) {
23 echo "no config file found. Will use ../var/fw.conf for now\n";
24 $this->config_file = "/var/lib/fwd/fw.conf";
25 } else if(is_dir("../var/")) {
26 echo "no config file found. Will use ../var/fw.conf for now\n";
27 $this->config_file = "../var/";
29 echo "No directory where i can create a config, bailing\n";
34 // config comes from shm... we'll get there