X-Git-Url: http://git.bytex64.net/?a=blobdiff_plain;f=www%2Fdoc%2Findex.html;h=61b8035a528b88d999ded944cc536072456988da;hb=fa435b6b28d6e700b517f59940e5781451132b9e;hp=e98ef47f0e0804b0dbca756781828d5bc61731f4;hpb=9cdf4e17bc5abb6eef351c6b7298f91a181164f0;p=blerg.git diff --git a/www/doc/index.html b/www/doc/index.html index e98ef47..61b8035 100644 --- a/www/doc/index.html +++ b/www/doc/index.html @@ -3,6 +3,7 @@
www/js/blerg.js
and
change baseURL at the top as well as a number of other self-references
-in that file and www/index.html
. The CGI version should
-work fine this way, but the HTTP version will require the request to be
-rewritten, as it expects to be serving from the root.
+in that file and www/index.html
.
You cannot serve the database and client from different domains (i.e., yoursite.com vs othersite.net, or even foo.yoursite.com and bar.yoursite.com). This is a requirement of the web browser — the same origin policy will not allow an AJAX request to travel across -domains. - -
Right now, blerg.httpd
doesn't serve any static assets,
-so you're going to have to put it behind a real webserver like apache,
-lighttpd, nginx, or similar. Set the document root to the www
-directory, then proxy /info, /create, /login, /logout, /get, /tag, and
-/put to blerg.httpd. You can change the port blerg.httpd
-listens on in config.h
.
-
-
Copy the files in www/ to the root of your web server. Copy
blerg.cgi
to your web server. Included in www-configs/ is
@@ -150,10 +148,47 @@ a .htaccess file for Apache that will rewrite the URLs. If you need to
call the CGI something other than blerg.cgi
, the .htaccess
file will need to be modified.
+
Nginx can't run CGI directly, and there's currently no FastCGI +version of Blërg, so you will have to run it under some kind of CGI to +FastCGI gateway, like the one described here on the nginx wiki. This +pretty much destroys the performance of Blërg, but it's all we've got +right now. +
There is an optional RSS cgi (rss.cgi
) that will serve
RSS feeds for users. Install this like blerg.cgi
above.
+As of 1.9.0, this is a perl FastCGI script, so you will have to make
+sure the perl libraries are available to it. A good way of doing that
+is to install to an environment directory, as described below.
+
+
The Makefile has support for installing Blërg into a directory that
+includes tools, libraries, and configuration snippets for shell and web
+servers. Use it as make install-environment
+ ENV_DIR=<directory>
. Under <directory>/etc will be
+a shell script that sets environment variables, and configuration
+snippets for nginx and apache to do the same. This should make it
+somewhat easier to use Blërg in a self-contained way.
+
+
For example, this will install Blërg to an environment directory +inside your home directory: + +
user@devhost:~/blerg$ make install-environment ENV_DIR=$HOME/blerg-env +... +user@devhost:~/blerg$ . ~/blerg-env/etc/env.sh ++ +
Then, you will be able to run tools like blergtool
, and
+it will operate on data inside ~/blerg-env/data
. Likewise,
+you can include
+/home/user/blerg-env/etc/nginx-fastcgi-vars.conf
or
+/home/user/blerg-env/etc/apache-setenv.conf
in your
+webserver to make the CGI/FastCGI scripts to the same thing.
password
or
new_password
are missing, the server returns JSON failure.
+Most of Blërg's core functionality is packaged in a static library
+called blerg.a
. It's not designed to be public or
+installed with `make install-environment`, but it should be relatively
+straightforward to use it in C programs. Look at the headers under the
+databse
directory.
+
+
A secondary library called blerg_auth.a
handles the
+authentication layer of Blërg. To use it, look at
+common/auth.h
.
+
+
As of 1.9.0, Blërg includes a perl library called
+Blerg::Database
. It wraps the core and authentication
+functionality in a perlish interface. The module has its own POD
+documentation, which you can read with your favorite POD reader, from
+the manual installed in an environment directory, or in HTML here.
+