I want to deploy a prebuilt static site to Cloudflare Pages. I have an CMS that builds a static site for me and I can have it copy its output to an s3 bucket and trigger a deploy hook. So I would want an option to have Cloudflare pages copy the site from s3 to deploy.
I think the easiest way to accomplish this would be to:
- Make connecting to a git repo optional (technically not required as I could just connect an empty repo but it won’t be needed for this)
- Include the AWS CLI as a preinstalled tool
Then I could:
- Setup my AWS credentials as environment variables
- Trigger a build using a deploy hook
- Set my build command to: “aws s3 sync s3://(bucket-name) output”
- Use “output” as the build output directory.
Technically I should be able to replicate this with what is available today but that will require me to
- Write (or find a prewritten) sync tool in a supported language
- Link to a git repo with the sync tool
- Set the build command to run the sync tool
I just feel the process would be much nicer if you included the AWS CLI and allowed me to not have to write or find my own syncing tool.