Skip to main content

Before you start

Add the file at this path on your default branch.
Peak reads it from the default branch only. Expect a pull request’s changes to this file to have no effect, even on its own preview. Merge changes to the default branch to use them.

Example

.peak/preview.yml

Top-level keys

Use lowercase letters, digits, and hyphens in names, up to 63 characters. Don’t start a name with peakviews-.

Start from another file

Set from to keep your Render or Compose setup and change part of it.
.peak/preview.yml
Expect Peak to read that file first, then apply this one. Expect a service or database with the same name to keep every field you leave out. Expect env and build args to merge by name. Set a service, database, or variable to null to remove it.

Services

Set build or image on each service. Set a port on the public service. Use the same value forms for build args as for env.

Databases

Values

Set each env value or build arg in one of these forms. Expect each generated value to stay the same for the life of the preview. Give two generate values the same key to share one value.
Expect Peak to ask for every secret name before a preview starts. Use letters, digits, and underscores in secret names. Don’t use names that change how Docker Compose runs, such as PATH, HOME, or names that start with COMPOSE_, DOCKER_, BUILDKIT_, BUILDX_, or PEAKVIEWS_. Write {{ and }} for literal braces.

File rules

Keep the file at 64 KiB or less. Use strict YAML: no anchors, aliases, merge keys, or tags. Use only the keys on this page. Expect a version 1 file to be ignored. Check errors under Setup in Previews.