vigiboard / apache / dashboard @ 805cc54a
History | View | Annotate | Download (2.35 KB)
1 | 805cc54a | Thomas ANDREJAK | #Apache configuration File |
---|---|---|---|
2 | #Read README.txt |
||
3 | #1. This file should be added to your apache config folder; On Debian copy to /etc/apache2/sites-available/ |
||
4 | #Default location for tg2 project is /home/tandreja/tg2env/dashboard_v2/dashboard. That is where you should put your project. This folder should be outside of apache location. Your package should not be installed into python site-package. |
||
5 | |||
6 | #2. Alias/Allow apache to serve static content. |
||
7 | Alias /dashboard/images /home/tandreja/tg2env/dashboard_v2/dashboard/public/images |
||
8 | Alias /dashboard/css /home/tandreja/tg2env/dashboard_v2/dashboard/public/css |
||
9 | Alias /dashboard/javascript /home/tandreja/tg2env/dashboard_v2/dashboard/public/javascript |
||
10 | Alias /dashboard/images_vigilo /home/tandreja/tg2env/dashboard_v2/dashboard/public/images_vigilo |
||
11 | #Embeded mode (http://example.com/dashboard).For big websites with a lot of memory and visitors. |
||
12 | WSGIScriptAlias /dashboard /home/tandreja/tg2env/dashboard_v2/dashboard/apache/dashboard.wsgi |
||
13 | |||
14 | #3. Test if modwsgi is working. Uncomment below line, and go to http://localhost/test: |
||
15 | #WSGIScriptAlias /test /home/tandreja/tg2env/dashboard_v2/dashboard/apache/test.wsgi |
||
16 | |||
17 | #4. [Optional] Sitewide (http://example.com/) |
||
18 | #Alias /images /home/tandreja/tg2env/dashboard_v2/dashboard/public/images |
||
19 | #Alias /css /home/tandreja/tg2env/dashboard_v2/dashboard/public/css |
||
20 | #Alias /javascript /home/tandreja/tg2env/dashboard_v2/dashboard/public/javascript |
||
21 | #WSGIScriptAlias / /home/tandreja/tg2env/dashboard_v2/apache/dashboard.wsgi |
||
22 | |||
23 | #5. [Optional] Deamon mode with 10 threads and 3 processes. For small to medium website. |
||
24 | #WSGIDaemonProcess dashboard threads=10 processes=3 |
||
25 | #WSGIProcessGroup dashboard |
||
26 | #WSGIScriptAlias / /home/tandreja/tg2env/dashboard_v2/dashboard/apache/dashboard.wsgi |
||
27 | |||
28 | #6. Directory Permission. |
||
29 | <Directory /home/tandreja/tg2env/dashboard_v2/dashboard/apache> |
||
30 | Order deny,allow |
||
31 | Allow from all |
||
32 | </Directory> |
||
33 | |||
34 | <Directory /home/tandreja/tg2env/dashboard_v2/dashboard/dashboard/public> |
||
35 | Order allow,denu |
||
36 | Allow from all |
||
37 | </Directory> |
||
38 | |||
39 | |||
40 | #7. [Optional] If you want to use Virtualhost apache settings. |
||
41 | #Sample Virtual Host configuration would look like this: |
||
42 | |||
43 | #<Directory /home/tandreja/tg2env/dashboard_v2/dashboard/apache> |
||
44 | # Order allow,deny |
||
45 | # Allow from all |
||
46 | #</Directory> |
||
47 | |||
48 | #NameVirtualHost *:81 |
||
49 | #<VirtualHost *:81> |
||
50 | # WSGIScriptAlias / /home/tandreja/tg2env/dashboard_v2/dashboard/apache/dashboard.wsgi |
||
51 | #</VirtualHost> |