workers-sdk
workers-sdk copied to clipboard
🚀 Feature Request: Multiple Pages Projects from Same Github Repo
Describe the solution
Not sure if this is the right place to post this, but I would love for Cloudflare Pages to support multiple projects from the same repo. I have two use cases:
Multiple deploy environments
My app has separate internal, staging, and production deployments. All of them run the same code but are tracked in different branches. To achieve this today with Cloudflare Pages I need to have the same code in 3 different repos—doable, but not very transparent.
Multiple projects in a monorepo
My app consists of several subprojects that depend on one another and share the same tooling/idioms. The easiest way to handle this in our use case is to put everything together in a monorepo so that projects can cross reference shared code and tooling, and my team can collaborate on the same codebase. As such I would like to be able to deploy each of the projects independently despite them being in the same repo.
Thanks in advance and hope that this gets prioritized! The workarounds for these seem to be just not using a monorepo structure or having several redundant projects, but I wish it could be more elegant than that. Thanks!
We’re currently evaluating Cloudflare Pages for our company, and this issue is the one big blocker for us.
I would love to have some kind of solution for this.
(not affiliated with OP)
Same here. For us, the main problem is that the functions directory is expected at the root and there's no option to choose a different directory for it (there's an option to choose the static asset directory, but not the functions dir).
I made it work for my project by just adding another step to my monorepo's root build command, that copies the functions to the root. It's ugly but it works
That said it does not solve the above issues I mentioned. It just makes one project deploy.
I made it work for my project by just adding another step to my monorepo's root
buildcommand, that copies the functions to the root. It's ugly but it works
Yeah we've done the same in the past but it's indeed rather ugly :-P. Being able to simply configure a working-directory like other github actions commonly do woud solve this nicely.
Hey,
We're tracking this internally, it is on the roadmap! I recommend following the blog (https://blog.cloudflare.com/) and joining our Discord (https://discord.gg/cloudflaredev) to stay up to date :)
Any new developments?
Hey @WalshyDev I'm curious, we are already running else this scenario and we would like to move to CF pages with rest of our deployments, is it possible to have it? What's are recent developments on this? Thank you for any heads up!