N
Nuxt2mo ago
aonghas

Anyone had any success deploying Nuxt to Firebase App Hosting?

I’m getting this error: An error occurred in your rollout generic::failed_precondition: Revision 'appname-build-2025-07-16-007' is not ready and cannot serve traffic. The user-provided container failed to start and listen on the port defined provided by the PORT=8080 environment variable within the allocated timeout. This can happen when the container port is misconfigured or if the timeout is too short. The health check timeout can be extended. Logs for this revision might contain more information. Logs URL:
2 Replies
kapa.ai
kapa.ai2mo ago
Hi @aonghas. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- I'm sorry, but the knowledge sources do not contain specific information about deploying Nuxt to Firebase App Hosting or troubleshooting the exact error you mentioned regarding the container not listening on the expected port for Firebase App Hosting. However, based on similar issues with containerized Nuxt deployments, a common cause for this type of error is that the Nuxt server is not configured to listen on the correct host and port. For most container platforms (including Google Cloud and Docker), Nuxt should be set to listen on 0.0.0.0 and the port provided by the environment variable (often PORT or 8080). This is typically done by setting environment variables or configuring your Nuxt app as follows: In your Dockerfile or deployment environment:
ENV HOST=0.0.0.0 PORT=8080 NODE_ENV=production
ENV HOST=0.0.0.0 PORT=8080 NODE_ENV=production
Or in your nuxt.config:
export default defineNuxtConfig({
server: {
port: 8080,
host: '0.0.0.0'
}
})
export default defineNuxtConfig({
server: {
port: 8080,
host: '0.0.0.0'
}
})
This ensures Nuxt listens on all interfaces, not just localhost, which is required for most cloud/container environments to pass health checks and serve traffic. This pattern is confirmed for other platforms in the knowledge sources, such as Docker and Google App Engine, and is likely relevant for Firebase App Hosting as well Nuxt deployment docs, Stack Overflow Docker/Nuxt answer. If you have already set this and still encounter issues, the knowledge sources do not provide further Firebase App Hosting–specific troubleshooting steps. You may want to check the container logs for more details, as suggested in the error message. If you need more detailed Firebase App Hosting–specific guidance, I'm sorry, but there's no information about that in the provided knowledge sources. ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai2mo ago
<@670239292840214568> Kapa.ai is still learning and improving, please let me know how I did by reacting below.

Did you find this page helpful?