Minimal app configuration
To successfully serve a static site using Upsun, you need to set up a minimal app configuration similar to the following: See more information on the required minimal settings:Add more features
Allow static files but not dynamic files on PHP containers
If you have a PHP container, you might want to enable client-side scripts but disable server-side scripts. To enable static files that don’t match any rule while disabling server-side scripts on a PHP container, use the following configuration: See more information onlocations properties.
Create cache rules
You can create sensible cache rules to improve performance. For example, if you publish new content regularly without updating images or site files much, you might want to cache text files for a day but all image files for longer. To do so, use a configuration similar to the following: You can also set aCache-Control header in your rules.
If expires and a Cache-Control header are set, the rule ignores the expires and sets only the Cache-Control header. For this reason, make sure
to add a max-age value, in seconds, for the Cache-Control header.