[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[myserver-commit] [2993] Added examples to the documentation.
From: |
Giuseppe Scrivano |
Subject: |
[myserver-commit] [2993] Added examples to the documentation. |
Date: |
Mon, 02 Feb 2009 19:29:12 +0000 |
Revision: 2993
http://svn.sv.gnu.org/viewvc/?view=rev&root=myserver&revision=2993
Author: gscrivano
Date: 2009-02-02 19:29:11 +0000 (Mon, 02 Feb 2009)
Log Message:
-----------
Added examples to the documentation.
Modified Paths:
--------------
trunk/myserver/documentation/basic_configuration.texi
trunk/myserver/documentation/mime_types.texi
trunk/myserver/documentation/process_security.texi
trunk/myserver/documentation/security.texi
trunk/myserver/documentation/virtual_hosts.texi
Modified: trunk/myserver/documentation/basic_configuration.texi
===================================================================
--- trunk/myserver/documentation/basic_configuration.texi 2009-02-01
19:08:46 UTC (rev 2992)
+++ trunk/myserver/documentation/basic_configuration.texi 2009-02-02
19:29:11 UTC (rev 2993)
@@ -52,7 +52,7 @@
<USE_ERROR_FILE>YES</USE_ERROR_FILE>
@end example
-So, if you set the value to NO, like in the line below,
+So, if you set the value to @code{NO}, like in the line below,
@example
<USE_ERROR_FILE>NO</USE_ERROR_FILE>
Modified: trunk/myserver/documentation/mime_types.texi
===================================================================
--- trunk/myserver/documentation/mime_types.texi 2009-02-01 19:08:46 UTC
(rev 2992)
+++ trunk/myserver/documentation/mime_types.texi 2009-02-02 19:29:11 UTC
(rev 2993)
@@ -22,13 +22,18 @@
the MIME attribute specifies the MIME name.
@item extension
-the MIME type will be used by any file with this extension.
+the MIME type will be used by any file with this extension. More
address@hidden items can be specified for the same MIME type.
@item filter
-this directive registers a filter to use with MIME type.
+this directive registers a filter to use on the MIME type. It depends
+from the protocol how it will be handled, a protocol may ignore this
+directive. For example HTTP will use a modifier filter only if it is
+accepted by the client.
@item handler
-specifies the way the file is handled by the server.
+specifies how the server will manage this file. It is protocol
+specific, for example, FTP doesn't support it.
@item param
specifies additional params for the handler.
@@ -38,8 +43,8 @@
server.
For example, there is need to use selfExecuted on the CGI protocol if
the accessed resource can be used as a process. Differently if it is
-not specified the resource mapped by the URI will be used as an
-argument to @code{param}.
+not specified, the resource mapped by the URI will be used as an
+additional argument to @code{param}.
@end itemize
@code{<FILTER>} defines a filter for the MIME type. The data will
Modified: trunk/myserver/documentation/process_security.texi
===================================================================
--- trunk/myserver/documentation/process_security.texi 2009-02-01 19:08:46 UTC
(rev 2992)
+++ trunk/myserver/documentation/process_security.texi 2009-02-02 19:29:11 UTC
(rev 2993)
@@ -21,6 +21,18 @@
auto-reboot because it will not be possible to get back old
permissions.
address@hidden CGI processes.
+It is possible to run CGI processes using a different uid/gid. It can
+be done defining the ``cgi.uid'' and ``cgi.gid'' values in a
+configuration file. It can be specified at any configuration level.
+
+These directives can be used in a security file to force the execution
+of the new process with both uid and gid to 1000.
address@hidden
+<DEFINE name="cgi.uid" value="1000" />
+<DEFINE name="cgi.gid" value="1000" />
address@hidden example
+
@section Fork Server
In a POSIX environment the @code{fork} syscall is used to execute new
processes. It clones the caller process keeping any open file or
@@ -38,6 +50,10 @@
It is enabled passing the @code{-f} switch to the myserver process.
+If the MyServer main process is configured to change its uid/gid after
+its initialization, it is the only way to spawn new processes with
+uid/gid different than the MyServer process.
+
@section FastCGI/SCGI servers
By default, FastCGI and SCGI servers are lazily initialized by
MyServer on the first request to a resource that is handled trought
@@ -50,7 +66,6 @@
A @code{PROCESS_SERVER} entry makes it possible to access a specific
FastCGI/SCGI configuration inside MIME types by its name.
-
@example
<PROCESS_SERVER>
<NAME>/opt/bin/fastcgi_server</NAME>
@@ -61,10 +76,31 @@
</PROCESS_SERVER>
@end example
-In the previous example a FastCGI server
+In the previous example the FastCGI server
@code{/opt/bin/fastcgi_server} is created. The @code{domain} must be
-"fastcgi" or "scgi", depending on the protocol to use.
+"fastcgi" or "scgi", depending on the specific protocol to use.
@code{LOCAL} specifies if the server is handled by myserver or it is
-already running, thus myserver will simply access and use it. In this
-case @code{name} can be anything without any specific meaning.
+already running; in the former case, myserver will simply access and
+use it.
+If the server is not local then the @code{name} is a simple label that
+can be used by a MIME type trought @code{param} to access it.
+
+The following code, declare an already running FastCGI server and
+registers it on the @code{fcgi} extension:
+
address@hidden
+<!-- Inside myserver.xml. -->
+<PROCESS_SERVER>
+ <NAME>a_remote_server</NAME>
+ <DOMAIN>fastcgi</DOMAIN>
+ <HOST>foo</HOST>
+ <PORT>2010</PORT>
+ <LOCAL>NO</LOCAL>
+</PROCESS_SERVER>
+
+<!-- Inside MIMEtypes.xml. -->
+<MIME mime="text/html" handler="RUNFASTCGI" param="a_remote_server">
+ <EXTENSION value="fcgi"/>
+</MIME>
address@hidden example
Modified: trunk/myserver/documentation/security.texi
===================================================================
--- trunk/myserver/documentation/security.texi 2009-02-01 19:08:46 UTC (rev
2992)
+++ trunk/myserver/documentation/security.texi 2009-02-02 19:29:11 UTC (rev
2993)
@@ -14,6 +14,7 @@
@item Local @file{.security.xml}.
@item Parent directories @file{.security.xml}.
@item System vhost directory @file{.security.xml}.
address@hidden MIME type configuration @file{MIMEtypes.xml}.
@item Virtual host configuration.
@item Global server configuration.
@end enumerate
Modified: trunk/myserver/documentation/virtual_hosts.texi
===================================================================
--- trunk/myserver/documentation/virtual_hosts.texi 2009-02-01 19:08:46 UTC
(rev 2992)
+++ trunk/myserver/documentation/virtual_hosts.texi 2009-02-02 19:29:11 UTC
(rev 2993)
@@ -86,14 +86,15 @@
Although FTP is used for public file sharing, restrictions may be
imposed using security file.
address@hidden HTTP specific configuration
MyServer gives you the option to enable the HTTP TRACE command for
each virtual host. All you need to do is edit the @file{security.xml}
file of the root of your virtual host (not a subdirectory! If the
file doesn't exist, you may create a new one), and add the parameter:
@example
-<HTTP TRACE="ON" />
+<DEFINE name="http.allow_trace" value="YES" />
@end example
-Once you do that, you enable HTTP TRACE command. By default, it's
-disabled (so, simply delete the line, if you want to disable it)
+Once you do that, you enable the HTTP TRACE command. By default, it's
+disabled.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [myserver-commit] [2993] Added examples to the documentation.,
Giuseppe Scrivano <=