Alias /renderd-example-map @PROJECT_SOURCE_DIR@/utils/example-map
Redirect /renderd-example-map/leaflet/leaflet.css https://unpkg.com/leaflet/dist/leaflet.css
Redirect /renderd-example-map/leaflet/leaflet.min.js https://unpkg.com/leaflet/dist/leaflet.js

<Directory @PROJECT_SOURCE_DIR@/utils/example-map>
  Allow from all
  AllowOverride All
  DirectoryIndex index.html
  Options +FollowSymLinks
  Order Allow,Deny
</Directory>

<IfModule !tile_module>
  LoadModule tile_module @PROJECT_BINARY_DIR@/src/mod_tile.so
</IfModule>

<VirtualHost @HTTPD0_HOST@:@HTTPD0_PORT@>
  LoadTileConfigFile @PROJECT_BINARY_DIR@/tests/conf/renderd.conf
  ModTileBulkMode Off
  ModTileCacheDurationDirty 900
  ModTileCacheDurationLowZoom 9 518400
  ModTileCacheDurationMax 604800
  ModTileCacheDurationMediumZoom 13 86400
  ModTileCacheDurationMinimum 10800
  ModTileCacheLastModifiedFactor 0.20
  ModTileEnableDirtyURL On
  ModTileEnableStats On
  ModTileEnableStatusURL On
  ModTileEnableTileThrottling Off
  ModTileEnableTileThrottlingXForward 0
  ModTileMaxLoadMissing 5
  ModTileMaxLoadOld 2
  ModTileMissingRequestTimeout 10
  ModTileRenderdSocketName @PROJECT_BINARY_DIR@/tests/run/renderd0.sock
  ModTileRequestTimeout 3
  ModTileThrottlingRenders 128 0.2
  ModTileThrottlingTiles 10000 1
  ModTileTileDir @PROJECT_BINARY_DIR@/tests/tiles
</VirtualHost>

<VirtualHost @HTTPD1_HOST@:@HTTPD1_PORT@>
  LoadTileConfigFile @PROJECT_BINARY_DIR@/tests/conf/renderd.conf
  ModTileBulkMode Off
  ModTileCacheDurationDirty 900
  ModTileCacheDurationLowZoom 9 518400
  ModTileCacheDurationMax 604800
  ModTileCacheDurationMediumZoom 13 86400
  ModTileCacheDurationMinimum 10800
  ModTileCacheLastModifiedFactor 0.20
  ModTileEnableDirtyURL Off
  ModTileEnableStats Off
  ModTileEnableStatusURL Off
  ModTileEnableTileThrottling Off
  ModTileEnableTileThrottlingXForward 0
  ModTileMaxLoadMissing 5
  ModTileMaxLoadOld 2
  ModTileMissingRequestTimeout 10
  ModTileRenderdSocketAddr @RENDERD1_HOST@ @RENDERD1_PORT@
  ModTileRequestTimeout 3
  ModTileThrottlingRenders 128 0.2
  ModTileThrottlingTiles 10000 1
  ModTileTileDir @PROJECT_BINARY_DIR@/tests/tiles
</VirtualHost>

CustomLog logs/access_log "%h %l %u %t \"%r\" %>s %b"
ErrorLog logs/error_log
Group @WWW_GROUP_NAME@
Listen @HTTPD0_PORT@
Listen @HTTPD1_PORT@
LogLevel debug
PidFile run/httpd.pid
ServerName localhost
ServerRoot @PROJECT_BINARY_DIR@/tests
User @WWW_USER_NAME@

<IfModule !access_compat_module>
  LoadModule access_compat_module @HTTPD_LIBEXECDIR@/mod_access_compat.so
</IfModule>
<IfModule !alias_module>
  LoadModule alias_module @HTTPD_LIBEXECDIR@/mod_alias.so
</IfModule>
<IfModule !authz_core_module>
  LoadModule authz_core_module @HTTPD_LIBEXECDIR@/mod_authz_core.so
</IfModule>
<IfModule !dir_module>
  LoadModule dir_module @HTTPD_LIBEXECDIR@/mod_dir.so
</IfModule>
<IfModule !log_config_module>
  LoadModule log_config_module @HTTPD_LIBEXECDIR@/mod_log_config.so
</IfModule>
<If "-f '@HTTPD_LIBEXECDIR@/mod_mpm_event.so'">
  <IfModule !mpm_prefork_module>
    <IfModule !mpm_event_module>
      LoadModule mpm_event_module @HTTPD_LIBEXECDIR@/mod_mpm_event.so
    </IfModule>
  </IfModule>
</If>
<If "-f '@HTTPD_LIBEXECDIR@/mod_mpm_prefork.so'">
  <IfModule !mpm_event_module>
    <IfModule !mpm_prefork_module>
      LoadModule mpm_prefork_module @HTTPD_LIBEXECDIR@/mod_mpm_prefork.so
    </IfModule>
  </IfModule>
</If>
<IfModule !unixd_module>
  LoadModule unixd_module @HTTPD_LIBEXECDIR@/mod_unixd.so
</IfModule>
