Show More
@@ -2,7 +2,6 b'' | |||||
2 | import os |
|
2 | import os | |
3 |
|
3 | |||
4 | DEBUG = True |
|
4 | DEBUG = True | |
5 | TEMPLATE_DEBUG = DEBUG |
|
|||
6 |
|
5 | |||
7 | ADMINS = ( |
|
6 | ADMINS = ( | |
8 | # ('Your Name', 'your_email@example.com'), |
|
7 | # ('Your Name', 'your_email@example.com'), | |
@@ -67,16 +66,7 b" STATIC_ROOT = ''" | |||||
67 | # Example: "http://media.lawrence.com/static/" |
|
66 | # Example: "http://media.lawrence.com/static/" | |
68 | STATIC_URL = '/static/' |
|
67 | STATIC_URL = '/static/' | |
69 |
|
68 | |||
70 | # Additional locations of static files |
|
69 | STATICFILES_DIRS = [] | |
71 | # It is really a hack, put real paths, not related |
|
|||
72 | STATICFILES_DIRS = ( |
|
|||
73 | os.path.dirname(__file__) + '/boards/static', |
|
|||
74 |
|
||||
75 | # '/d/work/python/django/neboard/neboard/boards/static', |
|
|||
76 | # Put strings here, like "/home/html/static" or "C:/www/django/static". |
|
|||
77 | # Always use forward slashes, even on Windows. |
|
|||
78 | # Don't forget to use absolute paths, not relative paths. |
|
|||
79 | ) |
|
|||
80 |
|
70 | |||
81 | # List of finder classes that know how to find static files in |
|
71 | # List of finder classes that know how to find static files in | |
82 | # various locations. |
|
72 | # various locations. | |
@@ -227,6 +217,7 b' MIDDLEWARE_CLASSES += [' | |||||
227 | 'debug_toolbar.middleware.DebugToolbarMiddleware', |
|
217 | 'debug_toolbar.middleware.DebugToolbarMiddleware', | |
228 | ] |
|
218 | ] | |
229 |
|
219 | |||
|
220 | ||||
230 | def custom_show_toolbar(request): |
|
221 | def custom_show_toolbar(request): | |
231 | return request.user.has_perm('admin.debug') |
|
222 | return request.user.has_perm('admin.debug') | |
232 |
|
223 |
@@ -10,20 +10,33 b' Site: http://neboard.me/' | |||||
10 | # INSTALLATION # |
|
10 | # INSTALLATION # | |
11 |
|
11 | |||
12 | 1. Install all dependencies over pip or system-wide |
|
12 | 1. Install all dependencies over pip or system-wide | |
|
13 | ||||
|
14 | You can use virtualenv to speed up the process. | |||
|
15 | ||||
|
16 | Use pip3 install -r requirements.txt | |||
|
17 | ||||
|
18 | Dependencies for the database and search engine need to be installed manually | |||
|
19 | when you choose which one to use. | |||
|
20 | ||||
13 | 2. Setup a database in `neboard/settings.py` |
|
21 | 2. Setup a database in `neboard/settings.py` | |
14 | 3. Run `./manage.py migrate` to apply all south migrations |
|
22 | 3. Setup SECRET_KEY to a secret value in `neboard/settings.py` | |
15 | 4. Apply config changes to `boards/config/config.ini`. You can see the default settings in `boards/config/default_config.ini` |
|
23 | 4. Run `./manage.py migrate` to apply all migrations | |
|
24 | 5. Apply config changes to `boards/config/config.ini`. You can see the default settings in `boards/config/default_config.ini` | |||
|
25 | 6. If you want to use decetral engine, run `./manage.py generate_keypair` to generate keys | |||
16 |
|
26 | |||
17 | # RUNNING # |
|
27 | # RUNNING # | |
18 |
|
28 | |||
19 | You can run the server using django default embedded webserver by running |
|
29 | You can run the server using django default embedded webserver by running: | |
20 |
|
30 | |||
21 | ./manage.py runserver <address>:<port> |
|
31 | ./manage.py runserver <address>:<port> | |
22 |
|
32 | |||
23 | See django-admin command help for details |
|
33 | See django-admin command help for details. | |
24 |
|
34 | |||
25 | Also consider using wsgi or fcgi interfaces on production servers. |
|
35 | Also consider using wsgi or fcgi interfaces on production servers. | |
26 |
|
36 | |||
|
37 | When running for the first time, you need to setup at least one section tag. | |||
|
38 | Go to the admin page and manually create one tag with "required" property set. | |||
|
39 | ||||
27 | # UPGRADE # |
|
40 | # UPGRADE # | |
28 |
|
41 | |||
29 | 1. Backup your project data. |
|
42 | 1. Backup your project data. |
General Comments 0
You need to be logged in to leave comments.
Login now