veeque
Explore posts from serversCDCloudflare Developers
•Created by veeque on 11/15/2024 in #general-help
Will D1 get jurisdictional restrictions?
I was reading this thread: https://community.cloudflare.com/t/d1-location-hints-explanation-and-improvement/634791
I cannot find any roadmap, so I'm wondering if it's something that has been forgotten
3 replies
CDCloudflare Developers
•Created by veeque on 10/31/2024 in #general-help
How to set up regional services?
5 replies
CDCloudflare Developers
•Created by veeque on 9/11/2024 in #pages-help
How to host multiple pages under the same domain
Let's assume I have a monorepo where each project is a SvelteKit app running on pages. Let's say they run on
app1.pages.dev
, app2.pages.dev
, app3.pages.dev
, and so on.
I now also have a worker that I deploy to handle all this.
Before doing that I have to point out that one page is special, it runs on homepage.pages.dev
and it will be the default page to show (when going to /
, or any other non-app route).
With all that being said:
* When going to /app1
I want to render app1.pages.dev
(also, when going to /app1/literally/anything
I want to render app1.pages.dev/literally/anything
). The same goes for app2
, and any other "custom" route I want
* If this were a switch case, the default would be just rendering the homepage.pages.dev/whatever/happens/to/be/the/uri
What issues I'm facing: I cannot understand how to properly "forward" the url after /app1
and I don't understand how/when assets (the JS, CSS, etc) load properly.
There might be some thing I've tried and either missed or found to be unsuccessful.
Any help would be amazing!3 replies
CDCloudflare Developers
•Created by veeque on 9/10/2024 in #general-help
How to host multiple pages on the same domain
I have a monorepo with 5 applications. Instead of giving each app its own subdomain I would like for one of these to be the home
example.com/
(which might have other routes like /about-us
, /legal
, etc), and all others to be available in example.com/app1
, example.com/app2
, etc. How can I do this?2 replies
CDCloudflare Developers
•Created by veeque on 9/4/2024 in #workers-help
Lower number of requests to SvelteKit app on CF pages
I have a SvelteKit app that I'm deploying using CF pages (or workes? still confusing). However requests to build artifacts (
/_app/*
) still get counted towards the requests usage quota. Is there a way to lower that?
The app is pretty simple:
* Static pages (homepage, contact us, etc)
* SPA pages (the app, hidden behind a login mask so no need for SSR)
* Dynamic routes (my customer's clients go to these eg /vendor/[name]
and they are dynamic).
Ideally it would be nice if the dynamic route gets generated and just statically served afterwards (kind of like ISR), the SPA pages should, ideally, only make requests to a CDN, and the static page should also make a request to a static page. Only the API endpoints actually have a reason to hit the worker itself. How can I configure this?1 replies
CDCloudflare Developers
•Created by veeque on 8/19/2024 in #general-help
How can I add a DNS record (dev.*) that points to a preview deployment?
I have a preview deployment with this URL:
dev.[site-name].pages.dev
, so I tried adding a CNAME record dev
that points to dev.[site-name].pages.dev
but navigating to it gives a 522, why's that? the pages.dev url works just fine17 replies
CDCloudflare Developers
•Created by veeque on 8/15/2024 in #general-help
Pages, Workers, Pages functions?
Which does Pages use? I assume "pages functions" but the pricing data is that for "workers"? Can someone please explain to me how all this goes together? The documentation links me all over the place but there is not "graph" I am able to visualise in my mind from all that, mostly due to me having basically just Vercel as hosting experience.
6 replies