First post
Making this blog was a great excuse to try Astro and Cloudflare. I really like the idea of static sites that cost next to nothing. Hosting sites with servers or functions is always a larger lift and a larger cost.
Right now I can see that the images aren’t loading correctly. It’s always nice when something isn’t working right, it’s a nagging feeling that will get me to come back and play with the site a little more.
This is my first time using Astro. It’s super lightweight!
This is also my first time using Cloudflare. Deploying to Cloudflare was super fast an easy when following this guide: Astro. It was also free! I made a Cloudflare account while following that guide and I didn’t put in any payment informaiton.
I created and shipped this website following the Cloudflare guide. But there are a few things I did that went beyond the guide:
- I transferred my domain from SquareSpace to Cloudflare. Cloudflare has a guide but the instructions in the console are much more helpful.
- Registered my Custom domain with this Cloudflare page
I’ll edit this post later when I work out the kinks with the images. Bye for now 👋.
Update Dec 31:
The image issue was in my astro.config.mjs. The default configuration cloudflare adapter generated by running pnpm create cloudflare@latest my-astro-app --framework=astro generated: imageService: "cloudflare".
I found this Astro documentation: Configure no-op passthrough service:
If your adapter does not support Astro’s built-in Sharp image optimization (e.g. Deno, Cloudflare), you can configure a no-op image service to allow you to use the
and
components.
Although this doc, doesn’t seem 100% up to date since, I updated the imageService to "passthrough" and that works fine for now. I’m guessing I’d have to set up cloudflare image hosting to use the default config.
Deploying this site is to cloudflare with wrangler is very fast. I may have to experiment and see how fast it would deploy to S3 on aws.
For now I’m happy to have this free hosting for my blog. I’ll be back with more posts about my technology stuff and more!
Thanks for reading, Bye!