Fossil SCM

Copied over documentation of 2 recently-added "fossil cgi" control file lines to the www/cgi.wiki doc (redirect and jsmode) and then reordered it all to match the order given in "fossil cgi --help" output to make it easier to maintain these parallel lists in the future.

wyoung 2021-03-01 07:15 trunk
Commit 282402d82fb394c1854518fed475260f22fd27ec2a0a0930c9b7ef3b115766fa
1 file changed +82 -56
+82 -56
--- www/cgi.wiki
+++ www/cgi.wiki
@@ -36,16 +36,18 @@
3636
the form "<b>property:&nbsp;argument&nbsp;...</b>".
3737
The remainder of this document describes the available properties and
3838
their arguments.
3939
4040
<hr>
41
+
4142
<h2 id="repository">repository: <i>PATH</i></h2>
4243
4344
This property defines the Fossil repository that the server will use.
4445
Every Fossil CGI requires either this property or the
4546
[#directory|<b>directory:</b>] property (but not both).
4647
Many Fossil CGI scripts have this one property and no other.
48
+
4749
4850
<h2 id="directory">directory: <i>PATH</i></h2>
4951
5052
The PATH is the name of a directory that contains one or more Fossil
5153
repository files having the suffix ".fossil". If this property is used
@@ -52,23 +54,16 @@
5254
instead of [#repository|<b>repository:</b>], then the Fossil server is
5355
able to serve all of the repositories in the directory. The specific
5456
repository used is selected by a prefix on the PATH_INFO.
5557
5658
57
-<h2 id="errorlog">errorlog: <i>FILENAME</i></h2>
58
-
59
-This setting causes the server to log any errors in FILENAME.
60
-It is ok for multiple Fossil CGIs to share the same error log.
61
-
62
-Setting up an error log for Fossil servers is not required, but it
63
-is recommended.
64
-
6559
<h2 id="notfound">notfound: <i>URL</i></h2>
6660
6761
If the [#directory|<b>directory:</b>] option is used and if the PATH_INFO
6862
of the HTTP request does not correspond to any Fossil repository, then
6963
the request redirects to URL.
64
+
7065
7166
<h2 id="repolist">repolist</h2>
7267
7368
This is a Boolean property.
7469
If it is present, and if the [#directory:|<b>directory:</b>] option is used,
@@ -78,10 +73,75 @@
7873
The "skin" of the reply is determined by the first
7974
repository in the list that has a non-zero
8075
[/help?cmd=repolist-skin|repolist-skin] setting.
8176
If no repository has such a non-zero repolist-skin setting, then
8277
the repository list is generic HTML without any decoration.
78
+
79
+
80
+<h2 id="localauth">localauth</h2>
81
+
82
+This is a Boolean property.
83
+If it is present, [./caps/ref.html#s | setup capability]
84
+is granted to any HTTP request that
85
+comes in over a loopback interface, such as 127.0.0.1.
86
+
87
+
88
+<h2 id="skin">skin: <i>NAME</i></h2>
89
+
90
+If NAME is the name of one of the built-in skins supported by Fossil,
91
+then this option causes Fossil to display using that built-in skin,
92
+and to ignore any custom skin that might be configured in the repository
93
+itself.
94
+
95
+So, if you wanted to set up a server for a single Fossil project, but
96
+also give users the option to use several of the different built-in
97
+skins, you could create multiple CGI scripts, each with a different
98
+"<b>skin:</b>" property, but all pointing to the same <b>repository:</b>.
99
+Then users can select which skin to use by using the appropriate CGI.
100
+
101
+
102
+<h2 id="files">files: </i>GLOBLIST</i></h2>
103
+
104
+The GLOBLIST argument is a comma-separate list of "globs" that specify
105
+filenames. In [#directory|<b>directory:</b> mode], if the PATH_INFO
106
+does not identify any Fossil repository, but it does refer some other
107
+file in the directory, and that filename matches one of the glob patterns
108
+in the GLOBLIST, then the file is returned as static content.
109
+
110
+
111
+<h2 id="setenv">setenv: <i>NAME VALUE</i></h2>
112
+
113
+This parameter causes additional environment variable NAME to have VALUE.
114
+This parameter can be repeated as many times as necessary.
115
+
116
+
117
+<h2 id="HOME">HOME: <i>PATH</i></h2>
118
+
119
+This parameter is a short-hand for "<b>setenv HOME <i>PATH</i></b>".
120
+
121
+
122
+<h2 id="cgi-debug">cgi-debug: <i>FILE</i></h2>
123
+
124
+Cause CGI-related debugging information to be appended in <i>FILE</i>. Use
125
+this to help debug CGI problems.
126
+
127
+
128
+<h2 id="errorlog">errorlog: <i>FILENAME</i></h2>
129
+
130
+This setting causes the server to log any errors in FILENAME.
131
+It is ok for multiple Fossil CGIs to share the same error log.
132
+
133
+Setting up an error log for Fossil servers is not required, but it
134
+is recommended.
135
+
136
+
137
+<h2 id="timeout">timeout: <i>N</i></h2>
138
+
139
+This property changes the timeout on each CGI request to N seconds.
140
+If N is zero, then there is no timeout. If this property is omitted,
141
+then the default timeout is 300 seconds (5 minutes).
142
+
83143
84144
<h2 id="extroot">extroot: <i>PATH</i></h2>
85145
86146
This property defines the DOCUMENT_ROOT for the
87147
[./serverext.wiki|CGI Server Extensions]. If this property
@@ -93,52 +153,24 @@
93153
extension. The sub-CGI extension outputs reply text, when Fossil
94154
then (optionally) augments with its own header and footer and returns
95155
to the original requestor. The property controls the DOCUMENT_ROOT
96156
of the sub-CGI.
97157
98
-<h2 id="timeout">timeout: <i>N</i></h2>
99
-
100
-This property changes the timeout on each CGI request to N seconds.
101
-If N is zero, then there is no timeout. If this property is omitted,
102
-then the default timeout is 300 seconds (5 minutes).
103
-
104
-<h2 id="localauth">localauth</h2>
105
-
106
-This is a Boolean property.
107
-If it is present, [./caps/ref.html#s | setup capability]
108
-is granted to any HTTP request that
109
-comes in over a loopback interface, such as 127.0.0.1.
110
-
111
-<h2 id="skin">skin: <i>NAME</i></h2>
112
-
113
-If NAME is the name of one of the built-in skins supported by Fossil,
114
-then this option causes Fossil to display using that built-in skin,
115
-and to ignore any custom skin that might be configured in the repository
116
-itself.
117
-
118
-So, if you wanted to set up a server for a single Fossil project, but
119
-also give users the option to use several of the different built-in
120
-skins, you could create multiple CGI scripts, each with a different
121
-"<b>skin:</b>" property, but all pointing to the same <b>repository:</b>.
122
-Then users can select which skin to use by using the appropriate CGI.
123
-
124
-<h2 id="files">files: </i>GLOBLIST</i></h2>
125
-
126
-The GLOBLIST argument is a comma-separate list of "globs" that specify
127
-filenames. In [#directory|<b>directory:</b> mode], if the PATH_INFO
128
-does not identify any Fossil repository, but it does refer some other
129
-file in the directory, and that filename matches one of the glob patterns
130
-in the GLOBLIST, then the file is returned as static content.
131
-
132
-<h2 id="setenv">setenv: <i>NAME VALUE</i></h2>
133
-
134
-This parameter causes additional environment variable NAME to have VALUE.
135
-This parameter can be repeated as many times as necessary.
136
-
137
-<h2 id="HOME">HOME: <i>PATH</i></h2>
138
-
139
-This parameter is a short-hand for "<b>setenv HOME <i>PATH</i></b>".
158
+
159
+<h2 id="redirect">redirect: <i>REPO URL</i></h2>
160
+
161
+Extract the "name" query parameter and search REPO for a check-in or
162
+ticket that matches the value of "name", then redirect to URL. There
163
+can be multiple "redirect:" lines that are processed in order. If the
164
+repo name is "*", then an unconditional redirect to URL is taken.
165
+
166
+
167
+<h2 id="jsmode">jsmode: <i>VALUE</i></h2>
168
+
169
+Specifies the delivery mode for JavaScript files. See "[/help?cmd=http |
170
+http --jsmode]" for the allowed values and their meanings.
171
+
140172
141173
<h2 id="mainmenu">mainmenu: <i>FILE</i></h2>
142174
143175
This parameter causes the contents of the given file to override the
144176
site's <tt>mainmenu</tt> configuration setting, much in the same way
@@ -145,11 +177,5 @@
145177
that the <tt>skin</tt> setting overrides the skin. This can be used to
146178
apply a common main menu to a number of sites, and centrally maintain
147179
it, without having to copy its contents into each site. Note, however,
148180
that the contents of this setting are not stored in the repository and
149181
will not be cloned along with the repository.
150
-
151
-
152
-<h2 id="cgi-debug">cgi-debug: <i>FILE</i></h2>
153
-
154
-Cause CGI-related debugging information to be appended in <i>FILE</i>. Use
155
-this to help debug CGI problems.
156182
--- www/cgi.wiki
+++ www/cgi.wiki
@@ -36,16 +36,18 @@
36 the form "<b>property:&nbsp;argument&nbsp;...</b>".
37 The remainder of this document describes the available properties and
38 their arguments.
39
40 <hr>
 
41 <h2 id="repository">repository: <i>PATH</i></h2>
42
43 This property defines the Fossil repository that the server will use.
44 Every Fossil CGI requires either this property or the
45 [#directory|<b>directory:</b>] property (but not both).
46 Many Fossil CGI scripts have this one property and no other.
 
47
48 <h2 id="directory">directory: <i>PATH</i></h2>
49
50 The PATH is the name of a directory that contains one or more Fossil
51 repository files having the suffix ".fossil". If this property is used
@@ -52,23 +54,16 @@
52 instead of [#repository|<b>repository:</b>], then the Fossil server is
53 able to serve all of the repositories in the directory. The specific
54 repository used is selected by a prefix on the PATH_INFO.
55
56
57 <h2 id="errorlog">errorlog: <i>FILENAME</i></h2>
58
59 This setting causes the server to log any errors in FILENAME.
60 It is ok for multiple Fossil CGIs to share the same error log.
61
62 Setting up an error log for Fossil servers is not required, but it
63 is recommended.
64
65 <h2 id="notfound">notfound: <i>URL</i></h2>
66
67 If the [#directory|<b>directory:</b>] option is used and if the PATH_INFO
68 of the HTTP request does not correspond to any Fossil repository, then
69 the request redirects to URL.
 
70
71 <h2 id="repolist">repolist</h2>
72
73 This is a Boolean property.
74 If it is present, and if the [#directory:|<b>directory:</b>] option is used,
@@ -78,10 +73,75 @@
78 The "skin" of the reply is determined by the first
79 repository in the list that has a non-zero
80 [/help?cmd=repolist-skin|repolist-skin] setting.
81 If no repository has such a non-zero repolist-skin setting, then
82 the repository list is generic HTML without any decoration.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
83
84 <h2 id="extroot">extroot: <i>PATH</i></h2>
85
86 This property defines the DOCUMENT_ROOT for the
87 [./serverext.wiki|CGI Server Extensions]. If this property
@@ -93,52 +153,24 @@
93 extension. The sub-CGI extension outputs reply text, when Fossil
94 then (optionally) augments with its own header and footer and returns
95 to the original requestor. The property controls the DOCUMENT_ROOT
96 of the sub-CGI.
97
98 <h2 id="timeout">timeout: <i>N</i></h2>
99
100 This property changes the timeout on each CGI request to N seconds.
101 If N is zero, then there is no timeout. If this property is omitted,
102 then the default timeout is 300 seconds (5 minutes).
103
104 <h2 id="localauth">localauth</h2>
105
106 This is a Boolean property.
107 If it is present, [./caps/ref.html#s | setup capability]
108 is granted to any HTTP request that
109 comes in over a loopback interface, such as 127.0.0.1.
110
111 <h2 id="skin">skin: <i>NAME</i></h2>
112
113 If NAME is the name of one of the built-in skins supported by Fossil,
114 then this option causes Fossil to display using that built-in skin,
115 and to ignore any custom skin that might be configured in the repository
116 itself.
117
118 So, if you wanted to set up a server for a single Fossil project, but
119 also give users the option to use several of the different built-in
120 skins, you could create multiple CGI scripts, each with a different
121 "<b>skin:</b>" property, but all pointing to the same <b>repository:</b>.
122 Then users can select which skin to use by using the appropriate CGI.
123
124 <h2 id="files">files: </i>GLOBLIST</i></h2>
125
126 The GLOBLIST argument is a comma-separate list of "globs" that specify
127 filenames. In [#directory|<b>directory:</b> mode], if the PATH_INFO
128 does not identify any Fossil repository, but it does refer some other
129 file in the directory, and that filename matches one of the glob patterns
130 in the GLOBLIST, then the file is returned as static content.
131
132 <h2 id="setenv">setenv: <i>NAME VALUE</i></h2>
133
134 This parameter causes additional environment variable NAME to have VALUE.
135 This parameter can be repeated as many times as necessary.
136
137 <h2 id="HOME">HOME: <i>PATH</i></h2>
138
139 This parameter is a short-hand for "<b>setenv HOME <i>PATH</i></b>".
140
141 <h2 id="mainmenu">mainmenu: <i>FILE</i></h2>
142
143 This parameter causes the contents of the given file to override the
144 site's <tt>mainmenu</tt> configuration setting, much in the same way
@@ -145,11 +177,5 @@
145 that the <tt>skin</tt> setting overrides the skin. This can be used to
146 apply a common main menu to a number of sites, and centrally maintain
147 it, without having to copy its contents into each site. Note, however,
148 that the contents of this setting are not stored in the repository and
149 will not be cloned along with the repository.
150
151
152 <h2 id="cgi-debug">cgi-debug: <i>FILE</i></h2>
153
154 Cause CGI-related debugging information to be appended in <i>FILE</i>. Use
155 this to help debug CGI problems.
156
--- www/cgi.wiki
+++ www/cgi.wiki
@@ -36,16 +36,18 @@
36 the form "<b>property:&nbsp;argument&nbsp;...</b>".
37 The remainder of this document describes the available properties and
38 their arguments.
39
40 <hr>
41
42 <h2 id="repository">repository: <i>PATH</i></h2>
43
44 This property defines the Fossil repository that the server will use.
45 Every Fossil CGI requires either this property or the
46 [#directory|<b>directory:</b>] property (but not both).
47 Many Fossil CGI scripts have this one property and no other.
48
49
50 <h2 id="directory">directory: <i>PATH</i></h2>
51
52 The PATH is the name of a directory that contains one or more Fossil
53 repository files having the suffix ".fossil". If this property is used
@@ -52,23 +54,16 @@
54 instead of [#repository|<b>repository:</b>], then the Fossil server is
55 able to serve all of the repositories in the directory. The specific
56 repository used is selected by a prefix on the PATH_INFO.
57
58
 
 
 
 
 
 
 
 
59 <h2 id="notfound">notfound: <i>URL</i></h2>
60
61 If the [#directory|<b>directory:</b>] option is used and if the PATH_INFO
62 of the HTTP request does not correspond to any Fossil repository, then
63 the request redirects to URL.
64
65
66 <h2 id="repolist">repolist</h2>
67
68 This is a Boolean property.
69 If it is present, and if the [#directory:|<b>directory:</b>] option is used,
@@ -78,10 +73,75 @@
73 The "skin" of the reply is determined by the first
74 repository in the list that has a non-zero
75 [/help?cmd=repolist-skin|repolist-skin] setting.
76 If no repository has such a non-zero repolist-skin setting, then
77 the repository list is generic HTML without any decoration.
78
79
80 <h2 id="localauth">localauth</h2>
81
82 This is a Boolean property.
83 If it is present, [./caps/ref.html#s | setup capability]
84 is granted to any HTTP request that
85 comes in over a loopback interface, such as 127.0.0.1.
86
87
88 <h2 id="skin">skin: <i>NAME</i></h2>
89
90 If NAME is the name of one of the built-in skins supported by Fossil,
91 then this option causes Fossil to display using that built-in skin,
92 and to ignore any custom skin that might be configured in the repository
93 itself.
94
95 So, if you wanted to set up a server for a single Fossil project, but
96 also give users the option to use several of the different built-in
97 skins, you could create multiple CGI scripts, each with a different
98 "<b>skin:</b>" property, but all pointing to the same <b>repository:</b>.
99 Then users can select which skin to use by using the appropriate CGI.
100
101
102 <h2 id="files">files: </i>GLOBLIST</i></h2>
103
104 The GLOBLIST argument is a comma-separate list of "globs" that specify
105 filenames. In [#directory|<b>directory:</b> mode], if the PATH_INFO
106 does not identify any Fossil repository, but it does refer some other
107 file in the directory, and that filename matches one of the glob patterns
108 in the GLOBLIST, then the file is returned as static content.
109
110
111 <h2 id="setenv">setenv: <i>NAME VALUE</i></h2>
112
113 This parameter causes additional environment variable NAME to have VALUE.
114 This parameter can be repeated as many times as necessary.
115
116
117 <h2 id="HOME">HOME: <i>PATH</i></h2>
118
119 This parameter is a short-hand for "<b>setenv HOME <i>PATH</i></b>".
120
121
122 <h2 id="cgi-debug">cgi-debug: <i>FILE</i></h2>
123
124 Cause CGI-related debugging information to be appended in <i>FILE</i>. Use
125 this to help debug CGI problems.
126
127
128 <h2 id="errorlog">errorlog: <i>FILENAME</i></h2>
129
130 This setting causes the server to log any errors in FILENAME.
131 It is ok for multiple Fossil CGIs to share the same error log.
132
133 Setting up an error log for Fossil servers is not required, but it
134 is recommended.
135
136
137 <h2 id="timeout">timeout: <i>N</i></h2>
138
139 This property changes the timeout on each CGI request to N seconds.
140 If N is zero, then there is no timeout. If this property is omitted,
141 then the default timeout is 300 seconds (5 minutes).
142
143
144 <h2 id="extroot">extroot: <i>PATH</i></h2>
145
146 This property defines the DOCUMENT_ROOT for the
147 [./serverext.wiki|CGI Server Extensions]. If this property
@@ -93,52 +153,24 @@
153 extension. The sub-CGI extension outputs reply text, when Fossil
154 then (optionally) augments with its own header and footer and returns
155 to the original requestor. The property controls the DOCUMENT_ROOT
156 of the sub-CGI.
157
158
159 <h2 id="redirect">redirect: <i>REPO URL</i></h2>
160
161 Extract the "name" query parameter and search REPO for a check-in or
162 ticket that matches the value of "name", then redirect to URL. There
163 can be multiple "redirect:" lines that are processed in order. If the
164 repo name is "*", then an unconditional redirect to URL is taken.
165
166
167 <h2 id="jsmode">jsmode: <i>VALUE</i></h2>
168
169 Specifies the delivery mode for JavaScript files. See "[/help?cmd=http |
170 http --jsmode]" for the allowed values and their meanings.
171
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
172
173 <h2 id="mainmenu">mainmenu: <i>FILE</i></h2>
174
175 This parameter causes the contents of the given file to override the
176 site's <tt>mainmenu</tt> configuration setting, much in the same way
@@ -145,11 +177,5 @@
177 that the <tt>skin</tt> setting overrides the skin. This can be used to
178 apply a common main menu to a number of sites, and centrally maintain
179 it, without having to copy its contents into each site. Note, however,
180 that the contents of this setting are not stored in the repository and
181 will not be cloned along with the repository.
 
 
 
 
 
 
182

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button