silverstripe / cwp

Common Web Platform (CWP) features module. We strongly recommend using it for all new CWP projects. Future features will be delivered here.
https://www.cwp.govt.nz
BSD 3-Clause "New" or "Revised" License
10 stars 27 forks source link

Clarify where redirects should go. #283

Closed mateusz closed 4 years ago

mateusz commented 4 years ago

Take "public" dir into account.

michalkleiner commented 4 years ago

Thanks @mateusz. Do you think it's also worth calling out the differences between RedirectRule and RedirectMatch?

mateusz commented 4 years ago

@michalkleiner I personally feel like we don't want to repeat apache docs here. This behaviour isn't really related to CWP, and it's the implementer's responsibility to understand how it works.

Now, making it clearer where is the webroot pointed to is CWP related, and has a bearing on this, so I think this particular piece of information could be exposed somewhere.

Any suggestions as to good location? Inline here, and in htaccess docs?

michalkleiner commented 4 years ago

@mateusz maybe under https://www.cwp.govt.nz/developer-docs/en/2/working_with_projects/infrastructural_considerations/#webserver-2 ?

mateusz commented 4 years ago

@michalkleiner care to review? Change in green:


Screen Shot 2020-07-13 at 12 03 22 PM
michalkleiner commented 4 years ago

@mateusz that reads ok, thanks. Keeping the recipe's .htaccess file verbatim is not for security reasons though — it's a functional necessity, not a security measure.

I've also made a PR for the actual .htaccess to support this https://github.com/silverstripe/cwp/pull/284/files — happy to adjust the wording there a bit to align with your change in the docs.

mateusz commented 4 years ago

True, removed the remark about security reasons, and merged, thanks for review! I saw your other PR - let's move over there.