"Fail open" question
If "Fail Open" mode is active (Pricing | Cloudflare Pages docs)
Once the daily request limit has been reached, Projects in fail open mode will bypass the Function and prevent it from operating on incoming traffic. Incoming requests will behave as if there was no Function, and pass through to the site’s static assets. This is the default configuration for all Pages projects.I understand from the documentation that my _worker.js file would not be seen as a static asset, but what about if my _worker.js file imports some others files? For example, given the following
_routes.json
:
And the following directory structure:
In this case, in “Fail open” mode, can the content of server folder be visible, or does it still respect _routes.json?
Will pages publicly serve my server-side source code(server directory) when an out-of-quota request is made to, for example /server/imported-by-_worker.js?2 Replies
Only the things in your asset output directory are served
Anything server-side is not
I'm not sure this answers my question. assets output and server code are in the same directory in the example (pages_build_output_dir). So the directory tree in my question is the pages_build_output_dir itself.
@Walshy | Deploying