E506 - File reference escapes the deck root¶
Cause¶
An authored file reference — a slide source:, a *_file: content
field, a container_file: include, or an image asset path — is
absolute, or its resolved target lies outside the deck's .deck.json
directory. References are confined to the deck root so that building a
deck obtained from an untrusted source (a git clone, an archive)
cannot read arbitrary files into the output. Symlinks are resolved
before the check: a symlink pointing outside the deck root is rejected
even though the link itself lives inside.
Example¶
{ markdown_file: "../../secrets/notes.md" }
How to fix¶
Move the referenced file inside the deck directory. If the file
legitimately lives elsewhere (e.g. a shared asset library), grant that
location explicitly at build time with a repeatable
--allow-path <dir> flag on scrolly build / scrolly validate —
the grant is made by the person running the build, never by deck
content.