]> git.openstreetmap.org Git - chef.git/blob - cookbooks/imagery/templates/default/mapserv_fcgi.conf.erb
Add leading ? to SECTION line in shorewall rules
[chef.git] / cookbooks / imagery / templates / default / mapserv_fcgi.conf.erb
1 # DO NOT EDIT - This file is being maintained by Chef
2
3 description     "starts mapserver in daemon mode for fastcgi"
4
5 start on (net-device-up
6           and local-filesystems
7           and runlevel [2345])
8 stop on runlevel [!2345]
9
10 respawn
11
12 limit nofile 16384 16384
13
14 # https://trac.osgeo.org/mapserver/wiki/EnvironmentVariables
15 env MS_MAPFILE="/srv/imagery/mapserver/layer-<%= @layer %>.map"
16 env MS_MAP_PATTERN="^/srv/imagery/mapserver/"
17 env MS_ERRORFILE="/tmp/mapserver-layer-<%= @layer %>.log"
18 env MS_DEBUGLEVEL="5"
19
20 pre-start script
21     mkdir -p -m 0775 /var/run/mapserver-fastcgi
22     chown imagery:imagery /var/run/mapserver-fastcgi
23 end script
24
25 script
26     exec /usr/bin/spawn-fcgi \
27         -n \
28         -u imagery \
29         -g imagery \
30         -s /var/run/mapserver-fastcgi/layer-<%= @layer %>.socket \
31         -M 0666 \
32         -f /usr/lib/cgi-bin/mapserv
33 end script