pmtiles-swarm

connecting…
Archive Size Added Mode Origin Progress Peers Down Up Ratio Expires State

Warm region

Reads tiles ahead of anyone asking for them, so the first visitor to an area does not wait on the swarm for it. Pick the area and the zoom range: the tile count quadruples with every level, so the whole world to deep zoom is millions of reads and almost never what is wanted.

Set location

Moves the archive's data. Within one filesystem this is a rename and finishes at once; across two it is a real copy, which for a large archive takes a while and runs in the background.

Import a list of PMTiles URLs

A provider that publishes terrain as many separate files usually publishes an index of them too — Mapterhorn's download_urls.json names 458, each with the box it covers and the zooms it holds. Those become sources read straight from where they are, over HTTP: nothing is downloaded, nothing is seeded, and a tile outside a file's box never asks it.
An existing stack, or a new name to make one. Sources already in it stay; a list imported before from this same address is replaced.
Fetched by this node rather than by your browser — the console is often on a different network, and what matters is that the machine which will read the archives can reach them. An index with an items list, or a plain list of URLs one per line.
Set on every imported source. An index rarely states it — Mapterhorn's files are all terrarium and its JSON never says so — and a terrain source read with the wrong one is a cliff face.

Export to archive

Runs the recipe over its sources and writes the result as a real archive, with its own infohash, seeded like any other. It reads every tile the sources hold, so it can take hours — and it can be stopped, which keeps the work for the next run to carry on from.
An export reads every tile its sources hold, which for a planet is hours. Narrowing it is the difference between a run you wait for and one you leave overnight.
The recipe's, not this dialog's — an export writes what the stack already serves, so what is baked and what a map has been looking at cannot disagree. Change them in the stack, then export.
What the archive calls itself, and what a map client shows. Dated by default, because two builds of one map are easier to tell apart that way — nothing here looks an archive up by name, so it is free to say whatever is useful.
Written into the archive's own metadata, so the credit travels with the file rather than living in whatever style happened to load it. Filled in from every source's attribution joined with |, since a stack is a derived work of all of them and this is the thing that reliably goes missing when tiles are combined. The stack's own attribution wins where it has one.
Optional, and empty by default — what a stack merges is the operator's business and not something to guess at. The date this was baked is recorded here whether or not anything else is.
Comma separated. What the archive is filed under once it is added, which is what /latest/<category>/ follows and what a subscriber sees in the feed. A stack has none of its own to fall back to — it is a recipe, not an archive — so left empty the file is unfiled: held and seeded, in no category and no feed.
This exports once, now. To have it run again by itself — nightly, or every so many hours — add a row under Settings → Feeds → Scheduled exports, where the other automations that bring an archive in on a timer are set up.

Adopt existing torrents

Takes over archives a torrent client is already seeding, so they are catalogued, served and published from here without being re-hashed or downloaded again.
Applied to everything taken. Leave empty to keep whatever category the other client had them under.
Their data is somewhere this node cannot read, but their infohash is right here — which is all it takes to join the swarm the other client is already seeding into. Anything already readable is adopted where it lies and is unaffected by this.

Add stack

A stack serves several archives as one tile endpoint. Sources are listed lowest first: each one covers the one before it wherever it has data, and the last wins. What shows through from underneath is whatever the source above masked or never had.
Used in the URL: /stacks/…/tiles.json
height = red × + green × + blue ×
Used where a source has no tile at this zoom and one is taken from its parent.
Multiplied by how many zoom levels a source was upscaled, so a tile from its immediate parent is barely touched and one from six levels up is smoothed hard. Hides the terracing an upscaled DEM shows under a hillshade. gaussian_blur_sigma in the offline merge, where 1.5 is the value these archives were built with. 0 is off.
A tile's coordinates are an extent rather than a pixel count, so a size is not a crop: it is the same ground on a finer or coarser grid. Left to follow the sources, the largest one decides — which keeps the finest data the stack has. A request can override this with /stacks/<id>/512/{z}/{x}/{y}.

Add an archive

A local path, a URL, a magnet, or a .torrent URL.
An archive can carry several. Feeds include every archive carrying the category asked for.
Joining an existing torrent
Cache is the default because committing a disk to a copy of something that may be hundreds of gigabytes should be a decision. Either can be changed afterwards without losing what is already downloaded.
Trackers
Comma separated, added to the defaults above. Only applies when a torrent is created here — joining one takes the trackers it already carries.
Fetching from a URL
Piece hashes are computed over content, so the whole archive is read either way. Keeping it makes this node a seeder immediately; discarding costs no disk, but nothing here can seed what it just published until a peer completes a copy.
A web seed makes the archive usable before it has any peers. Uncheck it for a private URL — a pre-signed link is a credential, and a torrent cannot be recalled.
Checksum
For a quick manual check. The torrent already verifies the archive, and per piece rather than as a whole — this is the familiar convenience, not the integrity guarantee. It costs a second read of the whole file, so the add takes twice as long.
Web seeds
Comma separated. Use this to publish a public URL instead of a private one.