Skip to main content

Deployment Failures

Deployment failures occur after the build succeeds but the application fails to start or run properly. Check your deployment logs and application logs to diagnose the issue.

Common Deployment Issues

Container Fails to Start

The container starts but crashes immediately or within a few seconds.

Symptoms:

  • Deployment status shows "Failed"
  • Application logs show crash traces or exit codes

Common causes:

  • Uncaught exception during startup (missing config, syntax error)
  • Missing environment variable that the app requires at boot
  • Incompatible runtime version

Solutions:

  1. Check Application > App Logs for error output
  2. Verify all required environment variables are set
  3. Test your startup command locally: run the same command from your services > web > command

Release Command Fails

The release command runs after the build but before the new version goes live. If it fails, the deployment is rolled back.

Symptoms:

  • Build succeeds but deployment fails
  • Logs mention the release command or migration errors

Common causes:

  • Database migration errors (conflicting migrations, missing tables)
  • Missing environment variables needed by the release command
  • Release command has a typo or references a missing script

Solutions:

  1. Check the deployment log for the release command output
  2. Run the migration or release command manually via Run Commands on the server
  3. Verify DATABASE_URL and other required variables are set
  4. If migrations conflict, resolve them locally and push a fix
warning

If your release command consistently fails, you can temporarily skip it by setting skip_release_command: true in your appliku.yml. Fix the underlying issue before re-enabling it.

Port Mismatch

Your application must listen on the port that Appliku expects. If there's a mismatch, the container appears to start but Nginx cannot route traffic to it.

Symptoms:

  • 502 Bad Gateway errors
  • Application logs show the app started successfully
  • No errors in deployment logs

Solutions:

  1. Check Application > Build Settings for the configured container port
  2. Make sure your application binds to 0.0.0.0:<port> (not 127.0.0.1)
  3. Common port settings:
    • Django/Gunicorn: gunicorn project.wsgi --bind 0.0.0.0:8000
    • Node.js/Express: app.listen(process.env.PORT || 3000)
    • Rails: rails server -b 0.0.0.0 -p 3000
note

The PORT environment variable is automatically set by Appliku to match your configured container port. Use it in your application startup command when possible.

Health Check Timeout

After the container starts, Appliku checks that it is responding. If the health check times out, the deployment fails.

Common causes:

  • Application takes too long to start (loading large models, warming caches)
  • Application crashes after initial startup
  • Application not responding on the expected port

Solutions:

  • Optimize startup time (lazy-load heavy resources)
  • Ensure the app responds to HTTP requests on the configured port
  • Check for post-startup crashes in the application logs

How to Check

  1. Deployment logs: Go to Application > Deployments and click the failed deployment to see the full log
  2. Application logs: Go to Application > App Logs to see runtime output from your containers
  3. Run Commands: Use the server's Run Commands feature to inspect the container state manually