Skip to content

Conversation

@catplat
Copy link
Collaborator

@catplat catplat commented Nov 6, 2025

Why

Closes #5175

What's changed

Update the top-level rule in sites/platform/static/files/fetch/appyaml/drupal10

Where are changes

http://localhost:1313/guides/drupal/deploy/configure.html#configure-apps-in-platformappyaml

Updates are for:

  • platform (sites/platform templates)
  • upsun (sites/upsun templates)

@catplat catplat linked an issue Nov 6, 2025 that may be closed by this pull request
@github-actions
Copy link

github-actions bot commented Nov 6, 2025

Your Upsun Fixed environment has successfully deployed. 🚀

See the site:

Copy link
Contributor

@dman-coders dman-coders left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First iteration had a few issues.

  • don't add the extra nesting under web - it's invalid there
  • Don't remove passthru - it's needed for the app
  • Don't remove the exceptiojn for access to css and other safe files - they are all normal and need not be blocked.

It's only PHP scripts that we are refining the execution rules for. I have a replacement forthcoming ...

@dman-coders
Copy link
Contributor

Tested the repaired version.
confirmed that index.php, install.php work, and access to css, including aggregated css works.
update.php and /core/rebuild.php are also accessible
confirmed that now sites/default/settings.php is disallowed
confirmed tha an arbitrary script like phpinfo.php is NOT allowed - this was the intent.
Going back to the endpoints I tested and reported in the original issue.
https://linear.app/platformsh/issue/ADV-2168/upsun-fixed-update-the-sample-drupal-app-configuration#comment-31e32bac

... OK, all the misc php files that were accessed incorrectly before are now blocked (good)
all the functionality we know we need remains (good)

Copy link
Contributor

@dman-coders dman-coders left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After reviewing together, this is valid and works.
Arbitrary php files are now disallowed (404) and required php pages are allowed still.
Correct behaviour now.

I actually tested this file on real deployments

@catplat catplat merged commit 8184ce5 into main Nov 7, 2025
14 checks passed
@catplat catplat deleted the 5175-drupal-sample branch November 7, 2025 04:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update the Drupal sample app configuration

4 participants