silverstripe / silverstripe/developer-docs

Server Requirements: SS_PROTECTED_ASSETS_PATH="../.protected/" now resolves outside the project root

Open
#910 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
No language data
Stars
7
Forks
74
Avg merge
1d 14m
Merged PRs (30d)
6

Description

Both branches (en/00_Getting_Started/00_Server_Requirements.md, branch 5 line 142, branch 6 line 127) show:

# This will be inside your project root, along-side the public/ directory
SS_PROTECTED_ASSETS_PATH="../.protected/"

Since silverstripe/assets 3.2.2 (silverstripe/silverstripe-assets#713, fixing #706), ProtectedAssetAdapter::findRoot() passes the env value through AssetAdapter::findRoot(), which resolves a leading ../ to dirname(BASE_PATH). So on current CMS 6 this example ends up one level above the project root, not inside it. Before 3.2.2 the raw value was used, which under PHP-FPM (cwd = public/) happened to land in the project root, matching the comment.

I think the CMS 6 example could use ./.protected/ (resolved against BASE_PATH), or keep ../ and update the comment. I'm less sure what the CMS 5 page should say, since assets 2.x still uses the raw value there. It may be worth a short note, as upgrading can quietly move the protected store.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with en/00_Getting_Started/00_Server_Requirements.md, checking branch 5 line 142 and branch 6 line 127. Compare the documented path behavior for CMS 5/assets 2.x and CMS 6/assets 3.2.2, including the linked silverstripe-assets changes. Done means the examples and comments accurately describe the resolved location and warn about any upgrade-related move.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.