The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119.
A tilekiln configuration is composed of a REQUIRED YAML configuration file with zero or more OPTIONAL SQL Jinja2 files.
The configuration SHALL be a YAML document. It MUST NOT be a YAML stream containing multiple documents.
SQL Jinja files are processed with Jinja2 as documented below. They SHOULD form a valid PostgreSQL SELECT statement with one column which is a PostGIS geometry in the coordinates space of the vector tile. This SHOULD be done with ST_AsMVTGeom(geom, {{bbox}}, {{extent}}))
.
The zoom of the tile being generated.
The x coordinate of the tile being generated.
The y coordinate of the tile being generated.
A SQL statement that evaluates to the buffered bounding box of the tile being generated.
A SQL statement that evaluates to the unbuffered bounding box of the tile being generated.
The tile extent in screen space.
The tile buffer, in units of tile coordinate space.
The side length of the tile being generated in web mercator meters.
The area of the tile being generated in square web mercator meters. Equal to {{ tile_length }}
squared.
The side length of one unit in the coordinate space of the tile being generated in web mercator meters. Equal to {{ tile_length }} / {{ extent }}
.
The area of one unit in the coordinate space of the tile being generated in square web mercator meters. Equal to {{ coordinate_length }}
squared.