[mapserver-dev] Draft proposal for 8.0 - Site Context FIles
Even Rouault
even.rouault at spatialys.com
Sat Apr 3 04:37:37 PDT 2021
Steve,
Excellent initiative. A few remarks:
- Why not calling this a configuration file ? I believe it would be
slightly clearer than context
- Since MS 8.0 will include nlohmann/json, perhaps consider a JSON
configuration file rather than our historical mapfile-like syntax ? This
would allow to develop a json-schema for validation. Your example would
become:
{
"env": {
"#comment": "put some comment here"
"|MS_MAP_NO_PATH": "true"
|
},
"maps": {
"|MAP1": "/opt/mapserver/myapp/map1.map",|
| "MAP2": "||/opt/mapserver/myapp/map2.map"|
||
}
}
- Regarding using putenv(), I'm not sure this is a good idea in FastCGI
mode, according to what is mentioned in
http://web.mit.edu/wwwdev/man/man3/FCGI_Accept.3. Using GDAL
CPLSetConfigOption() instead of putenv() and CPLGetConfigOption()
instead of getenv() would avoid messing with the "environ" global
variable. (unless I'm wrong our CI doesn't test at all CGI / FastCGI ...
I'll try to look at adding some testing of this)
Even
Le 02/04/2021 à 23:19, Steve Lime a écrit :
> Hi all: Just thinking about ways to make configuring MapServer easier
> for information you can't or don't want to manage in mapfiles.
> Currently that is done via environment variables. Another option would
> be the use of config/ini-type file. I've started a draft RFC for
> something I'll call a MapServer context file for the moment. See
> https://github.com/sdlime/mapserver/wiki/MapServer-8.0-Context-File
> <https://github.com/sdlime/mapserver/wiki/MapServer-8.0-Context-File>
> for more information. Just floating an idea at this point...
>
> --Steve
>
> _______________________________________________
> mapserver-dev mailing list
> mapserver-dev at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/mapserver-dev
--
http://www.spatialys.com
My software is free, but my time generally not.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20210403/2cf8198a/attachment.html>
More information about the mapserver-dev
mailing list