1 Setup on Ubuntu 14.04.6 LTS (GNU/Linux 3.13.0-165-generic x86_64):
2 ==================================================================
8 2) Requires fastcgi (libapache2-mod-fastcgi and libfcgi-dev)
14 2) Add .htaccess file in /var/www/html
18 RewriteRule ^([a-zA-Z0-9._]*\.iotcloud/([a-zA-Z0-9._]*))$ /cgi-bin/iotcloud.fcgi/$1
20 3) Create account directory. For example, create the directory test.iotcloud in /var/www/html
21 -- To password protect, create the following .htaccess file in the account directory:
24 AuthUserFile /var/www/html/foo.iotcloud/.htpasswd
27 4) In apache2.conf (/etc/apache2/apache2.conf), add to the /var/www directory section:
28 AllowOverride FileInfo AuthConfig
30 5) In the sites-enabled/000-default.conf (/etc/apache2/sites-enabled/000-default.conf) file, add the line:
31 SetEnv IOTCLOUD_ROOT /iotcloud/
33 6) Create the /iotcloud directory.
35 7) Create the account directory in the /iotcloud directory.
36 For example, test.iotcloud and give it permissions that the apache daemon can write to.
38 8) Compile cloud server by typing make
40 9) Copy it to the cgi-bin directory.
42 10) Make sure that the 'rewrite' module is loaded. Run on the command prompt:
45 11) Make sure that the 'cgid' module is loaded. Run on the command prompt:
48 12) Restart the apache server. Run on the command prompt:
49 sudo service apache2 restart
56 Apache2 Debugging Commands
57 --------------------------
58 Please check the following log files for any errors after installation.
60 sudo cat /var/log/apache2/access.log
61 sudo cat /var/log/apache2/error.log
64 Curl command for testing salt creation
65 --------------------------------------
66 1) Once the server is set up, run:
67 curl -X POST http://dc-6.calit2.uci.edu/test.iotcloud/?req=getsalt
69 2) If there is any error, error messages will be printed.
70 Then we need to double check the steps as listed above.
72 3) If everything is good, then there is no error message to be printed.
73 At this point the folder /iotcloud/test.iotcloud/ should contain the
74 "queuestatus" and a number of "SLOTx" blocks.