configuration - Configuration file for extenso.
See Description
Configuration file is used to initialise the program:
#
# Project name
#
Project : "v5" # Name of project
WebsiteRoot : "/usr/local/website/v5" # Root of project
Locale : "fr_CA.utf8" # Locale used in program
Postmax : "64000" # Maximum number of bytes for a post
#
# Database connection
#
Database default {
Host : "localhost" # Server name
Name : "v5"
User : "v5"
Password : "v5"
}
#
# List of modules
#
Module exemple {
Library : "/usr/local/lib/libsnexemple.so"
Init : "snexemple_init"
}
Module oauth {
Library : "/usr/local/lib/libsnoauth.so"
Init : "snoauth_init"
}
Module curl {
Library : "/usr/local/lib/libsncurl.so"
Init : "sncurl_init"
}
# Timeout in second for the request If no timeout is specified, the default value is zero which mean no timeout at all.
Timeout : "5"
#
# Preload these functions
#
Preload : "/usr/local/website/v5/permission.snc"
#
# Index file
#
Index : "index.sn"
esc_cgidata : "false"
# Timeout for a request
Timeout : "5"
The preload is used to tell apache to preload this executable file.
When a file is request by apache, this code is executed. An example:
Results:
{_{
a = request();
ext = extention(a.filename);
"ext"; ext;
if ext ne "sn" && ext ne "snc" then
"set status to -1";
status(-1);
else
"set status to 0";
status(0);
endif
}}
In this case, if the extention of the file is sn or snc, the file will be parse by extenso. If not -1 is return which is the apache status DECLINED. The output of the execution is sent to error_log for debugging purpose.
Here is the list of parameters:
Written by Pierre Laplante, <laplante@sednove.com>
Cras sit amet nibh libero, in gravida nulla. Nulla vel metus scelerisque ante sollicitudin commodo. Cras purus odio, vestibulum in vulputate at, tempus viverra turpis.
1.0 2014-09-09 21:24:14 laplante@sednove.com