Permalink
Browse files

git-svn-id: svn://cherokee-project.com/cherokee/trunk@2041 5dc97367-9…

…7f1-0310-9951-d761b3857238
  • Loading branch information...
taher
taher committed Sep 23, 2008
1 parent 24cd442 commit 1ee8b21192008c9089bcec8cc8321c5369748fef
View
@@ -1,3 +1,8 @@
+2008-09-23 Taher Shihadeh <taher@unixwars.com>
+
+ * doc/cookbook_*, doc/modules_*: Addressed issue #126:
+ http://code.google.com/p/cherokee/issues/detail?id=126
+
2008-09-23 Alvaro Lopez Ortega <alvaro@alobbs.com>
* cherokee/rule_directory.c (match): Fixes a problem with the
View
@@ -125,7 +125,7 @@ media/images/admin_vserver_loggers.png \
media/images/admin_vserver.png \
media/images/admin_vserver_vserver.png \
media/images/cookbook_django_common.png \
-media/images/cookbook_django_scgi.png \
+media/images/cookbook_django_infosources.png \
media/images/cookbook_ror_common.png \
media/images/cookbook_ror_fcgi.png \
media/images/cookbook_mysql_rule.png \
View
@@ -14,7 +14,7 @@
<meta name="Keywords" content="cherokee web server httpd http" />
<meta name="Description" content="Cherokee is a flexible, very fast, lightweight Web server. It is implemented entirely in C, and has no dependencies beyond a standard C library. It is embeddable and extensible with plug-ins. It supports on-the-fly configuration by reading files or strings, TLS/SSL (via GNUTLS or OpenSSL), virtual hosts, authentication, cache friendly features, PHP, custom error management, and much more." />
<link href="media/css/cherokee_doc.css" rel="stylesheet" type="text/css" media="all" />
- <title>{doctitle=}</title>
+ <title>{doctitle}</title>
</head>
<body>
@@ -26,7 +26,6 @@ There are two possible settings as *information sources*:
reroute the information to allow you to serve SSH sessions via your
webserver or any other neat tricks you can think of.
-
Note that because of Cherokee's flexibility and modularity, sometimes
and deppending of the situation one or the other setting might not
make much sense. In such ocasions `cherokee-admin` will simply hide
@@ -57,3 +56,4 @@ And these are the handlers that use balancing:
* link:modules_handlers_fcgi.html[FastCGI]
* link:modules_handlers_scgi.html[SCGI]
* link:modules_handlers_mirror.html[Generic balancer]
+* link:modules_handlers_dbslayer.html[Data Base bridge]
View
@@ -25,7 +25,6 @@ You will need Flup because it implements the standard interface
between Python Web applications and Web servers, so you will be using
it to run your web application either as FastCGI or SCGI.
-
Once you are done with that, you must deploy your Django project:
----
@@ -53,28 +52,33 @@ handler instead you would only have to omit the last parameter and
FastCGI would be used by default. The configuration of the handler is
exactly the same for SCGI and FastCGI.
-Once you have created the new rule for your `/var/www/example
-directory`, choose the desired handler and use the following
+Once you have created the new rule for your `/var/www/example`
+directory, choose the desired handler and use the following
configuration.
.Common CGI options
Under `Common CGI options` make sure to check the `Error handler` box and
uncheck `Check file`. This is to prevent possible errors with the
`INFO_PATH` generation that can happen when an application, in this
-case 'Rails', manages the whole subtree. This is mentioned in the
+case 'Django', manages the whole subtree. This is mentioned in the
link:modules_handlers_cgi.html[Common CGI] section of the
documentation.
image::media/images/cookbook_django_common.png[Common CGI options]
.SCGI specific
Under `SCGI specific` make sure to add the hosts providing the
-service. Note that you will have to manually launch the `spawner` if
+service. This is done by adding one or more information sources.
+
+image::media/images/media/images/cookbook_django_infosources.png[Info Sources]
+
+Note that you will have to manually launch the `spawner` if
you use a `Remote host` as `Information source` instead of a `Local
interpreter`.
-You will simply have to add as many sources as desired, for instance
-our example uses the port 3033.
+You will simply have to add as many sources as needed, for instance
+our example uses one nicknamed `django1`, created as *local
+interpreter* with these parameters on port 3033.
[grid="rows"]
`~~~~~~~~~~~~~~`~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -86,5 +90,3 @@ localhost:3033 , `/var/www/example/manage.py runfcgi method=threaded ` \
You can set up as many hosts as desired and Cherokee will balance the
load among them.
-
-image::media/images/cookbook_django_scgi.png[SCGI specifics]
View
@@ -8,17 +8,19 @@ The default configuration (the one created by `cherokee-admin` from
scratch when there is no `cherokee.conf` present) already supports
PHP.
-This example shows a typical usage of FastCGI. It connects to a
-FastCGI server located in localhost in port 1234. If no server is
-running, the webserver will run the FastCGI server by issuing the command
-defined as the *Interpreter* sub-parameter:
+This example shows a typical usage of FastCGI. It only uses one
+link:config_info_sources.html[information source] nicknamed `php` in
+this case. This connects to a FastCGI server located in localhost in
+port 1234. If no server is running, the webserver will run the FastCGI
+server by issuing the command defined as the *Interpreter*
+sub-parameter:
image::media/images/admin_handler_fastcgi1.png[Fastcgi]
This other example shows a typical usage of multiple FastCGI
servers. It connects to FastCGI servers in several locations. If no
server is running in the local computer, the webserver will run the
-FastCGI server by issuing the specified command. Note that for remote
+FastCGI server by issuing the specified command. Note that for *remote*
FastCGI servers, you are responsible of running the FastCGI services
there manually:
View
@@ -79,12 +79,16 @@ image::media/images/cookbook_ror_common.png[Common CGI options]
.FastCGI specific
Under `FastCGI specific` make sure to add the hosts providing the
-service. Note that you will have to manually launch the `spawner` if
-you use a `Remote host` as `Information source` instead of a `Local
-interpreter`.
+service. Do this by adding one or more
+link:config_info_sources.html[Information Sources].
+
+Note that, in the definition of the informaction source, you will have
+to manually launch the `spawner` if you use a `Remote host` as
+`Information source` instead of a `Local interpreter`.
You will simply have to add as many sources as desired, for instance
-our example uses the default values to set up ports 8000 through 8002:
+our example uses the default values to set up ports 8000 through
+8002. These sources will be nicknamed *ror0*, *ror1* and *ror2*.
[grid="rows"]
`~~~~~~~~~~~~~~`~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -98,4 +102,7 @@ localhost:8002 , `/home/foo/example/script/process/spawner fastcgi`
If any of those ports was not reachable, the `interpreter` command
would be launched and the fallen one would be reinstantiated.
+Here is a snapshot to show the creation of *ror0*. The rest are
+similar using the port variation detailed above.
+
image::media/images/cookbook_ror_fcgi.png[FastCGI specifics]
View
@@ -108,7 +108,7 @@ link:dev.html[Development info]
. link:dev_cherokee.conf.html[cherokee.conf]: Internal configuration specs.
////
. link:dev_api.html[API introduction]
- . link:dev_examples.html[Examples]
+ . link:dev_examples.html[Examples]: Development examples
////
////////////////////////////////////////////////////
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -38,3 +38,4 @@ And these are the handlers that use balancing:
* link:modules_handlers_fcgi.html[FastCGI]
* link:modules_handlers_scgi.html[SCGI]
* link:modules_handlers_mirror.html[Generic balancer]
+* link:modules_handlers_dbslayer.html[Data Base bridge]
@@ -6,17 +6,6 @@ Balancer: Round Robin
If multiple server entries are defined, the requests will be round-robinly
served by each of them.
-The configurable parameters will vary depending on what has been
-selected as information host. If it is set to *remote*, only a host
-address will be required. If that is not the case then configurable
-parameters will be:
-
-* Host: Either a local or remote host and port.
-
-* Interpreter: Defines the command line of the interpreter for this
- server. If you are using FastCGI or SCGI and are launching the
- services manually, this entry is not needed.
-
-* Environment variables: When running in local host, you can set up
- environment variables to be used by whatever is serving your
- load-balanced requests.
+The only thing needed to configure this balancer is a list of
+link:config_info_sources.html[information sources]. At least one must
+be selected in order for this to work.
@@ -32,8 +32,8 @@ extension.
To set up the FastCGI specifics, read the
link:modules_balancers.html[Balancers] section for general information
-and the link:modules_balancers_round_robin.html[Round robin] section
-for more details.
+and the link:config_info_sources.html[information sources] section for
+more details.
Examples

0 comments on commit 1ee8b21

Please sign in to comment.