Troubleshooting Guide
This guide helps you diagnose and resolve common issues with Deployxa.
Build Failures
Module Not Found
Error:
Module not found: Can't resolve 'package-name'
Cause: Missing dependency in package.json or incorrect import path.
Solution:
-
Check package.json:
npm install package-namegit add package.json package-lock.jsongit commit -m "Add missing dependency"git push -
Verify import path:
// ❌ Wrongimport utils from './util';// ✅ Correctimport utils from './utils'; -
Clear build cache:
deployxa deploy --no-cache
Build Command Failed
Error:
Command failed: npm run build
Cause: Build script error or missing configuration.
Solution:
-
Test locally:
npm run build -
Check build logs:
deployxa logs <deployment-id> --type build -
Verify build command:
- Go to Project → Settings → Build
- Ensure build command is correct
- Common commands:
- Next.js:
npm run build - React:
npm run build - Vue:
npm run build - Laravel:
composer install --no-dev
- Next.js:
TypeScript Compilation Error
Error:
error TS2307: Cannot find module 'module-name'
Cause: Missing TypeScript definitions or incorrect tsconfig.json.
Solution:
-
Install type definitions:
npm install --save-dev @types/module-name -
Check tsconfig.json:
{"compilerOptions": {"moduleResolution": "node","esModuleInterop": true}} -
Exclude node_modules:
{"exclude": ["node_modules"]}
Out of Memory During Build
Error:
FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed
Cause: Build process requires more memory than allocated.
Solution:
-
Increase Node memory:
{"scripts": {"build": "node --max-old-space-size=4096 node_modules/.bin/next build"}} -
Optimize build:
- Reduce bundle size
- Use code splitting
- Enable tree shaking
-
Upgrade plan:
- Pro tier has more memory
- Enterprise tier has custom limits
Runtime Errors
Application Crashes on Start
Error:
Error: listen EADDRINUSE: address already in use :::3000
Cause: Port conflict or incorrect port configuration.
Solution:
-
Use environment variable:
const port = process.env.PORT || 3000;app.listen(port); -
Check start command:
- Ensure start command uses correct port
- Deployxa automatically sets PORT environment variable
Database Connection Failed
Error:
Error: connect ECONNREFUSED 127.0.0.1:5432
Cause: Incorrect database credentials or database not accessible.
Solution:
-
Verify credentials:
DATABASE_URL=postgresql://user:pass@host:5432/db -
Check database host:
- Use external database host, not localhost
- Ensure database is publicly accessible or use VPN
-
Test connection:
psql $DATABASE_URL
Environment Variable Missing
Error:
Error: Environment variable not found: API_KEY
Cause: Required environment variable not set.
Solution:
-
Add variable:
deployxa env add API_KEY your-api-key --project my-app -
Verify in dashboard:
- Go to Project → Environment
- Check variable exists
- Ensure correct environment (production, preview, development)
-
Redeploy:
deployxa deploy --project my-app
CORS Error
Error:
Access to fetch at 'https://api.example.com' from origin 'https://my-app.deployxa.app' has been blocked by CORS policy
Cause: API server not configured to allow requests from your domain.
Solution:
-
Configure CORS on API server:
// Express.jsconst cors = require('cors');app.use(cors({origin: 'https://my-app.deployxa.app'})); -
Use proxy:
// next.config.jsmodule.exports = {async rewrites() {return [{source: '/api/:path*',destination: 'https://api.example.com/:path*'}];}};
Domain Issues
DNS Not Propagating
Problem: Domain verification failing or SSL not provisioning.
Cause: DNS records not configured correctly or not propagated.
Solution:
-
Verify DNS records:
dig example.com Adig www.example.com CNAME -
Check required records:
- Apex domain: A record pointing to
76.76.21.21 - Subdomain: CNAME pointing to
cname.deployxa.com
- Apex domain: A record pointing to
-
Wait for propagation:
- DNS can take up to 48 hours
- Use online tools to check propagation
- Most changes propagate within 15 minutes
-
Re-verify:
deployxa domain verify example.com --project my-app
SSL Certificate Pending
Problem: SSL certificate shows "Pending" for too long.
Cause: DNS not verified or Let's Encrypt rate limit.
Solution:
-
Verify domain first:
- Ensure domain is verified
- Check DNS records are correct
-
Check rate limits:
- Let's Encrypt has rate limits
- Wait 1 hour and retry
-
Manual verification:
deployxa domain ssl example.com --project my-app
Deployment Issues
Deployment Stuck in Queue
Problem: Deployment shows "Queued" for too long.
Cause: Build workers busy or system issue.
Solution:
-
Check system status:
- Visit status.deployxa.com
- Check for ongoing incidents
-
Cancel and retry:
deployxa deployment cancel <deployment-id>deployxa deploy --project my-app -
Contact support:
- If issue persists > 30 minutes
- Email: support@deployxa.com
Deployment Timeout
Problem: Deployment takes too long and times out.
Cause: Large dependencies, slow build, or network issues.
Solution:
-
Optimize build:
- Use
npm ciinstead ofnpm install - Enable dependency caching
- Reduce build steps
- Use
-
Check build logs:
deployxa logs <deployment-id> --type build -
Upgrade plan:
- Pro tier has faster build workers
- Enterprise tier has dedicated resources
Rollback Failed
Problem: Rollback to previous deployment fails.
Cause: Previous deployment no longer available or configuration changed.
Solution:
-
Check deployment history:
deployxa deployment list --project my-app -
Verify deployment exists:
- Only successful deployments can be rolled back to
- Check deployment is not deleted
-
Manual rollback:
- Create new deployment from previous commit
- Or redeploy specific branch
Performance Issues
Slow Application
Problem: Application responds slowly.
Cause: Insufficient resources, unoptimized code, or database issues.
Solution:
-
Check metrics:
deployxa metrics --project my-app --period 24h -
Increase resources:
- Upgrade plan for more CPU/RAM
- Enable auto-scaling
-
Optimize application:
- Enable caching
- Use CDN for static assets
- Optimize database queries
- Minimize bundle size
-
Monitor logs:
deployxa logs --project my-app --type runtime --follow
High Error Rate
Problem: Many requests returning 5xx errors.
Cause: Application bugs, resource limits, or external service failures.
Solution:
-
Check error logs:
deployxa logs --project my-app --type error -
Monitor metrics:
deployxa metrics --project my-app --metric errors -
Check external services:
- Verify database connection
- Check third-party API status
- Review environment variables
-
Enable alerts:
- Set up error rate alerts
- Configure notifications
Billing Issues
Payment Failed
Problem: Payment method declined or failed.
Cause: Insufficient funds, expired card, or bank issue.
Solution:
-
Update payment method:
- Go to Settings → Billing
- Add new payment method
- Retry payment
-
Check with bank:
- Verify card is active
- Check for international transaction blocks
- Ensure sufficient funds
-
Use alternative method:
- Try different card
- Use PayPal
- Contact support for bank transfer
Out of Credits
Problem: Project suspended due to insufficient credits.
Cause: Usage exceeded prepaid credits.
Solution:
-
Add credits:
- Go to Settings → Billing
- Click "Add Credits"
- Enter amount and payment method
-
Review usage:
deployxa billing usage --org my-org -
Set budget alerts:
- Configure alerts at 50%, 75%, 90%
- Prevent unexpected charges
-
Optimize usage:
- Review resource allocation
- Enable auto-scaling limits
- Remove unused projects
CLI Issues
Command Not Found
Problem:
deployxa: command not found
Cause: CLI not installed or not in PATH.
Solution:
-
Install CLI:
npm install -g @deployxa/cli -
Check PATH:
echo $PATH -
Use full path:
~/.npm-global/bin/deployxa -
Reinstall:
npm uninstall -g @deployxa/clinpm install -g @deployxa/cli
Authentication Failed
Problem:
Error: Authentication failed
Cause: Invalid or expired API token.
Solution:
-
Login again:
deployxa login -
Check token:
deployxa whoami -
Generate new token:
- Go to Settings → API Keys
- Create new API key
- Use new token
Getting Help
Debugging Steps
-
Check logs:
deployxa logs --project my-app --follow -
Verify configuration:
deployxa project get my-app -
Test locally:
- Reproduce issue locally
- Check environment variables
- Verify dependencies
-
Check status:
- Visit status.deployxa.com
- Check for ongoing incidents
Contact Support
Email: support@deployxa.com
Include:
- Project name/ID
- Deployment ID (if applicable)
- Error messages
- Steps to reproduce
- Expected vs actual behavior
Response Time:
- Free tier: 48 hours
- Pro tier: 24 hours
- Enterprise tier: 4 hours
Community Support
Discord: discord.gg/deployxa
GitHub: github.com/deployxa
Stack Overflow: Tag questions with deployxa
Common Error Codes
| Code | Meaning | Solution |
|---|---|---|
| 400 | Bad Request | Check request format |
| 401 | Unauthorized | Verify API token |
| 403 | Forbidden | Check permissions |
| 404 | Not Found | Verify resource exists |
| 429 | Rate Limited | Wait and retry |
| 500 | Server Error | Contact support |
| 503 | Service Unavailable | Check status page |
Related Topics
Need Help? Contact support@deployxa.com or join our community Discord.