This guide will cover the steps on how you can deploy your site built with Eleventy and Agility CMS to Vercel.
Deploying your Eleventy site to Vercel
In Agility CMS, head to Settings > Sitemaps, and set up a click on the Automated Vercel Deployment which will take you through a deployment flow.
Install the Agility CMS integration that assists with the automated deployment flow.
Make sure the build command is
npm run build, and override the output directory to
dist. Then click Deploy.
When the site is deployed, you'll notice the site with its Published Content.
Updating The Eleventy site when Content is Published
To update your Production deployment when Content is Published, we'll need to set up a Webhook tonotify Vercel of these changes.
In Vercel, go to Settings > Git > Deploy Hooks and add a Build Hook. Copy the Webhook URL Vercel generates for you.
The Production Deployment of your Eleventy site will now rebuild and update when Publish events are made in Agility!