Donal McBreen - Kamal 2.0: Deploy web apps anywhere - Rails World 2024

Discover Kamal 2.0, a Docker-based deployment tool offering zero-downtime deploys, built-in secret management & multi-app support. Learn how it simplifies web app deployment.

Key takeaways
  • Kamal 2.0 is a modern deployment tool built for Docker, designed as a simpler alternative to Kubernetes for deploying web applications

  • Key features include:

    • Zero-downtime deployments
    • Asset bridging to handle static assets between deployments
    • Built-in secret management with password manager integrations (1Password, LastPass, Bitwarden)
    • Multi-app support on a single server
    • Custom proxy solution optimized for container deployments
  • Core design principles:

    • Imperative rather than declarative approach
    • Minimal configuration required
    • Fast deployment without polling/waiting
    • No need for complex infrastructure
  • Requirements:

    • Docker registry
    • SSH access to deployment servers
    • Docker installed on target hosts
    • Domain pointing to server
  • Notable improvements in 2.0:

    • Better secret management without storing secrets on disk
    • Simplified asset handling between deployments
    • More efficient proxy implementation
    • Improved multi-app support
    • Zero-config SSL/HTTPS support
    • Built-in Rails console support
  • Will be included by default in Rails 8, making deployment significantly easier for new applications

  • Focuses on simple deployment scenarios:

    • Single server deployments
    • Small to medium applications
    • Teams that don’t need/want Kubernetes complexity