I have this specific use case that I'm trying to solve with Firebase Hosting and it's the following:
- I'm using Gridsome to generate static websites
- Before building, Gridsome uses Graphql and grabs from a Headless CMS some blog posts, which then are used to create static pages for each of them
- Currently, the Gridsome build is automatically deployed to Firebase Hosting whenever I merge into master through Github (this works great already)
The problem that I'm facing is that I want to trigger a Gridsome build + Firebase Hosting deploy whenever I publish a new blog post on my Headless CMS (It has the option to make a POST on new blog post). I know this is possible on other solutions like Vercel, but right now I'm using Firebase and would like to stick to the suite.
I've tried using the REST API without any luck, and Github Webhooks works the other way around and doesn't solve my problem. I'm thinking there might be a chance to call a Firebase function and use the CLI to deploy or something.
What I would like to know is if this feature exists and how to accomplish this scenario.
Thanks.