Organizations

  • Setting Up CloudFront Functions for Hugo Page Routing

    When hosting a Hugo site on AWS CloudFront, URLs ending with a trailing slash (like /about/) don’t automatically resolve to their corresponding index.html files. While Lambda@Edge can solve this, CloudFront Functions provide a more cost-effective and faster solution. This article will guide you through setting up a CloudFront Function to handle this routing properly.

    Why CloudFront Functions?

    CloudFront Functions are a perfect fit for this URL rewriting task because:

    serverless static-site routing Created Mon, 23 Dec 2024 00:00:00 +0000