Browse Source

[mod] config file replaced

asciimoo 11 years ago
parent
commit
8fe660b1df
3 changed files with 1 additions and 17 deletions
  1. 1
    2
      README.md
  2. 0
    7
      searx.conf_sample
  3. 0
    8
      searx/webapp.py

+ 1
- 2
README.md View File

16
 
16
 
17
 * install dependencies: `pip install -r requirements.txt`
17
 * install dependencies: `pip install -r requirements.txt`
18
 * clone source: `git clone git@github.com:asciimoo/searx.git && cd searx`
18
 * clone source: `git clone git@github.com:asciimoo/searx.git && cd searx`
19
-* create a config file: `cp searx.conf_sample search.conf`
20
-* edit your config (set your `secret_key`!)
19
+* edit your [searx/settings.py](https://github.com/asciimoo/searx/blob/master/searx/settings.py) (set your `secret_key`!)
21
 * run `python searx/webapp.py` to start the application
20
 * run `python searx/webapp.py` to start the application
22
 
21
 
23
 ### TODO
22
 ### TODO

+ 0
- 7
searx.conf_sample View File

1
-[app]
2
-secret_key          = "yourultrasecretkey" # change this!
3
-
4
-[server]
5
-port                = 8888
6
-debug               = False
7
-

+ 0
- 8
searx/webapp.py View File

23
     path.append(realpath(dirname(realpath(__file__))+'/../'))
23
     path.append(realpath(dirname(realpath(__file__))+'/../'))
24
 
24
 
25
 from flask import Flask, request, flash, render_template, url_for, Response, make_response
25
 from flask import Flask, request, flash, render_template, url_for, Response, make_response
26
-import ConfigParser
27
-from os import getenv
28
 from searx.engines import search, categories
26
 from searx.engines import search, categories
29
 from searx import settings
27
 from searx import settings
30
 import json
28
 import json
31
 
29
 
32
-cfg = ConfigParser.SafeConfigParser()
33
-cfg.read('/etc/searx.conf')
34
-cfg.read(getenv('HOME')+'/.searxrc')
35
-cfg.read(getenv('HOME')+'/.config/searx/searx.conf')
36
-cfg.read('searx.conf')
37
-
38
 
30
 
39
 app = Flask(__name__)
31
 app = Flask(__name__)
40
 app.secret_key = settings.secret_key
32
 app.secret_key = settings.secret_key