[BUG] Fails to deploy NextJS app
See original GitHub issueI’m able to deploy my NextJS app directly (firebase deploy
), however when I deploy via a PR or Merge action I get an error.
My repo is structured like so (the next app is in /frontend)
- firebase.json
- .github/workflows/firebase-hosting-merge.yml
- frontend/pages
- functions
My firebase.json is:
{
"functions": {
"source": "functions"
},
"hosting": {
"source": "frontend",
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"]
}
}
Action config
name: Deploy to Firebase Hosting on PR
'on': pull_request
jobs:
build_and_preview:
if: '${{ github.event.pull_request.head.repo.full_name == github.repository }}'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_SDXCRYPTO_ALGOVERA }}'
projectId: sdxcrypto-algovera
Error message
Error: Cannot deploy a web framework to hosting because the experiment webframeworks is not enabled. To enable webframeworks run firebase experiments:enable webframeworks
The process ‘/usr/local/bin/npx’ failed with exit code 1
Expected behavior
Deploys sucessfully. I have enabled the webframeworks experiment and re-tried but to no avail.
Actual behavior
Fails to deploy.
Issue Analytics
- State:
- Created 10 months ago
- Reactions:4
- Comments:6
Top Results From Across the Web
next.js - Error when trying to deploy NextJS app on Vercel
For those who are wondering, the solution that I used is first to remove the "next/babel" from the extends array, as julio has...
Read more >Next js App - Deploy failed to complete successfully. #2547
I have read the guide for submitting bug reports. I have done my best to include a minimal, self-contained set of instructions for...
Read more >NEED HELP: Next js deployment failed with error - why?
I just tried to deploy a Next js application on Vercel, but I got an error and I am not sure what went...
Read more >Trouble Deploying Next JS site - Netlify Support Forums
I read the procedure for deploying Next JS apps to Netlify. However I ran into trouble. Problem installing the plugin. Netlify App Log...
Read more >Netlify CMS & Next.js Deploy Error Fixed. (failed due to an ...
THE ERROR : Site has not yet been deployedfailed due to an error in @netlify/plugin- nextjs pluginDeploy summaryPlugin ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’m experiencing the same issue. I tried adding the installation command for firebase to the action and manually enabling experiment webframeworks but it all still fails. Is there something that can be done to automatically enable this with actions?
I see there are 2 potential fixes submitted but @FirebaseExtended hasn’t accepted either one. Fix # 1 Fix # 2
Potential Replacement: https://github.com/w9jds/firebase-action