update readme file
[iotcloud.git] / src / server / README.txt
1 1) Requires apache2
2 2) Requires fastcgi (libapache2-mod-fastcfi)
3
4 Setup on ubuntu
5 1) Install modules
6
7 2) Add .htaccess file in /var/www/html
8 RewriteEngine on
9 RewriteBase /
10 SetHandler cgi-script
11 RewriteRule ^([a-zA-Z0-9._]*\.iotcloud/([a-zA-Z0-9._]*))$ /cgi-bin/iotcloud.fcgi/$1
12
13 3) Create account directory.  For example, create the directory test.iotcloud in /var/www/html
14    -- To password protect, create the following .htaccess file in the account directory:
15 AuthType Basic
16 AuthName "Private"
17 AuthUserFile /var/www/html/foo.iotcloud/.htpasswd
18 Require valid-user
19
20 4) In apache2.conf, add to the /var/www directory section:
21 AllowOverride FileInfo AuthConfig
22
23 5) In the sites-enabled/000-default.conf file, add the line:
24 SetEnv IOTCLOUD_ROOT /iotcloud/
25
26 6) Create the /iotcloud directory.
27
28 7) Create the account directory in the /iotcloud directory.  For example, test.iotcloud and give it permissions that the apache daemon can write to.